[pal-cvs 3268] [1002] initial commit.

svnno****@sourc***** svnno****@sourc*****
2008年 6月 30日 (月) 11:54:28 JST


Revision: 1002
          http://svn.sourceforge.jp/cgi-bin/viewcvs.cgi?root=pal&view=rev&rev=1002
Author:   shinsuke
Date:     2008-06-30 11:54:27 +0900 (Mon, 30 Jun 2008)

Log Message:
-----------
initial commit.

Added Paths:
-----------
    announcement/trunk/.classpath
    announcement/trunk/.project
    announcement/trunk/.settings/
    announcement/trunk/.settings/org.eclipse.jdt.core.prefs
    announcement/trunk/.settings/org.eclipse.jdt.ui.prefs
    announcement/trunk/.settings/org.seasar.dolteng.eclipse.prefs
    announcement/trunk/dbflute/
    announcement/trunk/dbflute/_project.bat
    announcement/trunk/dbflute/_project.sh
    announcement/trunk/dbflute/build-announcement.properties
    announcement/trunk/dbflute/dfprop/
    announcement/trunk/dbflute/dfprop/databaseInfoMap.dfprop
    announcement/trunk/dbflute/doc.bat
    announcement/trunk/dbflute/doc.sh
    announcement/trunk/dbflute/generate.bat
    announcement/trunk/dbflute/generate.sh
    announcement/trunk/dbflute/jdbc.bat
    announcement/trunk/dbflute/jdbc.sh
    announcement/trunk/dbflute/log/
    announcement/trunk/dbflute/log/readme.txt
    announcement/trunk/dbflute/output/
    announcement/trunk/dbflute/output/doc/
    announcement/trunk/dbflute/output/doc/readme.txt
    announcement/trunk/dbflute/outside-sql-test.bat
    announcement/trunk/dbflute/outside-sql-test.sh
    announcement/trunk/dbflute/playsql/
    announcement/trunk/dbflute/playsql/replace-schema.sql
    announcement/trunk/dbflute/replace-schema.bat
    announcement/trunk/dbflute/replace-schema.sh
    announcement/trunk/dbflute/schema/
    announcement/trunk/dbflute/schema/readme.txt
    announcement/trunk/dbflute/sql2entity.bat
    announcement/trunk/dbflute/sql2entity.sh
    announcement/trunk/mydbflute/
    announcement/trunk/mydbflute/readme.txt
    announcement/trunk/pom.xml
    announcement/trunk/src/
    announcement/trunk/src/main/
    announcement/trunk/src/main/config/
    announcement/trunk/src/main/config/clay/
    announcement/trunk/src/main/config/clay/announcement.clay
    announcement/trunk/src/main/config/sql/
    announcement/trunk/src/main/config/sql/mysql/
    announcement/trunk/src/main/config/sql/mysql/announcement.sql
    announcement/trunk/src/main/java/
    announcement/trunk/src/main/java/jp/
    announcement/trunk/src/main/java/jp/sf/
    announcement/trunk/src/main/java/jp/sf/pal/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/AnnouncementConstraints.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/AccessContext.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/BFinder.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/BehaviorSelector.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheAbstractSelector.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheBehaviorSelector.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheDaoSelector.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DBFluteConfig.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoReadable.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoSelector.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoWritable.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/Entity.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/EntityDefinedCommonColumn.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/GenMetaData.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/InternalMapContext.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/QLog.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/XLog.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/annotation/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/annotation/OutsideSql.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/AbstractBehaviorReadable.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/AbstractBehaviorWritable.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/BehaviorReadable.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/BehaviorWritable.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileOutputOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileOutputResult.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionFailure.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionResult.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/load/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/load/LoadRefererOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/load/LoadReferrerOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ConditionBeanSetupper.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/EntityListSetupper.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ValueLabelBox.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ValueLabelSetupper.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/AbstractConditionBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/AbstractConditionQuery.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionBeanContext.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionQuery.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/FetchNarrowingBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/FetchNarrowingBeanContext.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ListResultBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/MapParameterBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/OrderByBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingInvoker.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingResultBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ResultBeanBuilder.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SelectResource.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SimpleOrderByBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SimplePagingBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKey.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyEqual.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyGreaterEqual.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyGreaterThan.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyInScope.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyIsNotNull.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyIsNull.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLessEqual.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLessThan.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLikeSearch.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyNotEqual.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyNotInScope.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyPrefixSearch.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/ConditionOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/DateFromToOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/FromToOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/InScopeOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/LikeSearchOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/SimpleStringOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/SplitOptionParts.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/ToSingleByteOptionParts.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/ToUpperLowerCaseOptionParts.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/local/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/local/JapaneseOptionPartsAgent.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/cvalue/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/cvalue/ConditionValue.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowEndDeterminer.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowResource.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowSetupper.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/mapping/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/mapping/EntityDtoMapper.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlContext.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlDao.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlBasicExecutor.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlCursorExecutor.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlEntityExecutor.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlPagingExecutor.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/PageNumberLink.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/PageNumberLinkSetupper.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/group/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/group/PageGroupBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/group/PageGroupOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/range/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/range/PageRangeBean.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/range/PageRangeOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/AbstractSqlClause.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/OrderByClause.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/OrderByElement.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClause.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDb2.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDefault.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDerby.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseFirebird.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseH2.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseInterbase.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseMySql.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseOracle.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClausePostgreSql.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseSqlServer.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/WhereClauseSimpleFilter.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/AbstractDBMeta.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/DBMeta.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/DBMetaInstanceHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/HierarchyArranger.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/HierarchyBasicRequest.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/HierarchyRequest.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/HierarchyRequestElement.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/HierarchySourceColumn.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/HierarchySourceIterator.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/HierarchySourceRow.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/basic/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/basic/HierarchySourceEntityColumn.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/basic/HierarchySourceEntityListIterator.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/basic/HierarchySourceEntityRow.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/basic/HierarchySourceListIterator.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/hierarchy/basic/HierarchySourceRowSetupper.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/info/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/info/ColumnInfo.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/info/ForeignInfo.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/info/ReferrerInfo.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/info/RelationInfo.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/info/UniqueInfo.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/BindVariableCommentNotFoundPropertyException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/BindVariableParameterNullValueException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/DangerousResultSizeException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/EmbeddedValueCommentNotFoundPropertyException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/EmbeddedValueParameterNullValueException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/EndCommentNotFoundException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/EntityAlreadyDeletedException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/EntityAlreadyUpdatedException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/EntityDuplicatedException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/IfCommentConditionNotFoundException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/IfCommentNotBooleanResultException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/IfCommentWrongExpressionException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/OutsideSqlNotFoundException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/RecordHasAlreadyBeenDeletedException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/RecordHasOverlappedException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/exception/RequiredOptionNotFoundException.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/MapListString.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/MapListStringImpl.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/MapStringBuilder.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/MapStringBuilderImpl.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/character/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/character/GeneralCharacter.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/character/JapaneseCharacter.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/character/impl/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/character/impl/GeneralCharacterImpl.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/character/impl/JapaneseCharacterImpl.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/collection/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/collection/order/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/collection/order/AccordingToOrder.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/collection/order/AccordingToOrderIdExtractor.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/collection/order/AccordingToOrderOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/collection/order/impl/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/collection/order/impl/AccordingToOrderImpl.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/FileMakingCallback.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/FileMakingHeaderInfo.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/FileMakingOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/FileMakingRowResource.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/FileMakingSimpleFacade.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/FileToken.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/FileTokenizingCallback.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/FileTokenizingHeaderInfo.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/FileTokenizingOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/FileTokenizingRowResource.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/impl/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/impl/FileMakingSimpleFacadeImpl.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/file/impl/FileTokenImpl.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/line/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/line/LineMakingOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/line/LineToken.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/line/LineTokenizingOption.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/line/impl/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/helper/token/line/impl/LineTokenImpl.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/jdbc/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/jdbc/CursorHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/jdbc/LatestSqlProvider.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/jdbc/StatementConfig.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/FetchNarrowingResultSetFactory.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/FetchNarrowingResultSetWrapper.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/S2BeanMetaDataFactoryImpl.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/S2DaoInterceptor.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/S2DaoLatestSqlProvider.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/S2DaoMetaDataExtension.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/S2DaoMetaDataFactoryImpl.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/S2DaoPropertyTypeFactoryBuilderExtension.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/S2DaoSelectDynamicCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/rshandler/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/rshandler/InternalBeanArrayMetaDataResultSetHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/rshandler/InternalBeanListMetaDataResultSetHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalAbstractAutoStaticCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalAbstractBatchAutoStaticCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalAbstractDynamicCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalAbstractSqlCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalAbstractStaticCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalDeleteAutoStaticCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalDeleteBatchAutoStaticCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalDeleteQueryAutoDynamicCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalInsertAutoDynamicCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalInsertBatchAutoStaticCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalUpdateAutoDynamicCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalUpdateBatchAutoStaticCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalUpdateDynamicCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlcommand/InternalUpdateModifiedOnlyCommand.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalAbstractAutoHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalAbstractBatchAutoHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalBasicHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalBasicSelectHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalBasicUpdateHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalCommandContextHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalDeleteAutoHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalDeleteBatchAutoHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalInsertAutoHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalInsertBatchAutoHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalUpdateAutoHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlhandler/InternalUpdateBatchAutoHandler.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqllog/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqllog/InternalSqlLog.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqllog/InternalSqlLogRegistry.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlparser/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlparser/InternalCommandContextCreator.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlparser/InternalSqlParser.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/sqlparser/InternalSqlTokenizer.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/util/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/s2dao/internal/util/InternalBindVariableUtil.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/util/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/util/SimpleAssertUtil.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/util/SimpleStringUtil.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/util/SimpleSystemUtil.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/util/TraceViewUtil.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/util/ValueLabelUtil.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsbhv/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsbhv/BsAnnouncementBhv.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsbhv/BsAnnouncementBodyBhv.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsdao/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsdao/BsAnnouncementBodyDao.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsdao/BsAnnouncementDao.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsentity/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsentity/BsAnnouncement.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsentity/BsAnnouncementBody.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsentity/dbmeta/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsentity/dbmeta/AnnouncementBodyDbm.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/bsentity/dbmeta/AnnouncementDbm.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/AnnouncementBodyCB.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/AnnouncementCB.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/bs/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/bs/BsAnnouncementBodyCB.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/bs/BsAnnouncementCB.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/cq/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/cq/AnnouncementBodyCQ.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/cq/AnnouncementCQ.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/cq/bs/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/cq/bs/AbstractBsAnnouncementBodyCQ.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/cq/bs/AbstractBsAnnouncementCQ.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/cq/bs/BsAnnouncementBodyCQ.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/cq/bs/BsAnnouncementCQ.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/cq/ciq/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/cq/ciq/AnnouncementBodyCIQ.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/cq/ciq/AnnouncementCIQ.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/nss/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/nss/AnnouncementBodyNss.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/cbean/nss/AnnouncementNss.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/exbhv/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/exbhv/AnnouncementBhv.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/exbhv/AnnouncementBodyBhv.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/exdao/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/exdao/AnnouncementBodyDao.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/exdao/AnnouncementDao.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/exentity/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/exentity/Announcement.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/db/exentity/AnnouncementBody.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/dxo/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/dxo/AnnouncementDxo.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/filter/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/filter/AnnouncementFilter.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/service/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/service/AnnouncementService.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/web/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/web/edit/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/web/edit/EditContentPage.java
    announcement/trunk/src/main/java/jp/sf/pal/announcement/web/view/
    announcement/trunk/src/main/java/jp/sf/pal/announcement/web/view/DisplayContentPage.java
    announcement/trunk/src/main/resources/
    announcement/trunk/src/main/resources/AMMessages.properties
    announcement/trunk/src/main/resources/app.dicon
    announcement/trunk/src/main/resources/appMessages.properties
    announcement/trunk/src/main/resources/appMessages_ja.properties
    announcement/trunk/src/main/resources/app_aop.dicon
    announcement/trunk/src/main/resources/convention.dicon
    announcement/trunk/src/main/resources/creator.dicon
    announcement/trunk/src/main/resources/customizer.dicon
    announcement/trunk/src/main/resources/dbflute.dicon
    announcement/trunk/src/main/resources/env.txt
    announcement/trunk/src/main/resources/env_ut.txt
    announcement/trunk/src/main/resources/jdbc.dicon
    announcement/trunk/src/main/resources/jp/
    announcement/trunk/src/main/resources/jp/sf/
    announcement/trunk/src/main/resources/jp/sf/pal/
    announcement/trunk/src/main/resources/jp/sf/pal/announcement/
    announcement/trunk/src/main/resources/jp/sf/pal/announcement/web/
    announcement/trunk/src/main/resources/jp/sf/pal/announcement/web/edit/
    announcement/trunk/src/main/resources/jp/sf/pal/announcement/web/edit/label.properties
    announcement/trunk/src/main/resources/jp/sf/pal/announcement/web/edit/label_ja.properties
    announcement/trunk/src/main/resources/s2container.dicon
    announcement/trunk/src/main/resources/teedaCustomize.dicon
    announcement/trunk/src/main/resources/teedaErrorPage.dicon
    announcement/trunk/src/main/webapp/
    announcement/trunk/src/main/webapp/WEB-INF/
    announcement/trunk/src/main/webapp/WEB-INF/faces-config.xml
    announcement/trunk/src/main/webapp/WEB-INF/portlet.xml
    announcement/trunk/src/main/webapp/WEB-INF/web.xml
    announcement/trunk/src/main/webapp/fckeditor/
    announcement/trunk/src/main/webapp/fckeditor/editor/
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckcontextmenu.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckdataprocessor.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckdocumentfragment_gecko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckdocumentfragment_ie.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckdomrange.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckdomrange_gecko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckdomrange_ie.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckdomrangeiterator.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckeditingarea.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckelementpath.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckenterkey.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckevents.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckhtmliterator.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckicon.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckiecleanup.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckimagepreloader.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckkeystrokehandler.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckmenublock.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckmenublockpanel.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckmenuitem.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckpanel.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckplugin.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckspecialcombo.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckstyle.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fcktoolbar.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fcktoolbarbreak_gecko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fcktoolbarbreak_ie.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fcktoolbarbutton.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fcktoolbarbuttonui.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fcktoolbarfontformatcombo.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fcktoolbarfontscombo.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fcktoolbarfontsizecombo.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fcktoolbarpanelbutton.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fcktoolbarspecialcombo.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fcktoolbarstylecombo.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckw3crange.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckxml.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckxml_gecko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/classes/fckxml_ie.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fck_othercommands.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckblockquotecommand.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckcorestylecommand.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckfitwindow.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckindentcommands.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckjustifycommands.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fcklistcommands.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fcknamedcommand.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckpasteplaintextcommand.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckpastewordcommand.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckremoveformatcommand.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckshowblocks.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckspellcheckcommand_gecko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckspellcheckcommand_ie.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fckstylecommand.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fcktablecommand.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/commandclasses/fcktextcolorcommand.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/fckconstants.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/fckeditorapi.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/fckjscoreextensions.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/fckscriptloader.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fck.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fck_contextmenu.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fck_gecko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fck_ie.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckbrowserinfo.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckcodeformatter.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckcommands.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckconfig.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckdebug.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckdebug_empty.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckdialog.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckdocumentprocessor.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckdomtools.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fcklanguagemanager.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fcklisthandler.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fcklistslib.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckplugins.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckregexlib.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckselection.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckselection_gecko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckselection_ie.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckstyles.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fcktablehandler.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fcktablehandler_gecko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fcktablehandler_ie.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fcktoolbaritems.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fcktoolbarset.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fcktools.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fcktools_gecko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fcktools_ie.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckundo.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckurlparams.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckxhtml.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckxhtml_gecko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckxhtml_ie.js
    announcement/trunk/src/main/webapp/fckeditor/editor/_source/internals/fckxhtmlentities.js
    announcement/trunk/src/main/webapp/fckeditor/editor/css/
    announcement/trunk/src/main/webapp/fckeditor/editor/css/behaviors/
    announcement/trunk/src/main/webapp/fckeditor/editor/css/behaviors/disablehandles.htc
    announcement/trunk/src/main/webapp/fckeditor/editor/css/behaviors/showtableborders.htc
    announcement/trunk/src/main/webapp/fckeditor/editor/css/fck_editorarea.css
    announcement/trunk/src/main/webapp/fckeditor/editor/css/fck_internal.css
    announcement/trunk/src/main/webapp/fckeditor/editor/css/fck_showtableborders_gecko.css
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/block_address.png
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/block_blockquote.png
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/block_div.png
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/block_h1.png
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/block_h2.png
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/block_h3.png
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/block_h4.png
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/block_h5.png
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/block_h6.png
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/block_p.png
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/block_pre.png
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/fck_anchor.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/fck_flashlogo.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/fck_hiddenfield.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/fck_pagebreak.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/css/images/fck_plugin.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/common/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/common/fck_dialog_common.css
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/common/fck_dialog_common.js
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/common/images/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/common/images/locked.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/common/images/reset.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/common/images/unlocked.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_about/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_about/logo_fckeditor.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_about/logo_fredck.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_about/sponsors/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_about/sponsors/spellchecker_net.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_about.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_anchor.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_button.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_checkbox.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_colorselector.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_docprops/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_docprops/fck_document_preview.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_docprops.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_flash/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_flash/fck_flash.js
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_flash/fck_flash_preview.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_flash.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_form.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_hiddenfield.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_image/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_image/fck_image.js
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_image/fck_image_preview.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_image.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_link/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_link/fck_link.js
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_link.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_listprop.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_paste.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_radiobutton.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_replace.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_select/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_select/fck_select.js
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_select.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_smiley.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_source.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_specialchar.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/blank.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/controlWindow.js
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/controls.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/server-scripts/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/server-scripts/spellchecker.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/server-scripts/spellchecker.php
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/server-scripts/spellchecker.pl
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/spellChecker.js
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/spellchecker.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/spellerStyle.css
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages/spellerpages/wordWindow.js
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_spellerpages.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_table.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_tablecell.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_template/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_template/images/
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_template/images/template1.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_template/images/template2.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_template/images/template3.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_template.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_textarea.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dialog/fck_textfield.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dtd/
    announcement/trunk/src/main/webapp/fckeditor/editor/dtd/fck_dtd_test.html
    announcement/trunk/src/main/webapp/fckeditor/editor/dtd/fck_xhtml10strict.js
    announcement/trunk/src/main/webapp/fckeditor/editor/dtd/fck_xhtml10transitional.js
    announcement/trunk/src/main/webapp/fckeditor/editor/fckdebug.html
    announcement/trunk/src/main/webapp/fckeditor/editor/fckdialog.html
    announcement/trunk/src/main/webapp/fckeditor/editor/fckeditor.html
    announcement/trunk/src/main/webapp/fckeditor/editor/fckeditor.original.html
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/browser.css
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/browser.html
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/frmactualfolder.html
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/frmcreatefolder.html
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/frmfolders.html
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/frmresourceslist.html
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/frmresourcetype.html
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/frmupload.html
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/ButtonArrow.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/Folder.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/Folder32.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/FolderOpened.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/FolderOpened32.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/FolderUp.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/ai.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/avi.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/bmp.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/cs.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/default.icon.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/dll.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/doc.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/exe.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/fla.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/gif.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/htm.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/html.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/jpg.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/js.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/mdb.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/mp3.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/pdf.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/png.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/ppt.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/rdp.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/swf.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/swt.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/txt.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/vsd.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/xls.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/xml.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/32/zip.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/ai.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/avi.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/bmp.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/cs.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/default.icon.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/dll.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/doc.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/exe.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/fla.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/gif.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/htm.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/html.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/jpg.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/js.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/mdb.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/mp3.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/pdf.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/png.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/ppt.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/rdp.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/swf.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/swt.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/txt.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/vsd.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/xls.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/xml.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/icons/zip.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/images/spacer.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/js/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/js/common.js
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/browser/default/js/fckxml.js
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/asp/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/asp/basexml.asp
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/asp/class_upload.asp
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/asp/commands.asp
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/asp/config.asp
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/asp/connector.asp
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/asp/io.asp
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/asp/upload.asp
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/asp/util.asp
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/aspx/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/aspx/config.ascx
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/aspx/connector.aspx
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/aspx/upload.aspx
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/ImageObject.cfc
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/cf5_connector.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/cf5_upload.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/cf_basexml.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/cf_commands.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/cf_connector.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/cf_io.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/cf_upload.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/cf_util.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/config.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/connector.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/image.cfc
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/cfm/upload.cfm
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/lasso/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/lasso/config.lasso
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/lasso/connector.lasso
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/lasso/upload.lasso
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/perl/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/perl/basexml.pl
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/perl/commands.pl
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/perl/connector.cgi
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/perl/io.pl
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/perl/upload.cgi
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/perl/upload_fck.pl
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/perl/util.pl
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/php/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/php/basexml.php
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/php/commands.php
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/php/config.php
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/php/connector.php
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/php/io.php
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/php/phpcompat.php
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/php/upload.php
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/php/util.php
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/py/
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/py/config.py
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/py/connector.py
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/py/fckcommands.py
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/py/fckconnector.py
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/py/fckoutput.py
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/py/fckutil.py
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/py/htaccess.txt
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/py/upload.py
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/py/wsgi.py
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/py/zope.py
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/test.html
    announcement/trunk/src/main/webapp/fckeditor/editor/filemanager/connectors/uploadtest.html
    announcement/trunk/src/main/webapp/fckeditor/editor/images/
    announcement/trunk/src/main/webapp/fckeditor/editor/images/anchor.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/arrow_ltr.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/arrow_rtl.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/angel_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/angry_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/broken_heart.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/cake.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/confused_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/cry_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/devil_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/embaressed_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/envelope.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/heart.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/kiss.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/lightbulb.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/omg_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/regular_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/sad_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/shades_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/teeth_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/thumbs_down.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/thumbs_up.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/tounge_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/whatchutalkingabout_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/smiley/msn/wink_smile.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/images/spacer.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/js/
    announcement/trunk/src/main/webapp/fckeditor/editor/js/fckadobeair.js
    announcement/trunk/src/main/webapp/fckeditor/editor/js/fckeditorcode_gecko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/js/fckeditorcode_ie.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/_translationstatus.txt
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/af.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/ar.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/bg.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/bn.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/bs.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/ca.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/cs.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/da.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/de.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/el.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/en-au.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/en-ca.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/en-uk.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/en.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/eo.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/es.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/et.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/eu.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/fa.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/fi.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/fo.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/fr-ca.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/fr.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/gl.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/gu.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/he.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/hi.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/hr.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/hu.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/it.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/ja.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/km.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/ko.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/lt.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/lv.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/mn.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/ms.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/nb.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/nl.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/no.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/pl.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/pt-br.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/pt.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/ro.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/ru.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/sk.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/sl.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/sr-latn.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/sr.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/sv.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/th.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/tr.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/uk.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/vi.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/zh-cn.js
    announcement/trunk/src/main/webapp/fckeditor/editor/lang/zh.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/autogrow/
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/autogrow/fckplugin.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/bbcode/
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/bbcode/_sample/
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/bbcode/_sample/sample.config.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/bbcode/_sample/sample.html
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/bbcode/fckplugin.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/dragresizetable/
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/dragresizetable/fckplugin.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/placeholder/
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/placeholder/fck_placeholder.html
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/placeholder/fckplugin.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/placeholder/lang/
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/placeholder/lang/de.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/placeholder/lang/en.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/placeholder/lang/es.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/placeholder/lang/fr.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/placeholder/lang/it.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/placeholder/lang/pl.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/placeholder/placeholder.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/simplecommands/
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/simplecommands/fckplugin.js
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/tablecommands/
    announcement/trunk/src/main/webapp/fckeditor/editor/plugins/tablecommands/fckplugin.js
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/_fckviewstrips.html
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/fck_dialog.css
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/fck_dialog_ie6.js
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/fck_editor.css
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/fck_strip.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/dialog.sides.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/dialog.sides.png
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/dialog.sides.rtl.png
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/sprites.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/sprites.png
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/toolbar.arrowright.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/toolbar.buttonarrow.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/toolbar.collapse.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/toolbar.end.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/toolbar.expand.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/toolbar.separator.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/default/images/toolbar.start.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/fck_dialog.css
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/fck_dialog_ie6.js
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/fck_editor.css
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/fck_strip.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/dialog.sides.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/dialog.sides.png
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/dialog.sides.rtl.png
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/sprites.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/sprites.png
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/toolbar.arrowright.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/toolbar.bg.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/toolbar.buttonarrow.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/toolbar.collapse.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/toolbar.end.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/toolbar.expand.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/toolbar.separator.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/office2003/images/toolbar.start.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/fck_dialog.css
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/fck_dialog_ie6.js
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/fck_editor.css
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/fck_strip.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/dialog.sides.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/dialog.sides.png
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/dialog.sides.rtl.png
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/sprites.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/sprites.png
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/toolbar.arrowright.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/toolbar.buttonarrow.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/toolbar.buttonbg.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/toolbar.collapse.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/toolbar.end.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/toolbar.expand.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/toolbar.separator.gif
    announcement/trunk/src/main/webapp/fckeditor/editor/skins/silver/images/toolbar.start.gif
    announcement/trunk/src/main/webapp/fckeditor/fckconfig.js
    announcement/trunk/src/main/webapp/fckeditor/fckeditor.afp
    announcement/trunk/src/main/webapp/fckeditor/fckeditor.asp
    announcement/trunk/src/main/webapp/fckeditor/fckeditor.cfc
    announcement/trunk/src/main/webapp/fckeditor/fckeditor.cfm
    announcement/trunk/src/main/webapp/fckeditor/fckeditor.js
    announcement/trunk/src/main/webapp/fckeditor/fckeditor.lasso
    announcement/trunk/src/main/webapp/fckeditor/fckeditor.php
    announcement/trunk/src/main/webapp/fckeditor/fckeditor.pl
    announcement/trunk/src/main/webapp/fckeditor/fckeditor.py
    announcement/trunk/src/main/webapp/fckeditor/fckeditor_php4.php
    announcement/trunk/src/main/webapp/fckeditor/fckeditor_php5.php
    announcement/trunk/src/main/webapp/fckeditor/fckpackager.xml
    announcement/trunk/src/main/webapp/fckeditor/fckstyles.xml
    announcement/trunk/src/main/webapp/fckeditor/fcktemplates.xml
    announcement/trunk/src/main/webapp/fckeditor/fckutils.cfm
    announcement/trunk/src/main/webapp/fckeditor/license.txt
    announcement/trunk/src/main/webapp/fckeditor/myconfig.js
    announcement/trunk/src/main/webapp/view/
    announcement/trunk/src/main/webapp/view/edit/
    announcement/trunk/src/main/webapp/view/edit/editContent.html
    announcement/trunk/src/main/webapp/view/error/
    announcement/trunk/src/main/webapp/view/error/error.html
    announcement/trunk/src/main/webapp/view/view/
    announcement/trunk/src/main/webapp/view/view/displayContent.html


-------------- next part --------------
Added: announcement/trunk/.classpath
===================================================================
--- announcement/trunk/.classpath	                        (rev 0)
+++ announcement/trunk/.classpath	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,43 @@
+<classpath>
+  <classpathentry kind="src" path="src/main/java"/>
+  <classpathentry kind="src" path="src/main/resources"/>
+  <classpathentry kind="output" path="target/classes"/>
+  <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+  <classpathentry kind="var" path="M2_REPO/aopalliance/aopalliance/1.0/aopalliance-1.0.jar" sourcepath="M2_REPO/aopalliance/aopalliance/1.0/aopalliance-1.0-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/geronimo/specs/geronimo-ejb_3.0_spec/1.0/geronimo-ejb_3.0_spec-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/portlet-api/portlet-api/1.0/portlet-api-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/seasar/teeda/teeda-ajax/1.0.13-sp2-20080605/teeda-ajax-1.0.13-sp2-20080605.jar" sourcepath="M2_REPO/org/seasar/teeda/teeda-ajax/1.0.13-sp2-20080605/teeda-ajax-1.0.13-sp2-20080605-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jp/sf/pal/common-utils/0.3/common-utils-0.3.jar" sourcepath="M2_REPO/jp/sf/pal/common-utils/0.3/common-utils-0.3-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/servlet/jstl/1.1.2/jstl-1.1.2.jar" sourcepath="M2_REPO/javax/servlet/jstl/1.1.2/jstl-1.1.2-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/seasar/container/s2-tiger/2.4.25/s2-tiger-2.4.25.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/portals/bridges/portals-bridges-portletfilter/1.0.3/portals-bridges-portletfilter-1.0.3.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-io/commons-io/1.3.2/commons-io-1.3.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/seasar/teeda/teeda-extension/1.0.13-sp2-20080605/teeda-extension-1.0.13-sp2-20080605.jar" sourcepath="M2_REPO/org/seasar/teeda/teeda-extension/1.0.13-sp2-20080605/teeda-extension-1.0.13-sp2-20080605-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/junit-addons/junit-addons/1.4/junit-addons-1.4.jar"/>
+  <classpathentry kind="var" path="M2_REPO/xerces/xercesImpl/2.6.2/xercesImpl-2.6.2.jar" sourcepath="M2_REPO/xerces/xercesImpl/2.6.2/xercesImpl-2.6.2-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jp/sf/pal/portlet-output-optimizer/0.2/portlet-output-optimizer-0.2.jar" sourcepath="M2_REPO/jp/sf/pal/portlet-output-optimizer/0.2/portlet-output-optimizer-0.2-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/seasar/container/s2-framework/2.4.25/s2-framework-2.4.25.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/geronimo/specs/geronimo-jta_1.1_spec/1.0/geronimo-jta_1.1_spec-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jp/sf/pal/faces-response-filter/0.2/faces-response-filter-0.2.jar" sourcepath="M2_REPO/jp/sf/pal/faces-response-filter/0.2/faces-response-filter-0.2-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/jboss/javassist/3.4.ga/javassist-3.4.ga.jar"/>
+  <classpathentry kind="var" path="M2_REPO/mysql/mysql-connector-java/5.0.4/mysql-connector-java-5.0.4.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/seasar/container/s2-extension/2.4.25/s2-extension-2.4.25.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-lang/commons-lang/2.4/commons-lang-2.4.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-logging/commons-logging/1.1/commons-logging-1.1.jar" sourcepath="M2_REPO/commons-logging/commons-logging/1.1/commons-logging-1.1-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/javax/servlet/servlet-api/2.3/servlet-api-2.3.jar" sourcepath="M2_REPO/javax/servlet/servlet-api/2.3/servlet-api-2.3-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/geronimo/specs/geronimo-jpa_3.0_spec/1.0/geronimo-jpa_3.0_spec-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/log4j/log4j/1.2.9/log4j-1.2.9.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/seasar/teeda/teeda-core/1.0.13-sp2-20080605/teeda-core-1.0.13-sp2-20080605.jar" sourcepath="M2_REPO/org/seasar/teeda/teeda-core/1.0.13-sp2-20080605/teeda-core-1.0.13-sp2-20080605-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-fileupload/commons-fileupload/1.2/commons-fileupload-1.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/geronimo/specs/geronimo-servlet_2.4_spec/1.0/geronimo-servlet_2.4_spec-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/seasar/teeda/teeda-tiger/1.0.13/teeda-tiger-1.0.13.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/geronimo/specs/geronimo-jsp_2.0_spec/1.0/geronimo-jsp_2.0_spec-1.0.jar"/>
+  <classpathentry kind="var" path="M2_REPO/ognl/ognl/2.6.9-patch-20070908/ognl-2.6.9-patch-20070908.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/seasar/dao/s2-dao-tiger/1.0.48/s2-dao-tiger-1.0.48.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/apache/poi/poi/3.0-FINAL/poi-3.0-FINAL.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/seasar/portlet/s2-portlet/1.0.7/s2-portlet-1.0.7.jar" sourcepath="M2_REPO/org/seasar/portlet/s2-portlet/1.0.7/s2-portlet-1.0.7-sources.jar"/>
+  <classpathentry kind="var" path="M2_REPO/xerces/xmlParserAPIs/2.6.2/xmlParserAPIs-2.6.2.jar"/>
+  <classpathentry kind="var" path="M2_REPO/junit/junit/4.4/junit-4.4.jar"/>
+  <classpathentry kind="var" path="M2_REPO/org/seasar/dao/s2-dao/1.0.48/s2-dao-1.0.48.jar"/>
+  <classpathentry kind="var" path="M2_REPO/commons-el/commons-el/1.0/commons-el-1.0.jar" sourcepath="M2_REPO/commons-el/commons-el/1.0/commons-el-1.0-sources.jar"/>
+</classpath>
\ No newline at end of file


Property changes on: announcement/trunk/.classpath
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/.project
===================================================================
--- announcement/trunk/.project	                        (rev 0)
+++ announcement/trunk/.project	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,15 @@
+<projectDescription>
+  <name>announcement</name>
+  <comment></comment>
+  <projects/>
+  <buildSpec>
+    <buildCommand>
+      <name>org.eclipse.jdt.core.javabuilder</name>
+      <arguments/>
+    </buildCommand>
+  </buildSpec>
+  <natures>
+    <nature>org.eclipse.jdt.core.javanature</nature>
+    <nature>org.seasar.dolteng.eclipse.nature</nature>
+  </natures>
+</projectDescription>
\ No newline at end of file


Property changes on: announcement/trunk/.project
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- announcement/trunk/.settings/org.eclipse.jdt.core.prefs	                        (rev 0)
+++ announcement/trunk/.settings/org.eclipse.jdt.core.prefs	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,259 @@
+#Fri Aug 10 22:15:11 JST 2007
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.compiler.compliance=1.5
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.blank_lines_before_field=1
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.comment.format_block_comments=false
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.lineSplit=80
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation=insert
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+eclipse.preferences.version=1
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=false
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.comment.format_line_comments=false
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.compiler.source=1.5
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert

Added: announcement/trunk/.settings/org.eclipse.jdt.ui.prefs
===================================================================
--- announcement/trunk/.settings/org.eclipse.jdt.ui.prefs	                        (rev 0)
+++ announcement/trunk/.settings/org.eclipse.jdt.ui.prefs	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,5 @@
+#Fri Aug 03 14:46:18 JST 2007
+eclipse.preferences.version=1
+formatter_profile=_Seasar
+formatter_settings_version=11
+org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8"?><templates><template autoinsert\="true" context\="gettercomment_context" deleted\="false" description\="Comment for getter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.gettercomment" name\="gettercomment">/**\n * @return the ${bare_field_name}\n */</template><template autoinsert\="true" context\="settercomment_context" deleted\="false" description\="Comment for setter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.settercomment" name\="settercomment">/**\n * @param ${param} the ${bare_field_name} to set\n */</template><template autoinsert\="true" context\="constructorcomment_context" deleted\="false" description\="Comment for created constructors" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorcomment" name\="constructorcomment">/**\n * ${tags}\n */</template><template autoinsert\="false" context\="filecomment_context" deleted\="false" description\="Comment for created Java files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.filecomment" name\="filecomment">/*\n * Copyright 2005-2007 Portal Application Laboratory Project and the Others.\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n *     http\://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, \n * either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */</template><template autoinsert\="true" context\="typecomment_context" deleted\="false" description\="Comment for created types" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.typecomment" name\="typecomment">/**\n * @author ${user}\n *\n * ${tags}\n */</template><template autoinsert\="true" context\="fieldcomment_context" deleted\="false" description\="Comment for fields" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.fieldcomment" name\="fieldcomment">/**\n * \n */</template><template autoinsert\="true" context\="methodcomment_context" deleted\="false" description\="Comment for non-overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodcomment" name\="methodcomment">/**\n * ${tags}\n */</template><template autoinsert\="true" context\="overridecomment_context" deleted\="false" description\="Comment for overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.overridecomment" name\="overridecomment">/* (non-Javadoc)\n * ${see_to_overridden}\n */</template><template autoinsert\="true" context\="delegatecomment_context" deleted\="false" description\="Comment for delegate methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.delegatecomment" name\="delegatecomment">/**\n * ${tags}\n * ${see_to_target}\n */</template><template autoinsert\="true" context\="newtype_context" deleted\="false" description\="Newly created files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.newtype" name\="newtype">${filecomment}\n${package_declaration}\n\n${typecomment}\n${type_declaration}</template><template autoinsert\="true" context\="classbody_context" deleted\="false" description\="Code in new class type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.classbody" name\="classbody">\n</template><template autoinsert\="true" context\="interfacebody_context" deleted\="false" description\="Code in new interface type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.interfacebody" name\="interfacebody">\n</template><template autoinsert\="true" context\="enumbody_context" deleted\="false" description\="Code in new enum type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.enumbody" name\="enumbody">\n</template><template autoinsert\="true" context\="annotationbody_context" deleted\="false" description\="Code in new annotation type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.annotationbody" name\="annotationbody">\n</template><template autoinsert\="true" context\="catchblock_context" deleted\="false" description\="Code in new catch blocks" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.catchblock" name\="catchblock">// ${todo} Auto-generated catch block\n${exception_var}.printStackTrace();</template><template autoinsert\="true" context\="methodbody_context" deleted\="false" description\="Code in created method stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodbody" name\="methodbody">// ${todo} Auto-generated method stub\n${body_statement}</template><template autoinsert\="true" context\="constructorbody_context" deleted\="false" description\="Code in created constructor stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorbody" name\="constructorbody">${body_statement}\n// ${todo} Auto-generated constructor stub</template><template autoinsert\="true" context\="getterbody_context" deleted\="false" description\="Code in created getters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.getterbody" name\="getterbody">return ${field};</template><template autoinsert\="true" context\="setterbody_context" deleted\="false" description\="Code in created setters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.setterbody" name\="setterbody">${field} \= ${param};</template></templates>

Added: announcement/trunk/.settings/org.seasar.dolteng.eclipse.prefs
===================================================================
--- announcement/trunk/.settings/org.seasar.dolteng.eclipse.prefs	                        (rev 0)
+++ announcement/trunk/.settings/org.seasar.dolteng.eclipse.prefs	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,12 @@
+#Mon May 26 09:54:10 JST 2008
+DaoType=S2Dao
+DefaultDaoPackage=jp.sf.pal.announcement.dao
+DefaultDtoPackage=jp.sf.pal.announcement.dto
+DefaultEntityPackage=jp.sf.pal.announcement.entity
+DefaultResourcePath=/announcement/src/main/resources
+DefaultRootPackage=jp.sf.pal.announcement
+DefaultSrcPath=/announcement/src/main/java
+DefaultWebPackage=jp.sf.pal.announcement.web
+ServletPath=/announcement
+WebContentsRoot=src/main/webapp/
+eclipse.preferences.version=1

Added: announcement/trunk/dbflute/_project.bat
===================================================================
--- announcement/trunk/dbflute/_project.bat	                        (rev 0)
+++ announcement/trunk/dbflute/_project.bat	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,5 @@
+ @ echo off
+
+set MY_PROJECT_NAME=announcement
+
+set DBFLUTE_HOME=..\mydbflute\dbflute-0.7.0


Property changes on: announcement/trunk/dbflute/_project.bat
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/_project.sh
===================================================================
--- announcement/trunk/dbflute/_project.sh	                        (rev 0)
+++ announcement/trunk/dbflute/_project.sh	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+export MY_PROJECT_NAME=announcement
+
+export DBFLUTE_HOME=../mydbflute/dbflute-0.7.0


Property changes on: announcement/trunk/dbflute/_project.sh
___________________________________________________________________
Name: svn:executable
   + *
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/build-announcement.properties
===================================================================
--- announcement/trunk/dbflute/build-announcement.properties	                        (rev 0)
+++ announcement/trunk/dbflute/build-announcement.properties	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,162 @@
+# =======================================================================================
+#                                                                                 for All
+#                                                                                 =======
+
+# -------------------------------------------------------------------
+#  P R O J E C T
+# -------------------------------------------------------------------
+# @FirstProperty
+# @Required
+torque.project = announcement
+
+# -------------------------------------------------------------------
+#  T A R G E T  D A T A B A S E
+# -------------------------------------------------------------------
+# This is the target database, only considered when generating
+# the SQL for your Torque project. Your possible choices are:
+#
+#   axion, cloudscape, db2, db2400, hypersonic, interbase, mssql,
+#   mysql, oracle, postgresql, sapdb, sybase, firebird, derby, h2
+# -------------------------------------------------------------------
+# @FirstProperty
+# @Required
+torque.database = mysql
+
+# -------------------------------------------------------------------
+#  T A R G E T  L A N G U A G E
+# -------------------------------------------------------------------
+# (Default 'java')
+#   The target language. Your possible choices are:
+#     java, csharp
+# -------------------------------------------------------------------
+# @FirstProperty
+#torque.targetLanguage = java
+
+
+
+# =======================================================================================
+#                                                                             for OM task
+#                                                                             ===========
+
+# _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
+#                                                            Basic
+#                                                         _/_/_/_/
+# /---------------------------------------------------------------------------
+# [Output Directory]
+#   java.dir: (Default '../src/main/java')
+#     The base output directory.
+#
+#     If this value is '../src/main/java' and your project stype is under maven,
+#     you don't need to set up this property!
+#
+#     {project}
+#         |
+#         |-dbflute_ldb
+#         |       |-build-ldb.properties
+#         |       |-...
+#         |
+#         |-src/main/java         // *Here!
+#         |-src/main/resources
+#         |-...
+#
+#
+# @FirstProperty
+#torque.java.dir = ../src/main/java
+# ----------------/
+
+# _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
+#                                                          Package
+#                                                             _/_/
+# /---------------------------------------------------------------------------
+# [EntityDao Package]
+#    packageBase: (Default '')
+#      The base directory of package.
+#
+#      *If this property is specified and other package properties is not specified,
+#       Then The packages of generated class are as follows:
+#
+#        ex) packageBase = org.seasar.dbflute.example.dbflute.ldb
+#              baseCommonPackage       --> org.seasar.dbflute.example.dbflute.ldb.allcommon
+#              baseBehaviorPackage     --> org.seasar.dbflute.example.dbflute.ldb.bsbhv
+#              baseDaoPackage          --> org.seasar.dbflute.example.dbflute.ldb.bsdao
+#              baseEntityPackage       --> org.seasar.dbflute.example.dbflute.ldb.bsentity
+#              conditionBeanPackage    --> org.seasar.dbflute.example.dbflute.ldb.cbean
+#              extendedBehaviorPackage --> org.seasar.dbflute.example.dbflute.ldb.exbhv
+#              extendedDaoPackage      --> org.seasar.dbflute.example.dbflute.ldb.exdao
+#              extendedEntityPackage   --> org.seasar.dbflute.example.dbflute.ldb.exentity
+#
+#      *If this property is not specified, you should specify the other package properties.
+#
+#
+#    baseCommonPackage:       (Default Java:'allcommon' C#:'allcommon')
+#    baseBehaviorPackage:     (Default Java:'bsbhv'     C#:'bsbhv')
+#    baseDaoPackage:          (Default Java:'bsdao'     C#:'bsdao')
+#    baseEntityPackage:       (Default Java:'bsentity'  C#:'bsentity')
+#    conditionBeanPackage:    (Default Java:'cbean'     C#:'cbean')
+#    extendedBehaviorPackage: (Default Java:'exbhv'     C#:'exbhv')
+#    extendedDaoPackage:      (Default Java:'exdao'     C#:'exdao')
+#    extendedEntityPackage:   (Default Java:'exentity'  C#:'exentity')
+#
+# @FirstProperty
+torque.packageBase				= jp.sf.pal.announcement.db
+# ----------------/
+
+# _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
+#                                                 S2Dao Adjustment
+#                                                     _/_/_/_/_/_/
+# /---------------------------------------------------------------------------
+# [S2Dao Version]
+#   s2daoVersion: (Default [The latest version])
+#
+# @JavaOnly
+torque.s2daoVersion = 1.0.47
+# ----------------/
+
+
+
+# =======================================================================================
+#                                                                           for JDBC task
+#                                                                           =============
+
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+# [Database Informaition]
+#
+#   * * * * * * * * * * * * * * * * * * * * * * * * *
+#   You shuold use './dfprop/databaseInfoMap.dfprop'
+#   Look the file!
+#   * * * * * * * * * * * * * * * * * * * * * * * * *
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+
+# _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
+#                                                         Adavance
+#                                                             _/_/
+
+# /---------------------------------------------------------------------------
+# [Sequence]
+#   sequenceDefinitionMap: (Default 'map:{}')
+#     The method 'XxxDao#selectNextVal()' is generated for its table primary key.
+#
+#       ex) public String selectNextVal_SQL = "select gen_id(BOOK_BOOK_ID_INC, 1) from RDB$DATABASE";
+#           public java.math.BigDecimal selectNextVal();
+#           // This example is for the database of Firebird
+#
+#   sequenceReturnType: (Default 'java.math.BigDecimal')
+#     The return type of The method 'XxxDao#selectNextVal()'.
+#
+
+#
+# *Apache Derby does not support Sequence-Object.
+#  But I want to test this property.
+#
+#torque.sequenceDefinitionMap	= map:{	\
+#		prodcts	= PRODUCTS_PRODUCTS_ID_INC	\
+#	}
+
+#torque.sequenceReturnType		=	java.lang.Integer
+# [Additional ForeignKey]
+torque.additionalForeignKeyMap = map:{ \
+ FK_ANNOUNCEMENT_BODY = map:{ localTableName = ANNOUNCEMENT_BODY; localColumnName = ID; foreignTableName = ANNOUNCEMENT; foreignColumnName = ID } \
+}
+
+
+


Property changes on: announcement/trunk/dbflute/build-announcement.properties
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/dfprop/databaseInfoMap.dfprop
===================================================================
--- announcement/trunk/dbflute/dfprop/databaseInfoMap.dfprop	                        (rev 0)
+++ announcement/trunk/dbflute/dfprop/databaseInfoMap.dfprop	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,18 @@
+# /---------------------------------------------------------------------------
+# [Database Information]
+#   databaseInfoMap: 
+#     driver   -- The class name of JDBC-Driver.
+#     url      -- The url for connecting database.
+#     schema   -- The schema name.
+#     user     -- The database user name.
+#     password -- The database password.
+#
+# @FirstProperty
+map:{
+	; driver		= com.mysql.jdbc.Driver
+	; url			= jdbc:mysql://localhost/announcement?useUnicode=true&amp;characterEncoding=UTF-8
+	; schema		= announcement
+	; user			= amuser
+	; password		= am123
+}
+# ----------------/

Added: announcement/trunk/dbflute/doc.bat
===================================================================
--- announcement/trunk/dbflute/doc.bat	                        (rev 0)
+++ announcement/trunk/dbflute/doc.bat	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,19 @@
+ @ echo off
+
+%~d0
+cd %~p0
+call _project.bat
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Specify the file path to be used as build-properties.
+rem nnnnnnnnnn/
+set MY_PROPERTIES_PATH=build-%MY_PROJECT_NAME%.properties
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Execute {Document}.
+rem nnnnnnnnnn/
+call %DBFLUTE_HOME%\etc\cmd\_df-doc.cmd %MY_PROPERTIES_PATH%
+
+pause
+
+


Property changes on: announcement/trunk/dbflute/doc.bat
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/doc.sh
===================================================================
--- announcement/trunk/dbflute/doc.sh	                        (rev 0)
+++ announcement/trunk/dbflute/doc.sh	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,14 @@
+#!/bin/sh
+
+. _project.sh
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Specify the file path to be used as build-properties."
+echo "nnnnnnnnnn/"
+export MY_PROPERTIES_PATH=build-${MY_PROJECT_NAME}.properties
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Execute {Document}."
+echo "nnnnnnnnnn/"
+sh $DBFLUTE_HOME/etc/cmd/_df-doc.sh $MY_PROPERTIES_PATH
+


Property changes on: announcement/trunk/dbflute/doc.sh
___________________________________________________________________
Name: svn:executable
   + *
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/generate.bat
===================================================================
--- announcement/trunk/dbflute/generate.bat	                        (rev 0)
+++ announcement/trunk/dbflute/generate.bat	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,19 @@
+ @ echo off
+
+%~d0
+cd %~p0
+call _project.bat
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Specify the file path to be used as build-properties.
+rem nnnnnnnnnn/
+set MY_PROPERTIES_PATH=build-%MY_PROJECT_NAME%.properties
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Execute {Generate}.
+rem nnnnnnnnnn/
+call %DBFLUTE_HOME%\etc\cmd\_df-generate.cmd %MY_PROPERTIES_PATH%
+
+pause
+
+


Property changes on: announcement/trunk/dbflute/generate.bat
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/generate.sh
===================================================================
--- announcement/trunk/dbflute/generate.sh	                        (rev 0)
+++ announcement/trunk/dbflute/generate.sh	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,16 @@
+#!/bin/sh
+
+. _project.sh
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Specify the file path to be used as build-properties."
+echo "nnnnnnnnnn/"
+export MY_PROPERTIES_PATH=build-${MY_PROJECT_NAME}.properties
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Execute {Generate}."
+echo "nnnnnnnnnn/"
+sh $DBFLUTE_HOME/etc/cmd/_df-generate.sh $MY_PROPERTIES_PATH
+
+
+


Property changes on: announcement/trunk/dbflute/generate.sh
___________________________________________________________________
Name: svn:executable
   + *
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/jdbc.bat
===================================================================
--- announcement/trunk/dbflute/jdbc.bat	                        (rev 0)
+++ announcement/trunk/dbflute/jdbc.bat	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,19 @@
+ @ echo off
+
+%~d0
+cd %~p0
+call _project.bat
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Specify the file path to be used as build-properties.
+rem nnnnnnnnnn/
+set MY_PROPERTIES_PATH=build-%MY_PROJECT_NAME%.properties
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Execute {JDBC and Document}.
+rem nnnnnnnnnn/
+call %DBFLUTE_HOME%\etc\cmd\_df-jdbc.cmd %MY_PROPERTIES_PATH%
+
+pause
+
+


Property changes on: announcement/trunk/dbflute/jdbc.bat
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/jdbc.sh
===================================================================
--- announcement/trunk/dbflute/jdbc.sh	                        (rev 0)
+++ announcement/trunk/dbflute/jdbc.sh	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+. _project.sh
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Specify the file path to be used as build-properties."
+echo "nnnnnnnnnn/"
+export MY_PROPERTIES_PATH="build-${MY_PROJECT_NAME}.properties"
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Execute {JDBC and Document}."
+echo "nnnnnnnnnn/"
+sh ${DBFLUTE_HOME}/etc/cmd/_df-jdbc.sh ${MY_PROPERTIES_PATH}
+
+


Property changes on: announcement/trunk/dbflute/jdbc.sh
___________________________________________________________________
Name: svn:executable
   + *
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/log/readme.txt
===================================================================
--- announcement/trunk/dbflute/log/readme.txt	                        (rev 0)
+++ announcement/trunk/dbflute/log/readme.txt	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1 @@
+Directory for LogFile


Property changes on: announcement/trunk/dbflute/log/readme.txt
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/output/doc/readme.txt
===================================================================
--- announcement/trunk/dbflute/output/doc/readme.txt	                        (rev 0)
+++ announcement/trunk/dbflute/output/doc/readme.txt	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1 @@
+Directory for Document


Property changes on: announcement/trunk/dbflute/output/doc/readme.txt
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/outside-sql-test.bat
===================================================================
--- announcement/trunk/dbflute/outside-sql-test.bat	                        (rev 0)
+++ announcement/trunk/dbflute/outside-sql-test.bat	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,19 @@
+ @ echo off
+
+%~d0
+cd %~p0
+call _project.bat
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Specify the file path to be used as build-properties.
+rem nnnnnnnnnn/
+set MY_PROPERTIES_PATH=build-%MY_PROJECT_NAME%.properties
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Execute {Outsite-Sql-Test}.
+rem nnnnnnnnnn/
+call %DBFLUTE_HOME%\etc\cmd\_df-outside-sql-test.cmd %MY_PROPERTIES_PATH%
+
+pause
+
+


Property changes on: announcement/trunk/dbflute/outside-sql-test.bat
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/outside-sql-test.sh
===================================================================
--- announcement/trunk/dbflute/outside-sql-test.sh	                        (rev 0)
+++ announcement/trunk/dbflute/outside-sql-test.sh	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+. _project.sh
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Specify the file path to be used as build-properties."
+echo "nnnnnnnnnn/"
+export MY_PROPERTIES_PATH=build-${MY_PROJECT_NAME}.properties
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Execute {Outsite-Sql-Test}."
+echo "nnnnnnnnnn/"
+sh $DBFLUTE_HOME/etc/cmd/_df-outside-sql-test.sh $MY_PROPERTIES_PATH
+
+


Property changes on: announcement/trunk/dbflute/outside-sql-test.sh
___________________________________________________________________
Name: svn:executable
   + *
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/playsql/replace-schema.sql
===================================================================
--- announcement/trunk/dbflute/playsql/replace-schema.sql	                        (rev 0)
+++ announcement/trunk/dbflute/playsql/replace-schema.sql	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,418 @@
+ALTER TABLE BLACK_ACTION DROP CONSTRAINT FK_BLACK_ACTION_BLACK_LIST
+;
+
+ALTER TABLE BLACK_ACTION DROP CONSTRAINT FK_BLACK_ACTION_LOOKUP
+;
+
+ALTER TABLE BLACK_LIST DROP CONSTRAINT FK_BLACK_LIST_LB_USER
+;
+
+ALTER TABLE BOOK DROP CONSTRAINT FK_BOOK_AUTHOR
+;
+
+ALTER TABLE BOOK DROP CONSTRAINT FK_BOOK_PUBLISHER
+;
+
+ALTER TABLE BOOK DROP CONSTRAINT FK_BOOK_GENRE
+;
+
+ALTER TABLE COLLECTION DROP CONSTRAINT FK_COLLECTION_BOOK
+;
+
+ALTER TABLE COLLECTION DROP CONSTRAINT FK_COLLECTION_LIBRARY
+;
+
+ALTER TABLE COLLECTION_STATUS DROP CONSTRAINT FK_COLLECTION_STATUS_COLLECTION
+;
+
+ALTER TABLE COLLECTION_STATUS DROP CONSTRAINT FK_COLLECTION_STATUS_LOOKUP
+;
+
+ALTER TABLE GENRE DROP CONSTRAINT FK_GENRE_GENRE
+;
+
+ALTER TABLE LB_USER DROP CONSTRAINT FK_LB_USER_LIBRARY
+;
+
+ALTER TABLE LENDING DROP CONSTRAINT FK_LENDING_LIBRARY
+;
+
+ALTER TABLE LENDING DROP CONSTRAINT FK_LENDING_LB_USER
+;
+
+ALTER TABLE LENDING_COLLECTION DROP CONSTRAINT FK_LENDING_COLLECTION_LENDING
+;
+
+ALTER TABLE LENDING_COLLECTION DROP CONSTRAINT FK_LENDING_COLLECTION_COL
+;
+
+ALTER TABLE NEXT_LIBRARY DROP CONSTRAINT FK_NEXT_LIBRARY_LIBRARY_ID
+;
+
+ALTER TABLE NEXT_LIBRARY DROP CONSTRAINT FK_NEXT_LIBRARY_NEXT_LIBRARY_ID
+;
+
+
+DROP TABLE AUTHOR
+;
+DROP TABLE BLACK_ACTION
+;
+DROP TABLE BLACK_ACTION_LOOKUP
+;
+DROP TABLE BLACK_LIST
+;
+DROP TABLE BOOK
+;
+DROP TABLE COLLECTION
+;
+DROP TABLE COLLECTION_STATUS
+;
+DROP TABLE COLLECTION_STATUS_LOOKUP
+;
+DROP TABLE GARBAGE
+;
+DROP TABLE GENRE
+;
+DROP TABLE LB_USER
+;
+DROP TABLE LENDING
+;
+DROP TABLE LENDING_COLLECTION
+;
+DROP TABLE LIBRARY
+;
+DROP TABLE NEXT_LIBRARY
+;
+DROP TABLE PUBLISHER
+;
+
+CREATE TABLE AUTHOR ( 
+	AUTHOR_ID integer NOT NULL GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1),
+	AUTHOR_NAME varchar(80) NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE BLACK_ACTION ( 
+	BLACK_ACTION_ID integer NOT NULL GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1),
+	BLACK_LIST_ID integer NOT NULL,
+	BLACK_ACTION_CODE char(3) NOT NULL,
+	BLACK_LEVEL smallint NOT NULL,
+	EVIDENCE_PHOTOGRAPH blob,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE BLACK_ACTION_LOOKUP ( 
+	BLACK_ACTION_CODE char(3) NOT NULL,
+	BLACK_ACTION_NAME varchar(80) NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE BLACK_LIST ( 
+	BLACK_LIST_ID integer NOT NULL GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1),
+	LB_USER_ID integer NOT NULL,
+	BLACK_RANK char(3) NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE BOOK ( 
+	BOOK_ID integer NOT NULL GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1),
+	ISBN_NO varchar(20) NOT NULL,
+	BOOK_NAME varchar(80) NOT NULL,
+	AUTHOR_ID integer NOT NULL,
+	PUBLISHER_ID integer NOT NULL,
+	MAX_LENDING_DATE_COUNT smallint NOT NULL,
+	GENRE_CODE varchar(12),
+	OPENING_PART clob,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE COLLECTION ( 
+	COLLECTION_ID integer NOT NULL,
+	LIBRARY_ID smallint NOT NULL,
+	BOOK_ID integer NOT NULL,
+	ARRIVAL_DATE timestamp NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE COLLECTION_STATUS ( 
+	COLLECTION_ID integer NOT NULL,
+	COLLECTION_STATUS_CODE char(3) NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE COLLECTION_STATUS_LOOKUP ( 
+	COLLECTION_STATUS_CODE char(3) NOT NULL,
+	COLLECTION_STATUS_NAME varchar(80) NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE GARBAGE ( 
+	GARBAGE_MEMO varchar(50),
+	GARBAGE_TIME timestamp
+)
+;
+
+CREATE TABLE GENRE ( 
+	GENRE_CODE varchar(12) NOT NULL,
+	GENRE_NAME varchar(80) NOT NULL,
+	PARENT_GENRE_CODE varchar(12),
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE LB_USER ( 
+	LB_USER_ID integer NOT NULL GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1),
+	LB_USER_NAME varchar(80) NOT NULL,
+	LIBRARY_ID smallint NOT NULL,
+	USER_PASSWORD varchar(50) NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE LENDING ( 
+	LENDING_ID integer NOT NULL GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1),
+	LIBRARY_ID smallint NOT NULL,
+	LB_USER_ID integer NOT NULL,
+	LENDING_DATE timestamp NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE LENDING_COLLECTION ( 
+	LENDING_ID integer NOT NULL,
+	COLLECTION_ID integer NOT NULL,
+	RETURN_LIMIT_DATE timestamp NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE LIBRARY ( 
+	LIBRARY_ID smallint NOT NULL GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1),
+	LIBRARY_NAME varchar(80) NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE NEXT_LIBRARY ( 
+	LIBRARY_ID smallint NOT NULL,
+	NEXT_LIBRARY_ID smallint NOT NULL,
+	DISTANCE_KM integer NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+CREATE TABLE PUBLISHER ( 
+	PUBLISHER_ID integer NOT NULL GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1),
+	PUBLISHER_NAME varchar(80) NOT NULL,
+	R_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	U_TIME timestamp DEFAULT CURRENT_TIMESTAMP NOT NULL,
+	R_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL,
+	U_STAFF varchar(50) DEFAULT 'DefaultStaff' NOT NULL
+)
+;
+
+
+ALTER TABLE AUTHOR ADD CONSTRAINT PK_AUTHOR 
+	PRIMARY KEY (AUTHOR_ID)
+;
+
+ALTER TABLE BLACK_ACTION ADD CONSTRAINT PK_BLACK_ACTION 
+	PRIMARY KEY (BLACK_ACTION_ID)
+;
+
+ALTER TABLE BLACK_ACTION_LOOKUP ADD CONSTRAINT PK_BLACK_ACTION_LOOKUP 
+	PRIMARY KEY (BLACK_ACTION_CODE)
+;
+
+ALTER TABLE BLACK_LIST ADD CONSTRAINT PK_BLACK_LIST 
+	PRIMARY KEY (BLACK_LIST_ID)
+;
+
+ALTER TABLE BOOK ADD CONSTRAINT PK_BOOK 
+	PRIMARY KEY (BOOK_ID)
+;
+
+ALTER TABLE COLLECTION ADD CONSTRAINT PK_COLLECTION 
+	PRIMARY KEY (COLLECTION_ID)
+;
+
+ALTER TABLE COLLECTION_STATUS ADD CONSTRAINT PK_COLLECTION_STATUS 
+	PRIMARY KEY (COLLECTION_ID)
+;
+
+ALTER TABLE COLLECTION_STATUS_LOOKUP ADD CONSTRAINT PK_COLLECTION_STATUS_LOOKUP 
+	PRIMARY KEY (COLLECTION_STATUS_CODE)
+;
+
+ALTER TABLE GENRE ADD CONSTRAINT PK_GENRE 
+	PRIMARY KEY (GENRE_CODE)
+;
+
+ALTER TABLE LB_USER ADD CONSTRAINT PK_LB_USER 
+	PRIMARY KEY (LB_USER_ID)
+;
+
+ALTER TABLE LENDING ADD CONSTRAINT PK_LENDING 
+	PRIMARY KEY (LENDING_ID)
+;
+
+ALTER TABLE LENDING_COLLECTION ADD CONSTRAINT PK_LENDING_COLLECTION 
+	PRIMARY KEY (LENDING_ID, COLLECTION_ID)
+;
+
+ALTER TABLE LIBRARY ADD CONSTRAINT PK_LIBRARY 
+	PRIMARY KEY (LIBRARY_ID)
+;
+
+ALTER TABLE NEXT_LIBRARY ADD CONSTRAINT PK_NEXT_LIBRARY 
+	PRIMARY KEY (LIBRARY_ID, NEXT_LIBRARY_ID)
+;
+
+ALTER TABLE PUBLISHER ADD CONSTRAINT PK_PUBLISHER 
+	PRIMARY KEY (PUBLISHER_ID)
+;
+
+
+ALTER TABLE BOOK
+	ADD CONSTRAINT UQ_BOOK_ISBN_NO UNIQUE (ISBN_NO)
+;
+
+ALTER TABLE COLLECTION
+	ADD CONSTRAINT UQ_COLLECTION_Primary UNIQUE (LIBRARY_ID, BOOK_ID)
+;
+
+ALTER TABLE LENDING
+	ADD CONSTRAINT UQ_LENDING_Primary UNIQUE (LIBRARY_ID, LB_USER_ID)
+;
+
+ALTER TABLE BLACK_LIST
+	ADD CONSTRAINT UQ_BLACK_LIST_LB_USER_ID UNIQUE (LB_USER_ID)
+;
+
+ALTER TABLE LIBRARY
+	ADD CONSTRAINT UQ_LIBRARY_LIBRARY_NAME UNIQUE (LIBRARY_NAME)
+;
+
+
+
+ALTER TABLE BLACK_ACTION ADD CONSTRAINT FK_BLACK_ACTION_BLACK_LIST 
+	FOREIGN KEY (BLACK_LIST_ID) REFERENCES BLACK_LIST (BLACK_LIST_ID)
+;
+
+ALTER TABLE BLACK_ACTION ADD CONSTRAINT FK_BLACK_ACTION_LOOKUP 
+	FOREIGN KEY (BLACK_ACTION_CODE) REFERENCES BLACK_ACTION_LOOKUP (BLACK_ACTION_CODE)
+;
+
+ALTER TABLE BLACK_LIST ADD CONSTRAINT FK_BLACK_LIST_LB_USER 
+	FOREIGN KEY (LB_USER_ID) REFERENCES LB_USER (LB_USER_ID)
+;
+
+ALTER TABLE BOOK ADD CONSTRAINT FK_BOOK_AUTHOR 
+	FOREIGN KEY (AUTHOR_ID) REFERENCES AUTHOR (AUTHOR_ID)
+;
+
+ALTER TABLE BOOK ADD CONSTRAINT FK_BOOK_PUBLISHER 
+	FOREIGN KEY (PUBLISHER_ID) REFERENCES PUBLISHER (PUBLISHER_ID)
+;
+
+ALTER TABLE BOOK ADD CONSTRAINT FK_BOOK_GENRE 
+	FOREIGN KEY (GENRE_CODE) REFERENCES GENRE (GENRE_CODE)
+;
+
+ALTER TABLE COLLECTION ADD CONSTRAINT FK_COLLECTION_BOOK 
+	FOREIGN KEY (BOOK_ID) REFERENCES BOOK (BOOK_ID)
+;
+
+ALTER TABLE COLLECTION ADD CONSTRAINT FK_COLLECTION_LIBRARY 
+	FOREIGN KEY (LIBRARY_ID) REFERENCES LIBRARY (LIBRARY_ID)
+;
+
+ALTER TABLE COLLECTION_STATUS ADD CONSTRAINT FK_COLLECTION_STATUS_COLLECTION 
+	FOREIGN KEY (COLLECTION_ID) REFERENCES COLLECTION (COLLECTION_ID)
+;
+
+ALTER TABLE COLLECTION_STATUS ADD CONSTRAINT FK_COLLECTION_STATUS_LOOKUP 
+	FOREIGN KEY (COLLECTION_STATUS_CODE) REFERENCES COLLECTION_STATUS_LOOKUP (COLLECTION_STATUS_CODE)
+;
+
+ALTER TABLE GENRE ADD CONSTRAINT FK_GENRE_GENRE 
+	FOREIGN KEY (PARENT_GENRE_CODE) REFERENCES GENRE (GENRE_CODE)
+;
+
+ALTER TABLE LB_USER ADD CONSTRAINT FK_LB_USER_LIBRARY 
+	FOREIGN KEY (LIBRARY_ID) REFERENCES LIBRARY (LIBRARY_ID)
+;
+
+ALTER TABLE LENDING ADD CONSTRAINT FK_LENDING_LIBRARY 
+	FOREIGN KEY (LIBRARY_ID) REFERENCES LIBRARY (LIBRARY_ID)
+;
+
+ALTER TABLE LENDING ADD CONSTRAINT FK_LENDING_LB_USER 
+	FOREIGN KEY (LB_USER_ID) REFERENCES LB_USER (LB_USER_ID)
+;
+
+ALTER TABLE LENDING_COLLECTION ADD CONSTRAINT FK_LENDING_COLLECTION_LENDING 
+	FOREIGN KEY (LENDING_ID) REFERENCES LENDING (LENDING_ID)
+;
+
+ALTER TABLE LENDING_COLLECTION ADD CONSTRAINT FK_LENDING_COLLECTION_COL 
+	FOREIGN KEY (COLLECTION_ID) REFERENCES COLLECTION (COLLECTION_ID)
+;
+
+ALTER TABLE NEXT_LIBRARY ADD CONSTRAINT FK_NEXT_LIBRARY_LIBRARY_ID 
+	FOREIGN KEY (LIBRARY_ID) REFERENCES LIBRARY (LIBRARY_ID)
+;
+
+ALTER TABLE NEXT_LIBRARY ADD CONSTRAINT FK_NEXT_LIBRARY_NEXT_LIBRARY_ID 
+	FOREIGN KEY (NEXT_LIBRARY_ID) REFERENCES LIBRARY (LIBRARY_ID)
+;

Added: announcement/trunk/dbflute/replace-schema.bat
===================================================================
--- announcement/trunk/dbflute/replace-schema.bat	                        (rev 0)
+++ announcement/trunk/dbflute/replace-schema.bat	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,19 @@
+ @ echo off
+
+%~d0
+cd %~p0
+call _project.bat
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Specify the file path to be used as build-properties.
+rem nnnnnnnnnn/
+set MY_PROPERTIES_PATH=build-%MY_PROJECT_NAME%.properties
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Execute {Replace-Schema}.
+rem nnnnnnnnnn/
+call %DBFLUTE_HOME%\etc\cmd\_df-replace-schema.cmd %MY_PROPERTIES_PATH%
+
+pause
+
+


Property changes on: announcement/trunk/dbflute/replace-schema.bat
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/replace-schema.sh
===================================================================
--- announcement/trunk/dbflute/replace-schema.sh	                        (rev 0)
+++ announcement/trunk/dbflute/replace-schema.sh	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+. _project.sh
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Specify the file path to be used as build-properties."
+echo "nnnnnnnnnn/"
+export MY_PROPERTIES_PATH=build-${MY_PROJECT_NAME}.properties
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Execute {Replace-Schema}."
+echo "nnnnnnnnnn/"
+sh $DBFLUTE_HOME/etc/cmd/_df-replace-schema.sh $MY_PROPERTIES_PATH
+
+


Property changes on: announcement/trunk/dbflute/replace-schema.sh
___________________________________________________________________
Name: svn:executable
   + *
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/schema/readme.txt
===================================================================
--- announcement/trunk/dbflute/schema/readme.txt	                        (rev 0)
+++ announcement/trunk/dbflute/schema/readme.txt	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1 @@
+Directory for SchemaFile


Property changes on: announcement/trunk/dbflute/schema/readme.txt
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/sql2entity.bat
===================================================================
--- announcement/trunk/dbflute/sql2entity.bat	                        (rev 0)
+++ announcement/trunk/dbflute/sql2entity.bat	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,19 @@
+ @ echo off
+
+%~d0
+cd %~p0
+call _project.bat
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Specify the file path to be used as build-properties.
+rem nnnnnnnnnn/
+set MY_PROPERTIES_PATH=build-%MY_PROJECT_NAME%.properties
+
+rem /nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
+rem Execute {Invoke Sql Directory}.
+rem nnnnnnnnnn/
+call %DBFLUTE_HOME%\etc\cmd\_df-sql2entity.cmd %MY_PROPERTIES_PATH%
+
+pause
+
+


Property changes on: announcement/trunk/dbflute/sql2entity.bat
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/dbflute/sql2entity.sh
===================================================================
--- announcement/trunk/dbflute/sql2entity.sh	                        (rev 0)
+++ announcement/trunk/dbflute/sql2entity.sh	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+. _project.sh
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Specify the file path to be used as build-properties."
+echo "nnnnnnnnnn/"
+export MY_PROPERTIES_PATH=build-${MY_PROJECT_NAME}.properties
+
+echo "/nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn"
+echo "Execute {Invoke Sql Directory}."
+echo "nnnnnnnnnn/"
+sh $DBFLUTE_HOME/etc/cmd/_df-sql2entity.sh $MY_PROPERTIES_PATH
+
+


Property changes on: announcement/trunk/dbflute/sql2entity.sh
___________________________________________________________________
Name: svn:executable
   + *
Name: svn:eol-style
   + native

Added: announcement/trunk/mydbflute/readme.txt
===================================================================
--- announcement/trunk/mydbflute/readme.txt	                        (rev 0)
+++ announcement/trunk/mydbflute/readme.txt	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,3 @@
+$ mkdir dbflute-0.7.0
+$ cd dbflute-0.7.0
+$ unzip <path>/dbflute-0.7.0.zip


Property changes on: announcement/trunk/mydbflute/readme.txt
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/pom.xml
===================================================================
--- announcement/trunk/pom.xml	                        (rev 0)
+++ announcement/trunk/pom.xml	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,252 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>jp.sf.pal</groupId>
+  <artifactId>announcement</artifactId>
+  <version>1.0-SNAPSHOT</version>
+  <packaging>war</packaging>
+  <name>Announcement Portlet</name>
+  <description/>
+  <url>http://pal.sourceforge.jp/</url>
+  <build>
+    <finalName>announcement</finalName>
+    <defaultGoal>validate</defaultGoal>
+    <pluginManagement>
+      <plugins>
+        <plugin>
+          <artifactId>maven-compiler-plugin</artifactId>
+          <configuration>
+            <source>1.5</source>
+            <target>1.5</target>
+            <encoding>UTF-8</encoding>
+          </configuration>
+        </plugin>
+        <plugin>
+          <artifactId>maven-surefire-plugin</artifactId>
+          <version>2.3</version>
+        </plugin>
+        <plugin>
+          <artifactId>maven-deploy-plugin</artifactId>
+          <configuration>
+            <updateReleaseInfo>true</updateReleaseInfo>
+          </configuration>
+        </plugin>
+        <plugin>
+          <groupId>org.codehaus.mojo</groupId>
+          <artifactId>cobertura-maven-plugin</artifactId>
+          <version>2.0-SNAPSHOT</version>
+          <executions>
+            <execution>
+              <goals>
+                <goal>clean</goal>
+              </goals>
+            </execution>
+          </executions>
+        </plugin>
+      </plugins>
+    </pluginManagement>
+    <plugins>
+      <plugin>
+        <artifactId>maven-source-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>source-jar</id>
+            <phase>package</phase>
+            <goals>
+              <goal>jar</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+  <repositories>
+    <repository>
+      <id>maven.marevol.com</id>
+      <name>Maven2 Repository on marevol.com</name>
+      <url>http://maven2.marevol.com/</url>
+    </repository>
+    <repository>
+      <id>maven.seasar.org</id>
+      <name>The Seasar Foundation Maven2 Repository</name>
+      <url>http://maven.seasar.org/maven2</url>
+    </repository>
+  </repositories>
+  <dependencies>
+    <dependency>
+      <groupId>mysql</groupId>
+      <artifactId>mysql-connector-java</artifactId>
+      <version>5.0.4</version>
+    </dependency>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>4.4</version>
+      <scope>compile</scope>
+    </dependency>
+    <dependency>
+      <groupId>junit-addons</groupId>
+      <artifactId>junit-addons</artifactId>
+      <version>1.4</version>
+      <scope>compile</scope>
+    </dependency>
+<!-- SERVLET DEV: BEGIN @@@
+    <dependency>
+      <groupId>jp.sf.pal</groupId>
+      <artifactId>faces-dev-filter</artifactId>
+      <version>0.1</version>
+      <scope>compile</scope>
+    </dependency>
+@@@@ SERVLET DEV: END -->
+    <dependency>
+      <groupId>javax.servlet</groupId>
+      <artifactId>servlet-api</artifactId>
+      <version>2.3</version>
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>portlet-api</groupId>
+      <artifactId>portlet-api</artifactId>
+      <version>1.0</version>
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.geronimo.specs</groupId>
+      <artifactId>geronimo-jsp_2.0_spec</artifactId>
+      <version>1.0</version>
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.geronimo.specs</groupId>
+      <artifactId>geronimo-servlet_2.4_spec</artifactId>
+      <version>1.0</version>
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.geronimo.specs</groupId>
+      <artifactId>geronimo-jta_1.1_spec</artifactId>
+      <version>1.0</version>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.geronimo.specs</groupId>
+      <artifactId>geronimo-ejb_3.0_spec</artifactId>
+      <version>1.0</version>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.geronimo.specs</groupId>
+      <artifactId>geronimo-jpa_3.0_spec</artifactId>
+      <version>1.0</version>
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.seasar.container</groupId>
+      <artifactId>s2-framework</artifactId>
+      <version>2.4.25</version>
+    </dependency>
+    <dependency>
+      <groupId>org.seasar.container</groupId>
+      <artifactId>s2-extension</artifactId>
+      <version>2.4.25</version>
+      <exclusions>
+        <exclusion>
+          <groupId>log4j</groupId>
+          <artifactId>log4j</artifactId>
+        </exclusion>
+      </exclusions>
+    </dependency>
+    <dependency>
+      <groupId>org.seasar.container</groupId>
+      <artifactId>s2-tiger</artifactId>
+      <version>2.4.25</version>
+      <exclusions>
+        <exclusion>
+          <groupId>org.easymock</groupId>
+          <artifactId>easymock</artifactId>
+        </exclusion>
+      </exclusions>
+    </dependency>
+    <dependency>
+      <groupId>org.seasar.teeda</groupId>
+      <artifactId>teeda-extension</artifactId>
+      <version>1.0.13-sp2-20080605</version>
+    </dependency>
+    <dependency>
+      <groupId>org.seasar.teeda</groupId>
+      <artifactId>teeda-tiger</artifactId>
+      <version>1.0.13</version>
+    </dependency>
+    <dependency>
+      <groupId>org.seasar.portlet</groupId>
+      <artifactId>s2-portlet</artifactId>
+      <version>1.0.7</version>
+    </dependency>
+    <dependency>
+      <groupId>org.seasar.dao</groupId>
+      <artifactId>s2-dao</artifactId>
+      <version>1.0.48</version>
+    </dependency>
+    <dependency>
+      <groupId>org.seasar.dao</groupId>
+      <artifactId>s2-dao-tiger</artifactId>
+      <version>1.0.48</version>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.portals.bridges</groupId>
+      <artifactId>portals-bridges-portletfilter</artifactId>
+      <version>1.0.3</version>
+      <exclusions>
+        <exclusion>
+          <groupId>logkit</groupId>
+          <artifactId>logkit</artifactId>
+        </exclusion>
+        <exclusion>
+          <groupId>avalon-framework</groupId>
+          <artifactId>avalon-framework</artifactId>
+        </exclusion>
+        <exclusion>
+          <groupId>javax.servlet</groupId>
+          <artifactId>servlet-api</artifactId>
+        </exclusion>
+        <exclusion>
+          <groupId>log4j</groupId>
+          <artifactId>log4j</artifactId>
+        </exclusion>
+      </exclusions>
+    </dependency>
+    <dependency>
+      <groupId>jp.sf.pal</groupId>
+      <artifactId>faces-response-filter</artifactId>
+      <version>0.2</version>
+    </dependency>
+    <dependency>
+      <groupId>jp.sf.pal</groupId>
+      <artifactId>portlet-output-optimizer</artifactId>
+      <version>0.2</version>
+    </dependency>
+    <dependency>
+      <groupId>jp.sf.pal</groupId>
+      <artifactId>common-utils</artifactId>
+      <version>0.3</version>
+    </dependency>
+    <dependency>
+      <groupId>log4j</groupId>
+      <artifactId>log4j</artifactId>
+      <version>1.2.9</version>
+    </dependency>
+    <dependency>
+      <groupId>xerces</groupId>
+      <artifactId>xercesImpl</artifactId>
+      <version>2.6.2</version>
+    </dependency>
+    <dependency>
+      <groupId>xerces</groupId>
+      <artifactId>xmlParserAPIs</artifactId>
+      <version>2.6.2</version>
+    </dependency>
+    <dependency>
+      <groupId>commons-lang</groupId>
+      <artifactId>commons-lang</artifactId>
+      <version>2.4</version>
+    </dependency>
+  </dependencies>
+</project>


Property changes on: announcement/trunk/pom.xml
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/config/clay/announcement.clay
===================================================================
--- announcement/trunk/src/main/config/clay/announcement.clay	                        (rev 0)
+++ announcement/trunk/src/main/config/clay/announcement.clay	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,133 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<clay-model clay-version="1.4.1">
+<database-model alias="" author="" begin-script="" end-script="" name="announcement" remarks="" sql-dialect-id="jp.azzurri.clay.dialect.MySQL_5_0_Dialect" uid="5dd26f:11acc05462b:-8000" version="1.0">
+<database-model-description></database-model-description>
+<schema-list>
+<schema alias="" name="DEFAULT_SCHEMA" remarks="" uid="5dd26f:11acc05462b:-7ffd">
+<schema-description></schema-description>
+<domain-list/>
+<table-list>
+<table alias="Announcement" name="ANNOUNCEMENT" remarks="" uid="5dd26f:11acc05462b:-7fff">
+<table-description></table-description>
+<table-figure-bounds height="-1" width="-1" x="128" y="179"/>
+<column-list>
+<column alias="Id" auto-increment="true" column-size="0" decimal-digits="0" default-value="" mandatory="true" name="ID" remarks="" uid="5dd26f:11acc05462b:-7ffa">
+<column-description></column-description>
+<data-type jdbc-type="4" name="INTEGER" selected-variant-pattern="INTEGER">
+<variant type-name-pattern="INTEGER"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n)"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n) UNSIGNED"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n) UNSIGNED ZEROFILL"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n) ZEROFILL"/>
+<variant type-name-pattern="INTEGER UNSIGNED"/>
+<variant type-name-pattern="INTEGER UNSIGNED ZEROFILL"/>
+<variant type-name-pattern="INTEGER ZEROFILL"/>
+</data-type>
+</column>
+<column alias="Scope" auto-increment="false" column-size="20" decimal-digits="0" default-value="" mandatory="true" name="SCOPE" remarks="" uid="5dd26f:11acc05462b:-7ff9">
+<column-description></column-description>
+<data-type jdbc-type="12" literal-prefix="'" literal-suffix="'" name="VARCHAR" selected-variant-pattern="VARCHAR(%n)">
+<variant precision-max="255" precision-min="1" precision-variable="%n" type-name-pattern="VARCHAR(%n)"/>
+<variant precision-max="255" precision-min="1" precision-variable="%n" type-name-pattern="VARCHAR(%n) BINARY"/>
+</data-type>
+</column>
+<column alias="Role" auto-increment="false" column-size="100" decimal-digits="0" default-value="" mandatory="false" name="ROLE" remarks="" uid="5dd26f:11acc05462b:-7ff8">
+<column-description></column-description>
+<data-type jdbc-type="12" literal-prefix="'" literal-suffix="'" name="VARCHAR" selected-variant-pattern="VARCHAR(%n)">
+<variant precision-max="255" precision-min="1" precision-variable="%n" type-name-pattern="VARCHAR(%n)"/>
+<variant precision-max="255" precision-min="1" precision-variable="%n" type-name-pattern="VARCHAR(%n) BINARY"/>
+</data-type>
+</column>
+<column alias="Start Date" auto-increment="false" column-size="0" decimal-digits="0" default-value="" mandatory="false" name="START_DATE" remarks="" uid="5dd26f:11acc05462b:-7ff7">
+<column-description></column-description>
+<data-type jdbc-type="93" literal-prefix="'" literal-suffix="'" name="DATETIME" selected-variant-pattern="DATETIME">
+<variant type-name-pattern="DATETIME"/>
+</data-type>
+</column>
+<column alias="End Date" auto-increment="false" column-size="0" decimal-digits="0" default-value="" mandatory="false" name="END_DATE" remarks="" uid="5dd26f:11acc05462b:-7ff6">
+<column-description></column-description>
+<data-type jdbc-type="93" literal-prefix="'" literal-suffix="'" name="DATETIME" selected-variant-pattern="DATETIME">
+<variant type-name-pattern="DATETIME"/>
+</data-type>
+</column>
+<column alias="Title" auto-increment="false" column-size="100" decimal-digits="0" default-value="" mandatory="true" name="TITLE" remarks="" uid="5dd26f:11acc05462b:-7ff3">
+<column-description></column-description>
+<data-type jdbc-type="12" literal-prefix="'" literal-suffix="'" name="VARCHAR" selected-variant-pattern="VARCHAR(%n)">
+<variant precision-max="255" precision-min="1" precision-variable="%n" type-name-pattern="VARCHAR(%n)"/>
+<variant precision-max="255" precision-min="1" precision-variable="%n" type-name-pattern="VARCHAR(%n) BINARY"/>
+</data-type>
+</column>
+<column alias="Sort Order" auto-increment="false" column-size="0" decimal-digits="0" default-value="" mandatory="true" name="SORT_ORDER" remarks="" uid="194b86d:11ad0db09a1:-7fc7">
+<column-description></column-description>
+<data-type jdbc-type="4" name="INTEGER" selected-variant-pattern="INTEGER">
+<variant type-name-pattern="INTEGER"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n)"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n) UNSIGNED"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n) UNSIGNED ZEROFILL"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n) ZEROFILL"/>
+<variant type-name-pattern="INTEGER UNSIGNED"/>
+<variant type-name-pattern="INTEGER UNSIGNED ZEROFILL"/>
+<variant type-name-pattern="INTEGER ZEROFILL"/>
+</data-type>
+</column>
+<column alias="Timestamp" auto-increment="false" column-size="0" decimal-digits="0" default-value="" mandatory="true" name="TIMESTAMP" remarks="" uid="194b86d:11ad0db09a1:-7fc0">
+<column-description></column-description>
+<data-type jdbc-type="93" literal-prefix="'" literal-suffix="'" name="TIMESTAMP" selected-variant-pattern="TIMESTAMP">
+<variant type-name-pattern="TIMESTAMP"/>
+<variant precision-max="14" precision-min="0" precision-variable="%n" type-name-pattern="TIMESTAMP(%n)"/>
+</data-type>
+</column>
+</column-list>
+<primary-key alias="" name="PK_ANNOUNCEMENT" remarks="" uid="5dd26f:11acc05462b:-7ffe">
+<primary-key-description></primary-key-description>
+<primary-key-column name="ID"/>
+</primary-key>
+<unique-key-list/>
+<foreign-key-list/>
+<index-list/>
+</table>
+<table alias="" name="ANNOUNCEMENT_BODY" remarks="" uid="194b86d:11ad0db09a1:-7fff">
+<table-description></table-description>
+<table-figure-bounds height="-1" width="-1" x="509" y="222"/>
+<column-list>
+<column alias="Id" auto-increment="false" column-size="0" decimal-digits="0" default-value="" mandatory="true" name="ID" remarks="" uid="194b86d:11ad0db09a1:-7ffb">
+<column-description></column-description>
+<data-type jdbc-type="4" name="INTEGER" selected-variant-pattern="INTEGER">
+<variant type-name-pattern="INTEGER"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n)"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n) UNSIGNED"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n) UNSIGNED ZEROFILL"/>
+<variant precision-max="10" precision-min="0" precision-variable="%n" type-name-pattern="INTEGER(%n) ZEROFILL"/>
+<variant type-name-pattern="INTEGER UNSIGNED"/>
+<variant type-name-pattern="INTEGER UNSIGNED ZEROFILL"/>
+<variant type-name-pattern="INTEGER ZEROFILL"/>
+</data-type>
+</column>
+<column alias="Content" auto-increment="false" column-size="0" decimal-digits="0" default-value="" mandatory="true" name="CONTENT" remarks="" uid="194b86d:11ad0db09a1:-7ffa">
+<column-description></column-description>
+<data-type jdbc-type="-1" literal-prefix="'" literal-suffix="'" name="TEXT" selected-variant-pattern="TEXT">
+<variant type-name-pattern="TEXT"/>
+</data-type>
+</column>
+</column-list>
+<primary-key alias="" name="PK_ANNOUNCEMENT_BODY" remarks="" uid="194b86d:11ad0db09a1:-7ffe">
+<primary-key-description></primary-key-description>
+<primary-key-column name="ID"/>
+</primary-key>
+<unique-key-list/>
+<foreign-key-list>
+<foreign-key alias="" name="FK_ANNOUNCEMENT_BODY" on-delete="CASCADE" on-update="" referenced-key="PK_ANNOUNCEMENT" referenced-table="ANNOUNCEMENT" referenced-table-schema="DEFAULT_SCHEMA" remarks="" source-entity-role="" source-multiplicity="1" source-relationship-type="" target-entity-role="" target-multiplicity="1" target-relationship-type="" uid="194b86d:11ad0db09a1:-7fea">
+<foreign-key-description></foreign-key-description>
+<foreign-key-figure>
+<fk-fig-bendpoint-list/>
+</foreign-key-figure>
+<foreign-key-column column-name="ID" referenced-key-column-name="ID"/>
+</foreign-key>
+</foreign-key-list>
+<index-list/>
+</table>
+</table-list>
+</schema>
+</schema-list>
+</database-model>
+</clay-model>

Added: announcement/trunk/src/main/config/sql/mysql/announcement.sql
===================================================================
--- announcement/trunk/src/main/config/sql/mysql/announcement.sql	                        (rev 0)
+++ announcement/trunk/src/main/config/sql/mysql/announcement.sql	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,29 @@
+DROP TABLE IF EXISTS ANNOUNCEMENT_BODY;
+DROP TABLE IF EXISTS ANNOUNCEMENT;
+
+CREATE TABLE ANNOUNCEMENT (
+       ID INTEGER NOT NULL AUTO_INCREMENT
+     , SCOPE VARCHAR(20) NOT NULL
+     , ROLE VARCHAR(100)
+     , START_DATE DATETIME
+     , END_DATE DATETIME
+     , TITLE VARCHAR(100) NOT NULL
+     , SORT_ORDER INTEGER NOT NULL
+     , TIMESTAMP TIMESTAMP NOT NULL
+     , PRIMARY KEY (ID)
+);
+
+CREATE TABLE ANNOUNCEMENT_BODY (
+       ID INTEGER NOT NULL
+     , CONTENT TEXT NOT NULL
+     , PRIMARY KEY (ID)
+);
+
+ALTER TABLE ANNOUNCEMENT_BODY
+  ADD CONSTRAINT FK_ANNOUNCEMENT_BODY
+      FOREIGN KEY (ID)
+      REFERENCES ANNOUNCEMENT (ID)
+   ON DELETE CASCADE;
+
+alter table ANNOUNCEMENT Type=InnoDB;
+

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/AnnouncementConstraints.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/AnnouncementConstraints.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/AnnouncementConstraints.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,13 @@
+package jp.sf.pal.announcement;
+
+public class AnnouncementConstraints {
+
+    public static final String DEFAULT_SCOPE = "DEFAULT";
+
+    public static final String SCOPE_KEY = "scope";
+
+    public static final long MIN_DATE = 0;
+
+    public static final long MAX_DATE = 92464556400000L;// 4900/02/01?
+
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/AnnouncementConstraints.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/AccessContext.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/AccessContext.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/AccessContext.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,267 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+/**
+ * Access-Context.
+ * <p>
+ * This access-context on the thread should be initialized at the beginning of access.
+ * The access is various. Web-Access, Batch-Access, JUnit-Access and so on...
+ * </p>
+ * @author DBFlute(AutoGenerator)
+ */
+public class AccessContext {
+
+    // ===================================================================================
+    //                                                                        Thread Local
+    //                                                                        ============
+    /** The thread-local for this. */
+    private static final ThreadLocal<AccessContext> threadLocal = new ThreadLocal<AccessContext>();
+
+    /**
+     * Get access-context on thread.
+     * @return Access-context. (Nullable)
+     */
+    public static AccessContext getAccessContextOnThread() {
+        return (AccessContext) threadLocal.get();
+    }
+
+    /**
+     * Set access-context on thread.
+     * @param accessContext Access-context. (NotNull)
+     */
+    public static void setAccessContextOnThread(AccessContext accessContext) {
+        if (accessContext == null) {
+            String msg = "The argument[accessContext] must not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+        threadLocal.set(accessContext);
+    }
+
+    /**
+     * Is existing access-context on thread?
+     * @return Determination.
+     */
+    public static boolean isExistAccessContextOnThread() {
+        return (threadLocal.get() != null);
+    }
+
+    /**
+     * Clear access-context on thread.
+     */
+    public static void clearAccessContextOnThread() {
+        threadLocal.set(null);
+    }
+
+    // ===================================================================================
+    //                                                                  Access Information
+    //                                                                  ==================
+    /**
+     * Get access user on thread.
+     * <p>
+     * If it can't get access user from access-context, 
+     * returns 'Anonymous' as default value!
+     * </p>
+     * @return Access user. (NotNull)
+     */
+    public static String getAccessUserOnThread() {
+        if (isExistAccessContextOnThread()) {
+            final AccessContext userContextOnThread = getAccessContextOnThread();
+            final String accessUser = userContextOnThread.getAccessUser();
+            if (accessUser != null) {
+                return accessUser;
+            }
+        }
+        return "Anonymous";// as Default
+    }
+
+    /**
+     * Get access process on thread.
+     * <p>
+     * If it can't get access process from access-context, 
+     * returns 'Anonymous' as default value!
+     * </p>
+     * @return Access process. (NotNull)
+     */
+    public static String getAccessProcessOnThread() {
+        if (isExistAccessContextOnThread()) {
+            final AccessContext userContextOnThread = getAccessContextOnThread();
+            final String accessProcess = userContextOnThread.getAccessProcess();
+            if (accessProcess != null) {
+                return accessProcess;
+            }
+        }
+        return "Anonymous";// as Default
+    }
+
+    /**
+     * Get access module on thread.
+     * <p>
+     * If it can't get access module from access-context, 
+     * returns 'Anonymous' as default value!
+     * </p>
+     * @return Access module. (NotNull)
+     */
+    public static String getAccessModuleOnThread() {
+        if (isExistAccessContextOnThread()) {
+            final AccessContext userContextOnThread = getAccessContextOnThread();
+            final String accessModule = userContextOnThread.getAccessModule();
+            if (accessModule != null) {
+                return accessModule;
+            }
+        }
+        return "Anonymous";// as Default
+    }
+
+    /**
+     * Get access date on thread.
+     * <p>
+     * If it can't get access date from access-context, 
+     * returns application current time as default value!
+     * </p>
+     * @return Access date. (NotNull)
+     */
+    public static java.util.Date getAccessDateOnThread() {
+        if (isExistAccessContextOnThread()) {
+            final AccessContext userContextOnThread = getAccessContextOnThread();
+            final java.util.Date accessDate = userContextOnThread
+                    .getAccessDate();
+            if (accessDate != null) {
+                return accessDate;
+            }
+            if (userContextOnThread.getAccessDateProvider() != null) {
+                return userContextOnThread.getAccessDateProvider()
+                        .getAccessDate();
+            }
+        }
+        return new java.util.Date();// as Default
+    }
+
+    /**
+     * Get access timestamp on thread.
+     * <p>
+     * If it can't get access timestamp from access-context, 
+     * returns application current time as default value!
+     * </p>
+     * @return Access timestamp. (NotNull)
+     */
+    public static java.sql.Timestamp getAccessTimestampOnThread() {
+        if (isExistAccessContextOnThread()) {
+            final AccessContext userContextOnThread = getAccessContextOnThread();
+            final java.sql.Timestamp accessTimestamp = userContextOnThread
+                    .getAccessTimestamp();
+            if (accessTimestamp != null) {
+                return accessTimestamp;
+            }
+            if (userContextOnThread.getAccessTimestampProvider() != null) {
+                return userContextOnThread.getAccessTimestampProvider()
+                        .getAccessTimestamp();
+            }
+        }
+        return new java.sql.Timestamp(System.currentTimeMillis());// as Default
+    }
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected String accessUser;
+
+    protected String accessProcess;
+
+    protected String accessModule;
+
+    protected java.util.Date accessDate;
+
+    protected AccessDateProvider accessDateProvider;
+
+    protected java.sql.Timestamp accessTimestamp;
+
+    protected AccessTimestampProvider accessTimestampProvider;
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    public String getAccessUser() {
+        return accessUser;
+    }
+
+    public void setAccessUser(String accessUser) {
+        this.accessUser = accessUser;
+    }
+
+    public String getAccessProcess() {
+        return accessProcess;
+    }
+
+    public void setAccessProcess(String accessProcess) {
+        this.accessProcess = accessProcess;
+    }
+
+    public String getAccessModule() {
+        return accessModule;
+    }
+
+    public void setAccessModule(String accessModule) {
+        this.accessModule = accessModule;
+    }
+
+    public java.util.Date getAccessDate() {
+        return accessDate;
+    }
+
+    public void setAccessDate(java.util.Date accessDate) {
+        this.accessDate = accessDate;
+    }
+
+    public AccessDateProvider getAccessDateProvider() {
+        return accessDateProvider;
+    }
+
+    public void setAccessDateProvider(AccessDateProvider accessDateProvider) {
+        this.accessDateProvider = accessDateProvider;
+    }
+
+    public java.sql.Timestamp getAccessTimestamp() {
+        return accessTimestamp;
+    }
+
+    public void setAccessTimestamp(java.sql.Timestamp accessTimestamp) {
+        this.accessTimestamp = accessTimestamp;
+    }
+
+    public AccessTimestampProvider getAccessTimestampProvider() {
+        return accessTimestampProvider;
+    }
+
+    public void setAccessTimestampProvider(
+            AccessTimestampProvider accessTimestampProvider) {
+        this.accessTimestampProvider = accessTimestampProvider;
+    }
+
+    // ===================================================================================
+    //                                                                  Provider Interface
+    //                                                                  ==================
+    /**
+     * The provider interface of access date.
+     */
+    public static interface AccessDateProvider {
+
+        /**
+         * Get access date.
+         * 
+         * @return Access date. (NotNull)
+         */
+        public java.util.Date getAccessDate();
+    }
+
+    /**
+     * The provider interface of access date.
+     */
+    public static interface AccessTimestampProvider {
+
+        /**
+         * Get access timestamp.
+         * 
+         * @return Access timestamp. (NotNull)
+         */
+        public java.sql.Timestamp getAccessTimestamp();
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/AccessContext.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/BFinder.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/BFinder.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/BFinder.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,102 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+import jp.sf.pal.announcement.db.allcommon.bhv.BehaviorReadable;
+
+/**
+ * The entry of DBFlute.
+ * @author DBFlute(AutoGenerator)
+ */
+ @ SuppressWarnings("unchecked")
+public class BFinder {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    protected static String _dbfluteDiconName = "dbflute.dicon";
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    private BFinder() {
+    }
+
+    // ===================================================================================
+    //                                                                              Finder
+    //                                                                             ======
+    public static <BEHAVIOR_TYPE extends BehaviorReadable> BEHAVIOR_TYPE find(
+            Class<BEHAVIOR_TYPE> behaviorType) {
+        assertObjectNotNull("behaviorType", behaviorType);
+        if (!org.seasar.framework.container.factory.SingletonS2ContainerFactory
+                .hasContainer()) {
+            synchronized (BFinder.class) {
+                if (!org.seasar.framework.container.factory.SingletonS2ContainerFactory
+                        .hasContainer()) {
+                    final String configFile = _dbfluteDiconName;
+                    if (org.seasar.framework.util.ResourceUtil
+                            .isExist(configFile)) {
+                        org.seasar.framework.container.factory.SingletonS2ContainerFactory
+                                .setConfigPath(configFile);
+                        org.seasar.framework.container.factory.SingletonS2ContainerFactory
+                                .init();
+                    } else {
+                        String msg = "S2Container is not initialized! Confirm your initializer and your dicon files.";
+                        throw new IllegalStateException(msg);
+                    }
+                }
+            }
+        }
+        final org.seasar.framework.container.S2Container container = org.seasar.framework.container.factory.SingletonS2ContainerFactory
+                .getContainer();
+        final BEHAVIOR_TYPE behavior = (BEHAVIOR_TYPE) container
+                .getComponent(behaviorType);
+        return behavior;
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    public static void setDBFluteDiconName(String dbfluteDiconName) {
+        _dbfluteDiconName = dbfluteDiconName;
+    }
+
+    // ===================================================================================
+    //                                                                      General Helper
+    //                                                                      ==============
+    /**
+     * Assert that the object is not null.
+     * @param variableName Variable name. (NotNull)
+     * @param value Value. (NotNull)
+     * @exception IllegalArgumentException
+     */
+    protected static void assertObjectNotNull(String variableName, Object value) {
+        if (variableName == null) {
+            String msg = "The value should not be null: variableName="
+                    + variableName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+        if (value == null) {
+            String msg = "The value should not be null: variableName="
+                    + variableName;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    // ----------------------------------------------------------------
+    //                                                    Assert String
+    //                                                    -------------
+    /**
+     * Assert that the entity is not null and not trimmed empty.
+     * @param variableName Variable name. (NotNull)
+     * @param value Value. (NotNull)
+     */
+    protected void assertStringNotNullAndNotTrimmedEmpty(String variableName,
+            String value) {
+        assertObjectNotNull("variableName", variableName);
+        assertObjectNotNull("value", value);
+        if (value.trim().length() == 0) {
+            String msg = "The value should not be empty: variableName="
+                    + variableName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/BFinder.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/BehaviorSelector.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/BehaviorSelector.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/BehaviorSelector.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,32 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+import jp.sf.pal.announcement.db.allcommon.bhv.BehaviorReadable;
+
+/**
+ * The interface of behavior-selector.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface BehaviorSelector {
+
+    /**
+     * Initialize condition-bean meta data. <br />
+     * If you call this, Hot Deploy of OutsideSql becomes Cool!
+     */
+    public void initializeConditionBeanMetaData();
+
+    /**
+     * Select behavior.
+     * @param <BEHAVIOR_TYPE> The type of behavior.
+     * @param behaviorType Behavior type. (NotNull)
+     * @return Behavior. (NotNull)
+     */
+    public <BEHAVIOR_TYPE extends BehaviorReadable> BEHAVIOR_TYPE select(
+            Class<BEHAVIOR_TYPE> behaviorType);
+
+    /**
+     * Select behavior-readable.
+     * @param tableFlexibleName Table flexible-name. (NotNull)
+     * @return Behavior-readable. (NotNull)
+     */
+    public BehaviorReadable byName(String tableFlexibleName);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/BehaviorSelector.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheAbstractSelector.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheAbstractSelector.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheAbstractSelector.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,91 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+import org.seasar.framework.container.S2Container;
+
+/**
+ * The abstract class of cache-selector.
+ * @author DBFlute(AutoGenerator)
+ */
+ @ SuppressWarnings("unchecked")
+public abstract class CacheAbstractSelector {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** The container of Seasar. */
+    protected S2Container _container;
+
+    // ===================================================================================
+    //                                                                           Component
+    //                                                                           =========
+    public <COMPONENT> COMPONENT getComponent(Class<COMPONENT> componentType) {
+        assertObjectNotNull("componentType", componentType);
+        assertObjectNotNull("_container", _container);
+        return (COMPONENT) _container.getComponent(componentType);
+    }
+
+    // ===================================================================================
+    //                                                                             Destroy
+    //                                                                             =======
+    public void destroy() {
+        _container = null;
+    }
+
+    // ===================================================================================
+    //                                                                              Helper
+    //                                                                              ======
+    protected String initUncap(String str) {
+        return str.substring(0, 1).toLowerCase() + str.substring(1);
+    }
+
+    // ===================================================================================
+    //                                                                              Assert
+    //                                                                              ======
+    // -----------------------------------------------------
+    //                                         Assert Object
+    //                                         -------------
+    /**
+     * Assert that the object is not null.
+     * @param variableName Variable name. (NotNull)
+     * @param value Value. (NotNull)
+     * @exception IllegalArgumentException
+     */
+    protected void assertObjectNotNull(String variableName, Object value) {
+        if (variableName == null) {
+            String msg = "The value should not be null: variableName="
+                    + variableName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+        if (value == null) {
+            String msg = "The value should not be null: variableName="
+                    + variableName;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    // -----------------------------------------------------
+    //                                         Assert String
+    //                                         -------------
+    /**
+     * Assert that the entity is not null and not trimmed empty.
+     * @param variableName Variable name. (NotNull)
+     * @param value Value. (NotNull)
+     */
+    protected void assertStringNotNullAndNotTrimmedEmpty(String variableName,
+            String value) {
+        assertObjectNotNull("variableName", variableName);
+        assertObjectNotNull("value", value);
+        if (value.trim().length() == 0) {
+            String msg = "The value should not be empty: variableName="
+                    + variableName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    public void setContainer(S2Container container) {
+        this._container = container;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheAbstractSelector.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheBehaviorSelector.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheBehaviorSelector.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheBehaviorSelector.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,119 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+import java.util.Collection;
+import java.util.Map;
+
+import jp.sf.pal.announcement.db.allcommon.bhv.BehaviorReadable;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMeta;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMetaInstanceHandler;
+import jp.sf.pal.announcement.db.allcommon.util.TraceViewUtil;
+
+/**
+ * The implementation of behavior-selector.
+ * @author DBFlute(AutoGenerator)
+ */
+ @ SuppressWarnings("unchecked")
+public class CacheBehaviorSelector extends CacheAbstractSelector implements
+        BehaviorSelector {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Log-instance. */
+    private static final org.apache.commons.logging.Log _log = org.apache.commons.logging.LogFactory
+            .getLog(CacheBehaviorSelector.class);
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** The cache of behavior. (It's the generic hell!) */
+    protected java.util.Map<Class<? extends BehaviorReadable>, BehaviorReadable> _behaviorCache = new java.util.LinkedHashMap<Class<? extends BehaviorReadable>, BehaviorReadable>();
+
+    // ===================================================================================
+    //                                                                          Initialize
+    //                                                                          ==========
+    /**
+     * Initialize condition-bean meta data. <br />
+     * If you call this, Hot Deploy of OutsideSql becomes Cool!
+     */
+    public void initializeConditionBeanMetaData() {
+        final Map<String, DBMeta> dbmetaMap = DBMetaInstanceHandler
+                .getDBMetaMap();
+        final Collection<DBMeta> dbmetas = dbmetaMap.values();
+        long before = 0;
+        if (_log.isDebugEnabled()) {
+            before = System.currentTimeMillis();
+            _log
+                    .debug("/= = = = = = = = = = = = = = = = = initializeConditionBeanMetaData()");
+        }
+        for (DBMeta dbmeta : dbmetas) {
+            BehaviorReadable bhv = byName(dbmeta.getTableDbName());
+            final DaoReadable dao = bhv.getDaoReadable();
+            if (_log.isDebugEnabled()) {
+                _log.debug("[" + dbmeta.getTableDbName() + "]");
+            }
+            dao.initializeDaoMetaData("selectList");
+        }
+        if (_log.isDebugEnabled()) {
+            long after = System.currentTimeMillis();
+            _log.debug("= = = = = = = = = =/ ["
+                    + TraceViewUtil.convertToPerformanceView(after - before)
+                    + "]");
+        }
+    }
+
+    // ===================================================================================
+    //                                                                            Selector
+    //                                                                            ========
+    /**
+     * Select behavior.
+     * @param <BEHAVIOR_TYPE> The type of behavior.
+     * @param behaviorType Behavior type. (NotNull)
+     * @return Behavior. (NotNull)
+     */
+    public <BEHAVIOR_TYPE extends BehaviorReadable> BEHAVIOR_TYPE select(
+            Class<BEHAVIOR_TYPE> behaviorType) {
+        if (_behaviorCache.containsKey(behaviorType)) {
+            return (BEHAVIOR_TYPE) _behaviorCache.get(behaviorType);
+        }
+        final BEHAVIOR_TYPE bhv = (BEHAVIOR_TYPE) getComponent(behaviorType);
+        _behaviorCache.put(behaviorType, bhv);
+        return bhv;
+    }
+
+    /**
+     * Select behavior-readable by name.
+     * @param tableFlexibleName Table flexible-name. (NotNull)
+     * @return Behavior-readable. (NotNull)
+     */
+    public BehaviorReadable byName(String tableFlexibleName) {
+        assertStringNotNullAndNotTrimmedEmpty("tableFlexibleName",
+                tableFlexibleName);
+        final DBMeta dbmeta = DBMetaInstanceHandler
+                .findDBMeta(tableFlexibleName);
+        return select(getBehaviorType(dbmeta));
+    }
+
+    /**
+     * Get behavior-type by dbmeta.
+     * @param dbmeta Dbmeta. (NotNull)
+     * @return Behavior-type. (NotNull)
+     */
+    protected Class<BehaviorReadable> getBehaviorType(DBMeta dbmeta) {
+        final String behaviorTypeName = dbmeta.getBehaviorTypeName();
+        if (behaviorTypeName == null) {
+            String msg = "The dbmeta.getBehaviorTypeName() should not return null: dbmeta="
+                    + dbmeta;
+            throw new IllegalStateException(msg);
+        }
+        final Class<BehaviorReadable> behaviorType;
+        try {
+            behaviorType = (Class<BehaviorReadable>) Class
+                    .forName(behaviorTypeName);
+        } catch (ClassNotFoundException e) {
+            throw new RuntimeException("The class does not exist: "
+                    + behaviorTypeName, e);
+        }
+        return behaviorType;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheBehaviorSelector.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheDaoSelector.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheDaoSelector.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheDaoSelector.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,64 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMeta;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMetaInstanceHandler;
+
+/**
+ * The implementation of dao-selector.
+ * <pre>
+ * Long long ago this object have cache of dao and bhv.
+ * But the cache cause wrong performance when this is initialized.
+ * So now this object don't have cache.
+ * </pre>
+ * @author DBFlute(AutoGenerator)
+ */
+ @ SuppressWarnings("unchecked")
+public class CacheDaoSelector extends CacheAbstractSelector implements
+        DaoSelector {
+
+    // ===================================================================================
+    //                                                                            Selector
+    //                                                                            ========
+    /**
+     * Select dao.
+     * 
+     * @param <DAO_TYPE> The type of behavior.
+     * @param daoType Dao type. (NotNull)
+     * @return Dao. (NotNull)
+     */
+    public <DAO_TYPE extends DaoReadable> DAO_TYPE select(
+            Class<DAO_TYPE> daoType) {
+        return (DAO_TYPE) getComponent(daoType);
+    }
+
+    /**
+     * Select dao-readable by name.
+     * 
+     * @param tableFlexibleName Table flexible name. (NotNull)
+     * @return Dao-readable. (NotNull)
+     */
+    public DaoReadable byName(String tableFlexibleName) {
+        assertStringNotNullAndNotTrimmedEmpty("tableFlexibleName",
+                tableFlexibleName);
+        final DBMeta dbmeta = DBMetaInstanceHandler
+                .findDBMeta(tableFlexibleName);
+        return select(getDaoType(dbmeta));
+    }
+
+    protected Class<DaoReadable> getDaoType(DBMeta dbmeta) {
+        final String daoTypeName = dbmeta.getDaoTypeName();
+        if (daoTypeName == null) {
+            String msg = "The dbmeta.getDaoTypeName() should not return null: dbmeta="
+                    + dbmeta;
+            throw new IllegalStateException(msg);
+        }
+        final Class<DaoReadable> daoType;
+        try {
+            daoType = (Class<DaoReadable>) Class.forName(daoTypeName);
+        } catch (ClassNotFoundException e) {
+            throw new RuntimeException("The class does not exist: "
+                    + daoTypeName, e);
+        }
+        return daoType;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/CacheDaoSelector.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DBFluteConfig.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DBFluteConfig.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DBFluteConfig.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,170 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+import jp.sf.pal.announcement.db.allcommon.jdbc.StatementConfig;
+
+/**
+ * The sigleton class that has generate-meta-data(GenMetaData).
+ * @author DBFlute(AutoGenerator)
+ */
+public class DBFluteConfig {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Log instance. */
+    private static final org.apache.commons.logging.Log _log = org.apache.commons.logging.LogFactory
+            .getLog(DBFluteConfig.class);
+
+    /** Singleton instance. */
+    private static final DBFluteConfig _instance = new DBFluteConfig();
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected StatementConfig _defaultStatementConfig;
+
+    protected boolean _conditionBeanFormatSql = true;
+
+    protected boolean _queryLogLevelInfo;
+
+    protected boolean _executeStatusLogLevelInfo;
+
+    protected boolean _internalDebug;
+
+    protected boolean _locked = true;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * Constructor.
+     */
+    private DBFluteConfig() {
+    }
+
+    // ===================================================================================
+    //                                                                           Singleton
+    //                                                                           =========
+    /**
+     * Get instance.
+     * @return Singleton instance. (NotNull)
+     */
+    public static DBFluteConfig getInstance() {
+        return _instance;
+    }
+
+    // ===================================================================================
+    //                                                            Default Statement Config
+    //                                                            ========================
+    public StatementConfig getDefaultStatementConfig() {
+        return _defaultStatementConfig;
+    }
+
+    public void setDefaultStatementConfig(StatementConfig defaultStatementConfig) {
+        assertNotLocked();
+        if (_log.isInfoEnabled()) {
+            _log.info("...Setting defaultStatementConfig: "
+                    + defaultStatementConfig);
+        }
+        _defaultStatementConfig = defaultStatementConfig;
+    }
+
+    // ===================================================================================
+    //                                                            ConditionBean Format Sql
+    //                                                            ========================
+    public boolean isConditionBeanFormatSql() {
+        return _conditionBeanFormatSql;
+    }
+
+    public void setConditionBeanFormatSql(boolean conditionBeanFormatSql) {
+        assertNotLocked();
+        if (_log.isInfoEnabled()) {
+            _log.info("...Setting conditionBeanFormatSql: "
+                    + conditionBeanFormatSql);
+        }
+        _conditionBeanFormatSql = conditionBeanFormatSql;
+    }
+
+    // ===================================================================================
+    //                                                                Query Log Level Info
+    //                                                                ====================
+    public boolean isQueryLogLevelInfo() {
+        return _queryLogLevelInfo;
+    }
+
+    public void setQueryLogLevelInfo(boolean queryLogLevelInfo) {
+        assertNotLocked();
+        if (_log.isInfoEnabled()) {
+            _log.info("...Setting queryLogLevelInfo: " + queryLogLevelInfo);
+        }
+        _queryLogLevelInfo = queryLogLevelInfo;
+    }
+
+    // ===================================================================================
+    //                                                       Execute Status Log Level Info
+    //                                                       =============================
+    public boolean isExecuteStatusLogLevelInfo() {
+        return _executeStatusLogLevelInfo;
+    }
+
+    public void setExecuteStatusLogLevelInfo(boolean executeStatusLogLevelInfo) {
+        assertNotLocked();
+        if (_log.isInfoEnabled()) {
+            _log.info("...Setting executeStatusLogLevelInfo: "
+                    + executeStatusLogLevelInfo);
+        }
+        _executeStatusLogLevelInfo = executeStatusLogLevelInfo;
+    }
+
+    // ===================================================================================
+    //                                                                      Internal Debug
+    //                                                                      ==============
+    public boolean isInternalDebug() {
+        return _internalDebug;
+    }
+
+    public void setInternalDebug(boolean internalDebug) {
+        assertNotLocked();
+        if (_log.isInfoEnabled()) {
+            _log.info("...Setting internalDebug: " + internalDebug);
+        }
+        _internalDebug = internalDebug;
+    }
+
+    // ===================================================================================
+    //                                                                         Config Lock
+    //                                                                         ===========
+    public boolean isLocked() {
+        return _locked;
+    }
+
+    public void lock() {
+        if (_log.isInfoEnabled()) {
+            _log.info("...Locking the config of dbflute!");
+        }
+        _locked = true;
+    }
+
+    public void unlock() {
+        if (_log.isInfoEnabled()) {
+            _log.info("...Unlocking the config of dbflute!");
+        }
+        _locked = false;
+    }
+
+    protected void assertNotLocked() {
+        if (!isLocked()) {
+            return;
+        }
+        String msg = "The config of dbflute is locked! Don't access at this timing!";
+        throw new IllegalStateException(msg);
+    }
+
+    // ===================================================================================
+    //                                                                        Config Clear
+    //                                                                        ============
+    public void clear() {
+        _defaultStatementConfig = null;
+        _internalDebug = false;
+    }
+}
\ No newline at end of file


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DBFluteConfig.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoReadable.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoReadable.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoReadable.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,9 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+/**
+ * The interface of dao-readable.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface DaoReadable {
+    public void initializeDaoMetaData(String methodName);// Very Internal Method!
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoReadable.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoSelector.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoSelector.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoSelector.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,24 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+/**
+ * The interface of dao-selector.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface DaoSelector {
+
+    /**
+     * Select dao.
+     * @param <DAO_TYPE> The type of behavior.
+     * @param daoType Dao type. (NotNull)
+     * @return Dao. (NotNull)
+     */
+    public <DAO_TYPE extends DaoReadable> DAO_TYPE select(
+            Class<DAO_TYPE> daoType);
+
+    /**
+     * Select dao-readable by name.
+     * @param tableFlexibleName Table flexible name. (NotNull)
+     * @return Dao-readable. (NotNull)
+     */
+    public DaoReadable byName(String tableFlexibleName);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoSelector.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoWritable.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoWritable.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoWritable.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,59 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+import java.util.List;
+
+/**
+ * The interface of dao-writable.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface DaoWritable extends DaoReadable {
+
+    /**
+     * Insert one entity that the type is entity-interface.
+     * @param entity Entity that the type is entity-interface. (NotNull)
+     * @return Inserted count.
+     */
+    public int create(Entity entity);
+
+    /**
+     * Update one entity that the type is entity-interface.
+     * @param entity Entity that the type is entity-interface. (NotNull)
+     * @return Updated count.
+     */
+    public int modify(Entity entity);
+
+    /**
+     * Update one entity that the type is entity-interface. (modified only)
+     * @param entity Entity that the type is entity-interface. (NotNull)
+     * @return Updated count.
+     */
+    public int modifyModifiedOnly(Entity entity);
+
+    /**
+     * Delete one entity that the type is entity-interface.
+     * @param entity Entity that the type is entity-interface. (NotNull)
+     * @return Deleted count.
+     */
+    public int remove(Entity entity);
+
+    /**
+     * Insert several entities that the type is entity-interface.
+     * @param entityList Entity-list that the type is entity-interface. (NotNull)
+     * @return The array of inserted count.
+     */
+    public int[] createList(List<Entity> entityList);
+
+    /**
+     * Update several entities that the type is entity-interface.
+     * @param entityList Entity-list that the type is entity-interface. (NotNull)
+     * @return The array of updated count.
+     */
+    public int[] modifyList(List<Entity> entityList);
+
+    /**
+     * Delete several entities that the type is entity-interface.
+     * @param entityList Entity-list that the type is entity-interface. (NotNull)
+     * @return The array of deleted count.
+     */
+    public int[] removeList(List<Entity> entityList);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/DaoWritable.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/Entity.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/Entity.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/Entity.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,112 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+import java.util.LinkedHashSet;
+import java.util.Set;
+
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMeta;
+
+/**
+ * The interface of entity.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface Entity {
+
+    // ===================================================================================
+    //                                                                              DBMeta
+    //                                                                              ======
+    /**
+     * Get the instance of target dbmeta.
+     * @return DBMeta. (NotNull)
+     */
+    public DBMeta getDBMeta();
+
+    // ===================================================================================
+    //                                                                          Table Name
+    //                                                                          ==========
+    /**
+     * Get table DB name.
+     * @return Table DB name. (NotNull)
+     */
+    public String getTableDbName();
+
+    /**
+     * Get table property name.
+     * @return Table property name. (NotNull)
+     */
+    public String getTablePropertyName();
+
+    // ===================================================================================
+    //                                                                       Determination
+    //                                                                       =============
+    /**
+     * Has the value of primary-key?
+     * @return Determination.
+     */
+    public boolean hasPrimaryKeyValue();
+
+    // ===================================================================================
+    //                                                                 Modified Properties
+    //                                                                 ===================
+    /**
+     * Get modified property names. (JavaBeansRule)
+     * @return Modified property names. (NotNull)
+     */
+    public Set<String> getModifiedPropertyNames();
+
+    /**
+     * Clear modified property names.
+     */
+    public void clearModifiedPropertyNames();
+
+    /**
+     * Entity modified properties.
+     */
+    public static class EntityModifiedProperties implements
+            java.io.Serializable {
+
+        /** Serial version UID. (Default) */
+        private static final long serialVersionUID = 1L;
+
+        /** Set of properties. */
+        protected Set<String> _propertiesSet = new LinkedHashSet<String>();
+
+        /**
+         * Add property name. (JavaBeansRule)
+         * @param propertyName Property name. (Nullable)
+         */
+        public void addPropertyName(String propertyName) {
+            _propertiesSet.add(propertyName);
+        }
+
+        /**
+         * Get the set of properties.
+         * @return The set of properties. (NotNull)
+         */
+        public Set<String> getPropertyNames() {
+            return _propertiesSet;
+        }
+
+        /**
+         * Is empty?
+         * @return Determination.
+         */
+        public boolean isEmpty() {
+            return _propertiesSet.isEmpty();
+        }
+
+        /**
+         * Clear the set of properties.
+         */
+        public void clear() {
+            _propertiesSet.clear();
+        }
+
+        /**
+         * Remove property name from the set. (JavaBeansRule)
+         * @param propertyName Property name. (Nullable)
+         */
+        public void remove(String propertyName) {
+            _propertiesSet.remove(propertyName);
+        }
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/Entity.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/EntityDefinedCommonColumn.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/EntityDefinedCommonColumn.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/EntityDefinedCommonColumn.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,19 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+/**
+ * The interface of entity defined common column.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface EntityDefinedCommonColumn extends Entity {
+
+    /**
+     * Disable common column auto set up.
+     */
+    public void disableCommonColumnAutoSetup();
+
+    /**
+     * Can the entity set up common column by auto?
+     * @return Determination.
+     */
+    public boolean canCommonColumnAutoSetup();
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/EntityDefinedCommonColumn.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/GenMetaData.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/GenMetaData.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/GenMetaData.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,252 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+/**
+ * The sigleton class that has generate-meta-data(GenMetaData).
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class GenMetaData {
+
+    /** Singleton instance. */
+    private static final GenMetaData _instance = new GenMetaData();
+
+    /**
+     * Constructor.
+     */
+    private GenMetaData() {
+    }
+
+    /**
+     * Get instance.
+     *
+     * @return Singleton instance.
+     */
+    public static GenMetaData getInstance() {
+        return _instance;
+    }
+
+    // ===================================================================================
+    //                                                                               Basic
+    //                                                                               =====
+    /**
+     * Get the property-value of targetLanguage.
+     *
+     * @return The property-value.
+     */
+    public String getTargetLanguage() {
+        return "java";
+    }
+
+    /**
+     * Get the property-value of templateFileExtension.
+     *
+     * @return The property-value.
+     */
+    public String getTemplateFileExtension() {
+        return "vm";
+    }
+
+    /**
+     * Get the property-value of classFileExtension.
+     *
+     * @return The property-value.
+     */
+    public String getClassFileExtension() {
+        return "java";
+    }
+
+    /**
+     * Get the property-value of templateFileEncoding.
+     *
+     * @return The property-value.
+     */
+    public String getTemplateEncoding() {
+        return "UTF-8";
+    }
+
+    /**
+     * Get the property-value of classAuthor.
+     *
+     * @return The property-value.
+     */
+    public String getClassAuthor() {
+        return "DBFlute(AutoGenerator)";
+    }
+
+    // ===================================================================================
+    //                                                                              Naming
+    //                                                                              ======
+    /**
+     * Is java name of table same as db name? Answer is false!
+     *
+     * @return The property-value.
+     */
+    public boolean isJavaNameOfTableSameAsDbName() {
+        return false;
+    }
+
+    /**
+     * Is java name of column same as db name? Answer is false!
+     *
+     * @return The property-value.
+     */
+    public boolean isJavaNameOfColumnSameAsDbName() {
+        return false;
+    }
+
+    // ===================================================================================
+    //                                                                              Prefix
+    //                                                                              ======
+    /**
+     * Get the property-value of projectPrefix.
+     *
+     * @return The property-value.
+     */
+    public String getProjectPrefix() {
+        return "";
+    }
+
+    /**
+     * Get the property-value of basePrefix.
+     *
+     * @return The property-value.
+     */
+    public String getBasePrefix() {
+        return "Bs";
+    }
+
+    // ===================================================================================
+    //                                                                             Package
+    //                                                                             =======
+    /**
+     * Get the property-value of baseCommonPackage.
+     *
+     * @return The property-value.
+     */
+    public String getBaseCommonPackage() {
+        return "jp.sf.pal.announcement.db.allcommon";
+    }
+
+    /**
+     * Get the property-value of baseBehaviorPackage.
+     *
+     * @return The property-value.
+     */
+    public String getBaseBehaviorPackage() {
+        return "jp.sf.pal.announcement.db.bsbhv";
+    }
+
+    /**
+     * Get the property-value of baseDaoPackage.
+     *
+     * @return The property-value.
+     */
+    public String getBaseDaoPackage() {
+        return "jp.sf.pal.announcement.db.bsdao";
+    }
+
+    /**
+     * Get the property-value of baseEntityPackage.
+     *
+     * @return The property-value.
+     */
+    public String getBaseEntityPackage() {
+        return "jp.sf.pal.announcement.db.bsentity";
+    }
+
+    /**
+     * Get the property-value of conditionBeanPackage.
+     *
+     * @return The property-value.
+     */
+    public String getConditionBeanPackage() {
+        return "jp.sf.pal.announcement.db.cbean";
+    }
+
+    /**
+     * Get the property-value of extendedDaoPackage.
+     *
+     * @return The property-value.
+     */
+    public String getExtendedDaoPackage() {
+        return "jp.sf.pal.announcement.db.exdao";
+    }
+
+    /**
+     * Get the property-value of extendedBehaviorPackage.
+     *
+     * @return The property-value.
+     */
+    public String getExtendedBehaviorPackage() {
+        return "jp.sf.pal.announcement.db.exbhv";
+    }
+
+    /**
+     * Get the property-value of extendedEntityPackage.
+     *
+     * @return The property-value.
+     */
+    public String getExtendedEntityPackage() {
+        return "jp.sf.pal.announcement.db.exentity";
+    }
+
+    // ===================================================================================
+    //                                                                     Optimistic Lock
+    //                                                                     ===============
+    /**
+     * Get the property-value of updateDateFieldName.
+     *
+     * @return The property-value.
+     */
+    public String getUpdateDateFieldName() {
+        return "";
+    }
+
+    /**
+     * Get the property-value of versionNoFieldName.
+     *
+     * @return The property-value.
+     */
+    public String getVersionNoFieldName() {
+        return "";
+    }
+
+    // ===================================================================================
+    //                                                                             Extract
+    //                                                                             =======
+    /**
+     * Get the value of 'extractAcceptStartBrace'.
+     *
+     * @return The property-value. (NotNull)
+     */
+    public String getExtractAcceptStartBrace() {
+        return "@{";
+    }
+
+    /**
+     * Get the value of 'extractAcceptEndBrace'.
+     *
+     * @return The property-value. (NotNull)
+     */
+    public String getExtractAcceptEndBrace() {
+        return "@}";
+    }
+
+    /**
+     * Get the value of 'extractAcceptDelimiter'.
+     *
+     * @return The property-value. (NotNull)
+     */
+    public String getExtractAcceptDelimiter() {
+        return "@;";
+    }
+
+    /**
+     * Get the value of 'extractAcceptEqual'.
+     *
+     * @return The property-value. (NotNull)
+     */
+    public String getExtractAcceptEqual() {
+        return "@=";
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/GenMetaData.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/InternalMapContext.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/InternalMapContext.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/InternalMapContext.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,62 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * The context of internal map.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class InternalMapContext {
+
+    // ===================================================================================
+    //                                                                        Thread Local
+    //                                                                        ============
+    /** The thread-local for this. */
+    private static final ThreadLocal<Map<String, Object>> threadLocal = new ThreadLocal<Map<String, Object>>();
+
+    protected static void initialize() {
+        if (threadLocal.get() != null) {
+            return;
+        }
+        threadLocal.set(new HashMap<String, Object>());
+    }
+
+    /**
+     * Get the value of the object by the key.
+     * 
+     * @return The value of the object. (Nullable)
+     */
+    public static Object getObject(String key) {
+        initialize();
+        return threadLocal.get().get(key);
+    }
+
+    /**
+     * Set the value of the object.
+     * 
+     * @param key The key of the object. (NotNull)
+     * @param value The value of the object. (Nullable)
+     */
+    public static void setObject(String key, Object value) {
+        initialize();
+        threadLocal.get().put(key, value);
+    }
+
+    /**
+     * Is existing internal-map-context on thread?
+     * 
+     * @return Determination.
+     */
+    public static boolean isExistInternalMapContextOnThread() {
+        return (threadLocal.get() != null);
+    }
+
+    /**
+     * Clear internal-map-context on thread.
+     */
+    public static void clearInternalMapContextOnThread() {
+        threadLocal.set(null);
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/InternalMapContext.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/QLog.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/QLog.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/QLog.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,37 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+/**
+ * @author DBFlute(AutoGenerator)
+ */
+public class QLog {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Log instance. */
+    private static final org.apache.commons.logging.Log _log = org.apache.commons.logging.LogFactory
+            .getLog(QLog.class);
+
+    // ===================================================================================
+    //                                                                             Logging
+    //                                                                             =======
+    public static void log(String sql) {// Very Internal
+        if (isQueryLogLevelInfo()) {
+            _log.info(sql);
+        } else {
+            _log.debug(sql);
+        }
+    }
+
+    public static boolean isLogEnabled() {
+        if (isQueryLogLevelInfo()) {
+            return _log.isInfoEnabled();
+        } else {
+            return _log.isDebugEnabled();
+        }
+    }
+
+    protected static boolean isQueryLogLevelInfo() {
+        return DBFluteConfig.getInstance().isQueryLogLevelInfo();
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/QLog.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/XLog.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/XLog.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/XLog.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,37 @@
+package jp.sf.pal.announcement.db.allcommon;
+
+/**
+ * @author DBFlute(AutoGenerator)
+ */
+public class XLog {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Log instance. */
+    private static final org.apache.commons.logging.Log _log = org.apache.commons.logging.LogFactory
+            .getLog(XLog.class);
+
+    // ===================================================================================
+    //                                                                             Logging
+    //                                                                             =======
+    public static void log(String msg) {// Very Internal
+        if (isExecuteStatusLogLevelInfo()) {
+            _log.info(msg);
+        } else {
+            _log.debug(msg);
+        }
+    }
+
+    public static boolean isLogEnabled() {// Very Internal
+        if (isExecuteStatusLogLevelInfo()) {
+            return _log.isInfoEnabled();
+        } else {
+            return _log.isDebugEnabled();
+        }
+    }
+
+    protected static boolean isExecuteStatusLogLevelInfo() {
+        return DBFluteConfig.getInstance().isExecuteStatusLogLevelInfo();
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/XLog.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/annotation/OutsideSql.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/annotation/OutsideSql.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/annotation/OutsideSql.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,18 @@
+package jp.sf.pal.announcement.db.allcommon.annotation;
+
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Inherited;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+ @ Inherited
+ @ Retention(RetentionPolicy.RUNTIME)
+ @ Target(ElementType.METHOD)
+public @interface OutsideSql {
+    boolean dynamicBinding() default false;
+
+    boolean offsetByCursor() default false;
+
+    boolean limitByCursor() default false;
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/annotation/OutsideSql.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/AbstractBehaviorReadable.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/AbstractBehaviorReadable.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/AbstractBehaviorReadable.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,1071 @@
+package jp.sf.pal.announcement.db.allcommon.bhv;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import jp.sf.pal.announcement.db.allcommon.BehaviorSelector;
+import jp.sf.pal.announcement.db.allcommon.DaoSelector;
+import jp.sf.pal.announcement.db.allcommon.Entity;
+import jp.sf.pal.announcement.db.allcommon.bhv.batch.TokenFileOutputOption;
+import jp.sf.pal.announcement.db.allcommon.bhv.batch.TokenFileOutputResult;
+import jp.sf.pal.announcement.db.allcommon.bhv.setup.ValueLabelBox;
+import jp.sf.pal.announcement.db.allcommon.bhv.setup.ValueLabelSetupper;
+import jp.sf.pal.announcement.db.allcommon.cbean.ConditionBean;
+import jp.sf.pal.announcement.db.allcommon.cbean.ConditionBeanContext;
+import jp.sf.pal.announcement.db.allcommon.cbean.ListResultBean;
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingBean;
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingHandler;
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingInvoker;
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingResultBean;
+import jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.OutsideSqlDao;
+import jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.executor.OutsideSqlBasicExecutor;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.ColumnInfo;
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.FileMakingHeaderInfo;
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.FileMakingOption;
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.FileMakingSimpleFacade;
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.impl.FileMakingSimpleFacadeImpl;
+
+/**
+ * The abstract class of behavior-readable.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+ @ SuppressWarnings("unchecked")
+public abstract class AbstractBehaviorReadable implements BehaviorReadable {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** Behavior-selector instance. It's basically referred at loadReferrer. (Required for loadReferrer) */
+    protected BehaviorSelector _behaviorSelector;
+
+    /** Dao-selector instance. It's basically referred at loadReferrer. (Required for OutsideSql) */
+    protected DaoSelector _daoSelector;
+
+    // =====================================================================================
+    //                                                                         Basic Get All
+    //                                                                         =============
+    /**
+     * Get count all.
+     * 
+     * @return Count all.
+     */
+    public int getCountAll() {
+        return callGetCountAll();
+    }
+
+    // =====================================================================================
+    //                                                                      Basic Read Count
+    //                                                                      ================
+    /**
+     * The implementation.
+     * 
+     * @param cb Condition-bean. This condition-bean should not be set up about fetch-scope. (NotNull)
+     * @return Read count. (NotNull)
+     */
+    public int readCount(ConditionBean cb) {
+        assertConditionBeanNotNull(cb);
+        return callReadCount(cb);
+    }
+
+    // =====================================================================================
+    //                                                                     Basic Read Entity
+    //                                                                     =================
+    /**
+     * The implementation.
+     * 
+     * @param cb Condition-bean. (NotNull)
+     * @return Read entity. (Nullalble)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public Entity readEntity(ConditionBean cb) {
+        assertConditionBeanNotNull(cb);
+        final java.util.List<Entity> ls = readList(cb);
+        if (ls.isEmpty()) {
+            return null;
+        }
+        assertEntitySelectedAsOne(ls, cb);
+        return (Entity) ls.get(0);
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param cb Condition-bean. (NotNull)
+     * @return Read entity. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public Entity readEntityWithDeletedCheck(ConditionBean cb) {
+        assertConditionBeanNotNull(cb);
+        final java.util.List<Entity> ls = readList(cb);
+        assertEntityNotDeleted(ls, cb);
+        assertEntitySelectedAsOne(ls, cb);
+        return (Entity) ls.get(0);
+    }
+
+    // =====================================================================================
+    //                                                     Basic Read Entity Internal Helper
+    //                                                     =================================
+    protected <ENTITY_TYPE extends Entity, CB_TYPE extends ConditionBean> ENTITY_TYPE helpSelectEntityInternally(
+            CB_TYPE cb,
+            InternalSelectEntityCallback<ENTITY_TYPE, CB_TYPE> callback) {
+        assertConditionBeanNotNull(cb);
+        cb.checkSafetyResult(1);
+        java.util.List<ENTITY_TYPE> ls = null;
+        try {
+            ls = callback.callbackSelectList(cb);
+        } catch (jp.sf.pal.announcement.db.allcommon.exception.DangerousResultSizeException e) {
+            throwEntityDuplicatedException("{Over safetyMaxResultSize '1'}",
+                    cb, e);
+        }
+        if (ls.isEmpty()) {
+            return null;
+        }
+        assertEntitySelectedAsOne(ls, cb);
+        return (ENTITY_TYPE) ls.get(0);
+    }
+
+    protected static interface InternalSelectEntityCallback<ENTITY_TYPE extends Entity, CB_TYPE extends ConditionBean> {
+        public java.util.List<ENTITY_TYPE> callbackSelectList(CB_TYPE cb);
+    }
+
+    protected <ENTITY_TYPE extends Entity, CB_TYPE extends ConditionBean> ENTITY_TYPE helpSelectEntityWithDeletedCheckInternally(
+            CB_TYPE cb,
+            InternalSelectEntityWithDeletedCheckCallback<ENTITY_TYPE, CB_TYPE> callback) {
+        assertConditionBeanNotNull(cb);
+        cb.checkSafetyResult(1);
+        java.util.List<ENTITY_TYPE> ls = null;
+        try {
+            ls = callback.callbackSelectList(cb);
+        } catch (jp.sf.pal.announcement.db.allcommon.exception.DangerousResultSizeException e) {
+            throwEntityDuplicatedException("{Over safetyMaxResultSize '1'}",
+                    cb, e);
+        }
+        assertEntityNotDeleted(ls, cb);
+        assertEntitySelectedAsOne(ls, cb);
+        return (ENTITY_TYPE) ls.get(0);
+    }
+
+    protected static interface InternalSelectEntityWithDeletedCheckCallback<ENTITY_TYPE extends Entity, CB_TYPE extends ConditionBean> {
+        public java.util.List<ENTITY_TYPE> callbackSelectList(CB_TYPE cb);
+    }
+
+    // =====================================================================================
+    //                                                                       Basic Read List
+    //                                                                       ===============
+    /**
+     * The implementation.
+     * 
+     * @param cb Condition-bean.
+     * @return List-result-bean. If the select result is zero, it returns empty list. (NotNull)
+     */
+    public ListResultBean<Entity> readList(ConditionBean cb) {
+        assertConditionBeanNotNull(cb);
+        return new jp.sf.pal.announcement.db.allcommon.cbean.ResultBeanBuilder<Entity>(
+                getTableDbName()).buildListResultBean(cb, callReadList(cb));
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param cb Condition-bean. (NotNull)
+     * @return Read page. (NotNull)
+     */
+    public PagingResultBean<Entity> readPage(final ConditionBean cb) {
+        assertConditionBeanNotNull(cb);
+        final PagingInvoker<Entity> invoker = new PagingInvoker<Entity>(
+                getTableDbName());
+        final PagingHandler<Entity> handler = new PagingHandler<Entity>() {
+            public PagingBean getPagingBean() {
+                return cb;
+            }
+
+            public int count() {
+                return readCount(cb);
+            }
+
+            public List<Entity> paging() {
+                return readList(cb);
+            }
+        };
+        return invoker.invokePaging(handler);
+    }
+
+    /**
+     * Assert that record has not been deleted.
+     * 
+     * @param entity Selected entity.
+     * @param searchKey4log Search-key for Logging.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException
+     * @deprecated Please use assertEntityNotDeleted().
+     */
+    protected void assertRecordHasNotBeenDeleted(
+            jp.sf.pal.announcement.db.allcommon.Entity entity,
+            Object searchKey4Log) {
+        assertEntityNotDeleted(entity, searchKey4Log);
+    }
+
+    /**
+     * Assert that record has not been deleted.
+     * 
+     * @param ls Selected list.
+     * @param searchKey4Log Search-key for Logging.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException
+     * @deprecated Please use assertEntityNotDeleted().
+     */
+    protected void assertRecordHasNotBeenDeleted(java.util.List ls,
+            Object searchKey4Log) {
+        assertEntityNotDeleted(ls, searchKey4Log);
+    }
+
+    /**
+     * Assert that the entity is not deleted.
+     * 
+     * @param entity Selected entity. (Nullable)
+     * @param searchKey4log Search-key for Logging.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     */
+    protected void assertEntityNotDeleted(
+            jp.sf.pal.announcement.db.allcommon.Entity entity,
+            Object searchKey4Log) {
+        if (entity == null) {
+            throwEntityAlreadyDeletedException(searchKey4Log);
+        }
+    }
+
+    /**
+     * Assert that the entity is not deleted.
+     * 
+     * @param ls Selected list. (Nullable)
+     * @param searchKey4Log Search-key for Logging. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException
+     */
+    protected void assertEntityNotDeleted(java.util.List ls,
+            Object searchKey4Log) {
+        if (ls == null || ls.isEmpty()) {
+            throwEntityAlreadyDeletedException(searchKey4Log);
+        }
+    }
+
+    /**
+     * @param ls Selected list.
+     * @param searchKey4Log Search-key for Logging.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException
+     * @deprecated Please use assertEntitySelectedAsOne.
+     */
+    protected void assertRecordHasBeenSelectedAsOne(java.util.List ls,
+            Object searchKey4Log) {
+        assertEntitySelectedAsOne(ls, searchKey4Log);
+    }
+
+    /**
+     * Assert that the entity is selected as one.
+     * 
+     * @param ls Selected list. (NotNull)
+     * @param searchKey4Log Search-key for Logging. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException
+     */
+    protected void assertEntitySelectedAsOne(java.util.List ls,
+            Object searchKey4Log) {
+        if (ls == null || ls.isEmpty()) {
+            throwEntityAlreadyDeletedException(searchKey4Log);
+        }
+        if (ls.size() > 1) {
+            throwEntityDuplicatedException(ls.size() + "", searchKey4Log, null);
+        }
+    }
+
+    private void throwEntityAlreadyDeletedException(Object searchKey4Log) {
+        ConditionBeanContext.throwEntityAlreadyDeletedException(searchKey4Log);
+    }
+
+    private void throwEntityDuplicatedException(String resultCountString,
+            Object searchKey4Log, Throwable cause) {
+        ConditionBeanContext.throwEntityDuplicatedException(resultCountString,
+                searchKey4Log, cause);
+    }
+
+    // ===================================================================================
+    //                                                                      Various Select
+    //                                                                      ==============
+    public OutsideSqlBasicExecutor outsideSql() {
+        assertDaoSelectorNotNull("outsideSql");
+        final OutsideSqlDao outsideSqlDao = _daoSelector
+                .select(OutsideSqlDao.class);
+        return new OutsideSqlBasicExecutor(outsideSqlDao, getTableDbName());
+    }
+
+    private void assertDaoSelectorNotNull(String methodName) {
+        if (_daoSelector == null) {
+            String msg = "Look! Read the message below." + getLineSeparator();
+            msg = msg
+                    + "/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *"
+                    + getLineSeparator();
+            msg = msg
+                    + "Not found the selector of dao as behavior's attributed!"
+                    + getLineSeparator();
+            msg = msg + getLineSeparator();
+            msg = msg + "[Advice]" + getLineSeparator();
+            msg = msg
+                    + "Please confirm the definition of the selector at your 'dbflute.dicon'."
+                    + getLineSeparator();
+            msg = msg + "It is precondition that '" + methodName
+                    + "()' needs the selector instance." + getLineSeparator();
+            msg = msg + getLineSeparator();
+            msg = msg + "[Your Behavior's Attributes]" + getLineSeparator();
+            msg = msg + "  _behaviorSelector  : " + _behaviorSelector
+                    + getLineSeparator();
+            msg = msg + "  _daoSelector       : " + _daoSelector
+                    + getLineSeparator();
+            msg = msg + "* * * * * * * * * */" + getLineSeparator();
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    /**
+     * Create value-label list.
+     * @param <ENTITY> The type of entity.
+     * @param cb Condition-bean. (NotNull)
+     * @param valueLabelSetupper Value-label-setupper. (NotNull)
+     * @return Value-label list. (NotNull)
+     */
+    public <ENTITY extends Entity> List<java.util.Map<String, Object>> createValueLabelList(
+            List<ENTITY> entityList,
+            ValueLabelSetupper<ENTITY> valueLabelSetupper) {
+        final List<Map<String, Object>> valueLabelList = new ArrayList<Map<String, Object>>();
+        final ValueLabelBox box = new ValueLabelBox();
+        for (ENTITY entity : entityList) {
+            final Map<String, Object> valueLabel = new HashMap<String, Object>();
+            valueLabelSetupper.setup(box, entity);
+            valueLabel.put("value", box.getValue());
+            valueLabel.put("label", box.getLabel());
+            valueLabelList.add(valueLabel);
+        }
+        return valueLabelList;
+    }
+
+    // ===================================================================================
+    //                                                                            Sequence
+    //                                                                            ========
+    /**
+     * The implementation.
+     * 
+     * @return The value of sequence. (NotNull)
+     */
+    public java.math.BigDecimal readNextVal() {
+        try {
+            final java.lang.reflect.Method method = getClass().getMethod(
+                    "selectNextVal", new Class[] {});
+            Object sequenceObject = method.invoke(this, new Object[] {});
+            if (sequenceObject instanceof java.math.BigDecimal) {
+                return (java.math.BigDecimal) sequenceObject;
+            }
+            return (java.math.BigDecimal) helpConvertingSequenceObject(
+                    java.math.BigDecimal.class, sequenceObject);
+        } catch (NoSuchMethodException e) {
+            throw new RuntimeException("The table does not have sequence: "
+                    + getTableDbName(), e);
+        } catch (Exception e) {
+            throw new RuntimeException(
+                    "The selectNextVal() of the table threw the exception: "
+                            + getTableDbName(), e);
+        }
+    }
+
+    protected Object helpConvertingSequenceObject(Class resultClass,
+            Object sequenceObject) {
+        try {
+            final java.lang.reflect.Constructor constructor = resultClass
+                    .getConstructor(new Class[] { String.class });
+            return constructor.newInstance(new Object[] { sequenceObject
+                    .toString() });
+        } catch (NoSuchMethodException e) {
+        } catch (Exception e) {
+            throw new RuntimeException(
+                    "The readNextVal() of the table threw the exception: "
+                            + getTableDbName(), e);
+        }
+        try {
+            final java.lang.reflect.Method method = resultClass.getMethod(
+                    "valueOf", new Class[] { long.class });
+            return method.invoke(null, new Object[] { Long
+                    .valueOf(sequenceObject.toString()) });
+        } catch (NoSuchMethodException e) {
+        } catch (Exception e) {
+            throw new RuntimeException(
+                    "The readNextVal() of the table threw the exception: "
+                            + getTableDbName(), e);
+        }
+        String msg = "Cannot convert sequenceObject to resultClass:";
+        msg = msg + " resultClass=" + resultClass + " sequenceObjectType="
+                + sequenceObject.getClass();
+        throw new IllegalStateException(msg);
+    }
+
+    // ===================================================================================
+    //                                                       Load Referrer Internal Helper
+    //                                                       =============================
+    /**
+     * @param <LOCAL_ENTITY_TYPE> The type of base entity.
+     * @param <PK_TYPE> The type of primary key.
+     * @param <REFERRER_CB_TYPE> The type of referrer condition-bean.
+     * @param <REFERRER_ENTITY_TYPE> The type of referrer entity.
+     * @param localEntityList The list of local entity. (NotNull)
+     * @param loadReferrerOption The option of loadReferrer. (NotNull)
+     * @param callback The internal call-back of loadReferrer. (NotNull) 
+     */
+    protected <LOCAL_ENTITY_TYPE extends Entity, PK_TYPE, REFERRER_CB_TYPE extends ConditionBean, REFERRER_ENTITY_TYPE extends Entity> void helpLoadRefererInternally(
+            java.util.List<LOCAL_ENTITY_TYPE> localEntityList,
+            jp.sf.pal.announcement.db.allcommon.bhv.load.LoadRefererOption<REFERRER_CB_TYPE, REFERRER_ENTITY_TYPE> loadReferrerOption,
+            InternalLoadRefererCallback<LOCAL_ENTITY_TYPE, PK_TYPE, REFERRER_CB_TYPE, REFERRER_ENTITY_TYPE> callback) {
+        doHelpLoadReferrerInternally(localEntityList, loadReferrerOption,
+                callback);
+    }// Cannot deprecated because someone who overrides this method exists.
+
+    /**
+     * Help load referrer internally. <br />
+     * About internal policy, the value of primary key(and others too) is treated as CaseInsensitive.
+     * 
+     * @param <LOCAL_ENTITY_TYPE> The type of base entity.
+     * @param <PK_TYPE> The type of primary key.
+     * @param <REFERRER_CB_TYPE> The type of referrer condition-bean.
+     * @param <REFERRER_ENTITY_TYPE> The type of referrer entity.
+     * @param localEntityList The list of local entity. (NotNull)
+     * @param loadReferrerOption The option of loadReferrer. (NotNull)
+     * @param callback The internal call-back of loadReferrer. (NotNull) 
+     */
+    protected <LOCAL_ENTITY_TYPE extends Entity, PK_TYPE, REFERRER_CB_TYPE extends ConditionBean, REFERRER_ENTITY_TYPE extends Entity> void helpLoadReferrerInternally(
+            java.util.List<LOCAL_ENTITY_TYPE> localEntityList,
+            jp.sf.pal.announcement.db.allcommon.bhv.load.LoadReferrerOption<REFERRER_CB_TYPE, REFERRER_ENTITY_TYPE> loadReferrerOption,
+            final InternalLoadReferrerCallback<LOCAL_ENTITY_TYPE, PK_TYPE, REFERRER_CB_TYPE, REFERRER_ENTITY_TYPE> callback) {
+        final InternalLoadRefererCallback<LOCAL_ENTITY_TYPE, PK_TYPE, REFERRER_CB_TYPE, REFERRER_ENTITY_TYPE> compatibleCallback = new InternalLoadRefererCallback<LOCAL_ENTITY_TYPE, PK_TYPE, REFERRER_CB_TYPE, REFERRER_ENTITY_TYPE>() {
+            public PK_TYPE callbackBase_getPrimaryKeyValue(
+                    LOCAL_ENTITY_TYPE entity) {
+                return callback.callbackBase_getPrimaryKeyValue(entity);
+            }
+
+            public void callbackBase_setReferrerList(LOCAL_ENTITY_TYPE entity,
+                    List<REFERRER_ENTITY_TYPE> referrerList) {
+                callback.callbackBase_setReferrerList(entity, referrerList);
+            }
+
+            public PK_TYPE callbackReferrer_getForeignKeyValue(
+                    REFERRER_ENTITY_TYPE entity) {
+                return callback.callbackReferrer_getForeignKeyValue(entity);
+            }
+
+            public REFERRER_CB_TYPE callbackReferrer_newMyConditionBean() {
+                return callback.callbackReferrer_newMyConditionBean();
+            }
+
+            public void callbackReferrer_queryAddOrderByForeignKeyAsc(
+                    REFERRER_CB_TYPE cb) {
+                callback.callbackReferrer_queryAddOrderByForeignKeyAsc(cb);
+            }
+
+            public void callbackReferrer_queryForeignKeyInScope(
+                    REFERRER_CB_TYPE cb, List<PK_TYPE> pkList) {
+                callback.callbackReferrer_queryForeignKeyInScope(cb, pkList);
+            }
+
+            public List<REFERRER_ENTITY_TYPE> callbackReferrer_selectList(
+                    REFERRER_CB_TYPE cb) {
+                return callback.callbackReferrer_selectList(cb);
+            }
+
+            public void callbackReferrer_setForeignEntity(
+                    REFERRER_ENTITY_TYPE referrerEntity,
+                    LOCAL_ENTITY_TYPE localEntity) {
+                callback.callbackReferrer_setForeignEntity(referrerEntity,
+                        localEntity);
+            }
+        };
+        helpLoadRefererInternally(
+                localEntityList,
+                new jp.sf.pal.announcement.db.allcommon.bhv.load.LoadRefererOption<REFERRER_CB_TYPE, REFERRER_ENTITY_TYPE>(
+                        loadReferrerOption), compatibleCallback);
+    }
+
+    /**
+     * Help load referrer internally. <br />
+     * About internal policy, the value of primary key(and others too) is treated as CaseInsensitive.
+     * 
+     * @param <LOCAL_ENTITY_TYPE> The type of base entity.
+     * @param <PK_TYPE> The type of primary key.
+     * @param <REFERRER_CB_TYPE> The type of referrer condition-bean.
+     * @param <REFERRER_ENTITY_TYPE> The type of referrer entity.
+     * @param localEntityList The list of local entity. (NotNull)
+     * @param loadReferrerOption The option of loadReferrer. (NotNull)
+     * @param callback The internal call-back of loadReferrer. (NotNull) 
+     */
+    protected <LOCAL_ENTITY_TYPE extends Entity, PK_TYPE, REFERRER_CB_TYPE extends ConditionBean, REFERRER_ENTITY_TYPE extends Entity> void doHelpLoadReferrerInternally(
+            java.util.List<LOCAL_ENTITY_TYPE> localEntityList,
+            jp.sf.pal.announcement.db.allcommon.bhv.load.LoadReferrerOption<REFERRER_CB_TYPE, REFERRER_ENTITY_TYPE> loadReferrerOption,
+            InternalLoadReferrerCallback<LOCAL_ENTITY_TYPE, PK_TYPE, REFERRER_CB_TYPE, REFERRER_ENTITY_TYPE> callback) {
+
+        // - - - - - - - - - - -
+        // Assert pre-condition
+        // - - - - - - - - - - -
+        assertBehaviorSelectorNotNull("loadReferrer");
+        assertObjectNotNull("localEntityList", localEntityList);
+        assertObjectNotNull("loadReferrerOption", loadReferrerOption);
+        if (localEntityList.isEmpty()) {
+            return;
+        }
+
+        // - - - - - - - - - - - - - -
+        // Prepare temporary container
+        // - - - - - - - - - - - - - -
+        final java.util.Map<PK_TYPE, LOCAL_ENTITY_TYPE> pkBaseEntityMap = new java.util.LinkedHashMap<PK_TYPE, LOCAL_ENTITY_TYPE>();
+        final java.util.List<PK_TYPE> pkList = new java.util.ArrayList<PK_TYPE>();
+        for (LOCAL_ENTITY_TYPE localEntity : localEntityList) {
+            final PK_TYPE primaryKeyValue = callback
+                    .callbackBase_getPrimaryKeyValue(localEntity);
+            pkList.add(callback.callbackBase_getPrimaryKeyValue(localEntity));
+            pkBaseEntityMap.put(toLowerCasePrimaryKeyIfString(primaryKeyValue),
+                    localEntity);
+        }
+
+        // - - - - - - - - - - - - - - - -
+        // Prepare referrer condition bean
+        // - - - - - - - - - - - - - - - -
+        final REFERRER_CB_TYPE cb;
+        if (loadReferrerOption.getReferrerConditionBean() != null) {
+            cb = loadReferrerOption.getReferrerConditionBean();
+        } else {
+            cb = callback.callbackReferrer_newMyConditionBean();
+        }
+
+        // - - - - - - - - - - - - - -
+        // Select the list of referrer
+        // - - - - - - - - - - - - - -
+        callback.callbackReferrer_queryForeignKeyInScope(cb, pkList);
+        loadReferrerOption
+                .delegateKeyConditionExchangingFirstWhereClauseForLastOne(cb);
+        if (!loadReferrerOption.isStopOrderByKey()) {
+            callback.callbackReferrer_queryAddOrderByForeignKeyAsc(cb);
+            cb.getSqlComponentOfOrderByClause()
+                    .exchangeFirstOrderByElementForLastOne();
+        }
+        loadReferrerOption.delegateConditionBeanSettingUp(cb);
+        final java.util.List<REFERRER_ENTITY_TYPE> referrerList = callback
+                .callbackReferrer_selectList(cb);
+        loadReferrerOption.delegateEntitySettingUp(referrerList);
+
+        // - - - - - - - - - - - - - - - - - - - - - - - -
+        // Create the map of {primary key / referrer list}
+        // - - - - - - - - - - - - - - - - - - - - - - - -
+        final java.util.Map<PK_TYPE, java.util.List<REFERRER_ENTITY_TYPE>> pkReffererListMap = new java.util.LinkedHashMap<PK_TYPE, java.util.List<REFERRER_ENTITY_TYPE>>();
+        for (REFERRER_ENTITY_TYPE referrerEntity : referrerList) {
+            final PK_TYPE referrerListKey;
+            {
+                final PK_TYPE foreignKeyValue = callback
+                        .callbackReferrer_getForeignKeyValue(referrerEntity);
+                referrerListKey = toLowerCasePrimaryKeyIfString(foreignKeyValue);
+            }
+            if (!pkReffererListMap.containsKey(referrerListKey)) {
+                pkReffererListMap.put(referrerListKey,
+                        new java.util.ArrayList<REFERRER_ENTITY_TYPE>());
+            }
+            (pkReffererListMap.get(referrerListKey)).add(referrerEntity);
+
+            // for Reverse Reference.
+            final LOCAL_ENTITY_TYPE localEntity = pkBaseEntityMap
+                    .get(referrerListKey);
+            callback.callbackReferrer_setForeignEntity(referrerEntity,
+                    localEntity);
+        }
+
+        // - - - - - - - - - - - - - - - - - -
+        // Relate referrer list to base entity
+        // - - - - - - - - - - - - - - - - - -
+        for (LOCAL_ENTITY_TYPE localEntity : localEntityList) {
+            final PK_TYPE referrerListKey;
+            {
+                final PK_TYPE primaryKey = callback
+                        .callbackBase_getPrimaryKeyValue(localEntity);
+                referrerListKey = toLowerCasePrimaryKeyIfString(primaryKey);
+            }
+            if (pkReffererListMap.containsKey(referrerListKey)) {
+                callback.callbackBase_setReferrerList(localEntity,
+                        pkReffererListMap.get(referrerListKey));
+            } else {
+                callback.callbackBase_setReferrerList(localEntity,
+                        new java.util.ArrayList<REFERRER_ENTITY_TYPE>());
+            }
+        }
+    }
+
+    /**
+     * To lower case for primary key if the value is string.
+     * 
+     * @param <PK_TYPE> The type of primary key.
+     * @param value The value of primary key. (Nullable)
+     * @return The value of primary key. (Nullable)
+     */
+    protected <PK_TYPE> PK_TYPE toLowerCasePrimaryKeyIfString(PK_TYPE value) {
+        return (PK_TYPE) toLowerCaseIfString(value);
+    }
+
+    /**
+     * @param <LOCAL_ENTITY_TYPE> The type of base entity.
+     * @param <PK_TYPE> The type of primary key.
+     * @param <REFERRER_CB_TYPE> The type of referrer condition-bean.
+     * @param <REFERRER_ENTITY_TYPE> The type of referrer entity.
+     */
+    protected static interface InternalLoadRefererCallback<LOCAL_ENTITY_TYPE extends Entity, PK_TYPE, REFERRER_CB_TYPE extends ConditionBean, REFERRER_ENTITY_TYPE extends Entity>
+            extends
+            InternalLoadReferrerCallback<LOCAL_ENTITY_TYPE, PK_TYPE, REFERRER_CB_TYPE, REFERRER_ENTITY_TYPE> {
+    }
+
+    /**
+     * @param <LOCAL_ENTITY_TYPE> The type of base entity.
+     * @param <PK_TYPE> The type of primary key.
+     * @param <REFERRER_CB_TYPE> The type of referrer conditionBean.
+     * @param <REFERRER_ENTITY_TYPE> The type of referrer entity.
+     */
+    protected static interface InternalLoadReferrerCallback<LOCAL_ENTITY_TYPE extends Entity, PK_TYPE, REFERRER_CB_TYPE extends ConditionBean, REFERRER_ENTITY_TYPE extends Entity> {
+        // For Base
+        public PK_TYPE callbackBase_getPrimaryKeyValue(LOCAL_ENTITY_TYPE entity);
+
+        public void callbackBase_setReferrerList(LOCAL_ENTITY_TYPE entity,
+                java.util.List<REFERRER_ENTITY_TYPE> referrerList);
+
+        // For Referrer
+        public REFERRER_CB_TYPE callbackReferrer_newMyConditionBean();
+
+        public void callbackReferrer_queryForeignKeyInScope(
+                REFERRER_CB_TYPE cb, java.util.List<PK_TYPE> pkList);
+
+        public void callbackReferrer_queryAddOrderByForeignKeyAsc(
+                REFERRER_CB_TYPE cb);
+
+        public java.util.List<REFERRER_ENTITY_TYPE> callbackReferrer_selectList(
+                REFERRER_CB_TYPE cb);
+
+        public PK_TYPE callbackReferrer_getForeignKeyValue(
+                REFERRER_ENTITY_TYPE entity);
+
+        public void callbackReferrer_setForeignEntity(
+                REFERRER_ENTITY_TYPE referrerEntity,
+                LOCAL_ENTITY_TYPE localEntity);
+    }
+
+    private void assertBehaviorSelectorNotNull(String methodName) {
+        if (_behaviorSelector == null) {
+            String msg = "Look! Read the message below." + getLineSeparator();
+            msg = msg
+                    + "/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *"
+                    + getLineSeparator();
+            msg = msg
+                    + "Not found the selector of behavior as behavior's attributed!"
+                    + getLineSeparator();
+            msg = msg + getLineSeparator();
+            msg = msg + "[Advice]" + getLineSeparator();
+            msg = msg
+                    + "Please confirm the definition of the selector at your 'dbflute.dicon'."
+                    + getLineSeparator();
+            msg = msg + "It is precondition that '" + methodName
+                    + "()' needs the selector instance." + getLineSeparator();
+            msg = msg + getLineSeparator();
+            msg = msg + "[Your Behavior's Attributes]" + getLineSeparator();
+            msg = msg + "  _behaviorSelector  : " + _behaviorSelector
+                    + getLineSeparator();
+            msg = msg + "  _daoSelector       : " + _daoSelector
+                    + getLineSeparator();
+            msg = msg + "* * * * * * * * * */" + getLineSeparator();
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    // ===================================================================================
+    //                                                             Pullout Internal Helper
+    //                                                             =======================
+    protected <LOCAL_ENTITY_TYPE extends Entity, FOREIGN_ENTITY_TYPE extends Entity> java.util.List<FOREIGN_ENTITY_TYPE> helpPulloutInternally(
+            java.util.List<LOCAL_ENTITY_TYPE> localEntityList,
+            InternalPulloutCallback<LOCAL_ENTITY_TYPE, FOREIGN_ENTITY_TYPE> callback) {
+        assertObjectNotNull("localEntityList", localEntityList);
+        final java.util.Set<FOREIGN_ENTITY_TYPE> foreignSet = new java.util.LinkedHashSet<FOREIGN_ENTITY_TYPE>();
+        for (LOCAL_ENTITY_TYPE entity : localEntityList) {
+            final FOREIGN_ENTITY_TYPE foreignEntity = callback
+                    .callbackGetForeignEntity(entity);
+            if (foreignEntity == null || foreignSet.contains(foreignEntity)) {
+                continue;
+            }
+            foreignSet.add(foreignEntity);
+        }
+        return new java.util.ArrayList<FOREIGN_ENTITY_TYPE>(foreignSet);
+    }
+
+    protected static interface InternalPulloutCallback<LOCAL_ENTITY_TYPE extends Entity, FOREIGN_ENTITY_TYPE extends Entity> {
+        public FOREIGN_ENTITY_TYPE callbackGetForeignEntity(
+                LOCAL_ENTITY_TYPE entity);
+    }
+
+    // ===================================================================================
+    //                                                                          Token File
+    //                                                                          ==========
+    public TokenFileOutputExecutor tokenFileOutput()
+            throws java.io.FileNotFoundException, java.io.IOException {
+        return new TokenFileOutputExecutor();
+    }
+
+    public class TokenFileOutputExecutor {
+
+        /**
+         * Output token-file from this table records.
+         * 
+         * @param cb Condition-bean. (NotNull)
+         * @param filename Name of the file. (NotNull and NotEmpty)
+         * @param tokenFileOutputOption token-file-output-option. (NotNull and Required{delimiter and encoding})
+         * @return Token-file-output-result. (NotNull)
+         * @throws java.io.FileNotFoundException
+         * @throws java.io.IOException
+         */
+        public TokenFileOutputResult outputTokenFile(ConditionBean cb,
+                String filename, TokenFileOutputOption tokenFileOutputOption)
+                throws java.io.FileNotFoundException, java.io.IOException {
+            assertConditionBeanNotNull(cb);
+            assertStringNotNullAndNotTrimmedEmpty("filename", filename);
+            assertObjectNotNull("tokenFileOutputOption", tokenFileOutputOption);
+
+            final java.util.List<Entity> ls = readList(cb);
+            java.util.List<java.util.List<String>> rowList = new java.util.ArrayList<java.util.List<String>>();
+            for (java.util.Iterator ite = ls.iterator(); ite.hasNext();) {
+                final Entity entity = (Entity) ite.next();
+                final java.util.List<String> valueList = getDBMeta()
+                        .convertToColumnStringValueList(entity);
+                rowList.add(valueList);
+            }
+            final FileMakingSimpleFacade fileMakingSimpleFacade = new FileMakingSimpleFacadeImpl();
+            final FileMakingOption fileMakingOption = tokenFileOutputOption
+                    .getFileMakingOption();
+            final FileMakingHeaderInfo fileMakingHeaderInfo = new FileMakingHeaderInfo();
+            final java.util.List<String> columnDbNameList = new java.util.ArrayList<String>();
+            for (final java.util.Iterator ite = getDBMeta().getColumnInfoList()
+                    .iterator(); ite.hasNext();) {
+                final ColumnInfo columnInfo = (ColumnInfo) ite.next();
+                columnDbNameList.add(columnInfo.getColumnDbName());
+            }
+            fileMakingHeaderInfo.setColumnNameList(columnDbNameList);
+            fileMakingOption.setFileMakingHeaderInfo(fileMakingHeaderInfo);
+            fileMakingSimpleFacade.makeFromRowList(filename, rowList,
+                    fileMakingOption);
+            final TokenFileOutputResult tokeFileOutputResult = new TokenFileOutputResult();
+            tokeFileOutputResult.setSelectedList(ls);
+            return tokeFileOutputResult;
+        }
+    }
+
+    // ===================================================================================
+    //                                                                     Delegate Method
+    //                                                                     ===============
+    /**
+     * The implementation.
+     * 
+     * @return All count.
+     */
+    protected int callGetCountAll() {
+        final java.lang.reflect.Method mtd = getMethod(getDaoReadable()
+                .getClass(), "getCountAll", new Class[] {});
+        final Object result = invoke(mtd, getDaoReadable(), new Object[] {});
+        return ((Integer) result).intValue();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return All list. (NotNull)
+     */
+    protected java.util.List<Entity> callGetListAll() {
+        final java.lang.reflect.Method mtd = getMethod(getDaoReadable()
+                .getClass(), "getListAll", new Class[] {});
+        final Object result = invoke(mtd, getDaoReadable(), new Object[] {});
+        return (java.util.List<Entity>) result;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param cb Condition-bean that the type is condition-bean-interface. (NotNull)
+     * @return Read count. (NotNull)
+     */
+    protected int callReadCount(ConditionBean cb) {
+        assertConditionBeanNotNull(cb);
+        final Class[] types = new Class[] { cb.getClass() };
+        final java.lang.reflect.Method mtd = getMethod(getDaoReadable()
+                .getClass(), "selectCount", types);
+        final Object result = invoke(mtd, getDaoReadable(), new Object[] { cb });
+        return ((Integer) result).intValue();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param cb Condition-bean that the type is condition-bean-interface. (NotNull)
+     * @return Read entity. If the select result is zero, it returns null. (Nullable)
+     */
+    protected Entity callReadEntity(ConditionBean cb) {
+        assertConditionBeanNotNull(cb);
+        final Class[] types = new Class[] { cb.getClass() };
+        final java.lang.reflect.Method mtd = getMethod(getDaoReadable()
+                .getClass(), "selectEntity", types);
+        final Object result = invoke(mtd, getDaoReadable(), new Object[] { cb });
+        return (Entity) result;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param cb Condition-bean that the type is condition-bean-interface. (NotNull)
+     * @return Read list. If the select result is zero, it returns empty list. (NotNull)
+     */
+    protected java.util.List<Entity> callReadList(ConditionBean cb) {
+        assertConditionBeanNotNull(cb);
+        final Class[] types = new Class[] { cb.getClass() };
+        final java.lang.reflect.Method mtd = getMethod(getDaoReadable()
+                .getClass(), "selectList", types);
+        final Object result = invoke(mtd, getDaoReadable(), new Object[] { cb });
+        return (java.util.List<Entity>) result;
+    }
+
+    private java.lang.reflect.Method getMethod(Class clazz, String methodName,
+            Class[] argTypes) {
+        try {
+            return clazz.getMethod(methodName, argTypes);
+        } catch (NoSuchMethodException ex) {
+            String msg = "class=" + clazz + " method=" + methodName + "-"
+                    + java.util.Arrays.asList(argTypes);
+            throw new RuntimeException(msg, ex);
+        }
+    }
+
+    private Object invoke(java.lang.reflect.Method method, Object target,
+            Object[] args) {
+        try {
+            return method.invoke(target, args);
+        } catch (java.lang.reflect.InvocationTargetException ex) {
+            Throwable t = ex.getCause();
+            if (t instanceof RuntimeException) {
+                throw (RuntimeException) t;
+            }
+            if (t instanceof Error) {
+                throw (Error) t;
+            }
+            String msg = "target=" + target + " method=" + method + "-"
+                    + java.util.Arrays.asList(args);
+            throw new RuntimeException(msg, ex);
+        } catch (IllegalAccessException ex) {
+            String msg = "target=" + target + " method=" + method + "-"
+                    + java.util.Arrays.asList(args);
+            throw new RuntimeException(msg, ex);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                Optimistic Lock Info
+    //                                                                ====================
+    protected abstract boolean hasVersionNoValue(Entity entity);
+
+    protected abstract boolean hasUpdateDateValue(Entity entity);
+
+    // ===================================================================================
+    //                                                                              Helper
+    //                                                                              ======
+    /**
+     * To lower case if the type is String.
+     * 
+     * @param obj Object. (Nullable)
+     * @return Lower object. (Nullable)
+     */
+    protected Object toLowerCaseIfString(Object obj) {
+        if (obj != null && obj instanceof String) {
+            return ((String) obj).toLowerCase();
+        }
+        return obj;
+    }
+
+    /**
+     * Get the value of line separator.
+     * 
+     * @return The value of line separator. (NotNull)
+     */
+    protected String getLineSeparator() {
+        return System.getProperty("line.separator");
+    }
+
+    protected <ENTITY_TYPE extends Entity> ENTITY_TYPE helpDowncastInternally(
+            Entity entity, Class<ENTITY_TYPE> clazz) {
+        assertObjectNotNull("entity", entity);
+        assertObjectNotNull("clazz", clazz);
+        try {
+            return (ENTITY_TYPE) entity;
+        } catch (ClassCastException e) {
+            String msg = "The entity should be " + clazz.getSimpleName()
+                    + " but it was: " + entity.getClass();
+            throw new RuntimeException(msg, e);
+        }
+    }
+
+    // ----------------------------------------------------------------
+    //                                                    Assert Object
+    //                                                    -------------
+    /**
+     * Assert that the object is not null.
+     * 
+     * @param variableName Variable name. (NotNull)
+     * @param value Value. (NotNull)
+     * @exception IllegalArgumentException
+     */
+    protected void assertObjectNotNull(String variableName, Object value) {
+        if (variableName == null) {
+            String msg = "The value should not be null: variableName="
+                    + variableName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+        if (value == null) {
+            String msg = "The value should not be null: variableName="
+                    + variableName;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    /**
+     * Assert that the entity is not null.
+     * 
+     * @param entity Entity. (NotNull)
+     */
+    protected void assertEntityNotNull(Entity entity) {
+        assertObjectNotNull("entity", entity);
+    }
+
+    /**
+     * Assert that the condition-bean is not null.
+     * 
+     * @param cb Condition-bean. (NotNull)
+     */
+    protected void assertConditionBeanNotNull(
+            jp.sf.pal.announcement.db.allcommon.cbean.ConditionBean cb) {
+        assertObjectNotNull("cb", cb);
+    }
+
+    /**
+     * Assert that the entity has primary-key value.
+     * 
+     * @param entity Entity. (NotNull)
+     */
+    protected void assertEntityNotNullAndHasPrimaryKeyValue(Entity entity) {
+        assertEntityNotNull(entity);
+        if (!entity.hasPrimaryKeyValue()) {
+            String msg = "The entity must should primary-key: entity=" + entity;
+            throw new IllegalArgumentException(msg + entity);
+        }
+    }
+
+    // ----------------------------------------------------------------
+    //                                                    Assert String
+    //                                                    -------------
+    /**
+     * Assert that the entity is not null and not trimmed empty.
+     * 
+     * @param variableName Variable name. (NotNull)
+     * @param value Value. (NotNull)
+     */
+    protected void assertStringNotNullAndNotTrimmedEmpty(String variableName,
+            String value) {
+        assertObjectNotNull("variableName", variableName);
+        assertObjectNotNull(variableName, value);
+        if (value.trim().length() == 0) {
+            String msg = "The value should not be empty: variableName="
+                    + variableName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    // ----------------------------------------------------------------
+    //                                                      Assert List
+    //                                                      -----------
+    /**
+     * Assert that the list is empty.
+     * 
+     * @param ls List. (NotNull)
+     */
+    protected void assertListNotNullAndEmpty(java.util.List ls) {
+        assertObjectNotNull("ls", ls);
+        if (!ls.isEmpty()) {
+            String msg = "The list should be empty: ls=" + ls.toString();
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    /**
+     * Assert that the list is not empty.
+     * 
+     * @param ls List. (NotNull)
+     */
+    protected void assertListNotNullAndNotEmpty(java.util.List ls) {
+        assertObjectNotNull("ls", ls);
+        if (ls.isEmpty()) {
+            String msg = "The list should not be empty: ls=" + ls.toString();
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    /**
+     * Assert that the list having only one.
+     * 
+     * @param ls List. (NotNull)
+     */
+    protected void assertListNotNullAndHasOnlyOne(java.util.List ls) {
+        assertObjectNotNull("ls", ls);
+        if (ls.size() != 1) {
+            String msg = "The list should contain only one object: ls="
+                    + ls.toString();
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    /**
+     * Get the selector of behavior.
+     * 
+     * @return The select of behavior. (Nullable: But normally NotNull)
+     */
+    protected BehaviorSelector getBehaviorSelector() {
+        return _behaviorSelector;
+    }
+
+    /**
+     * Set the selector of behavior.
+     * 
+     * @param behaviorSelector The selector of behavior. (NotNull)
+     */
+    public void setBehaviorSelector(BehaviorSelector behaviorSelector) {
+        this._behaviorSelector = behaviorSelector;
+    }
+
+    /**
+     * Get the selector of dao.
+     * 
+     * @return The select of behavior. (Nullable: But normally NotNull)
+     */
+    protected DaoSelector getDaoSelector() {
+        return _daoSelector;
+    }
+
+    /**
+     * Set the selector of dao.
+     * 
+     * @param daoSelector The selector of dao. (NotNull)
+     */
+    public void setDaoSelector(DaoSelector daoSelector) {
+        _daoSelector = daoSelector;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/AbstractBehaviorReadable.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/AbstractBehaviorWritable.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/AbstractBehaviorWritable.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/AbstractBehaviorWritable.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,904 @@
+package jp.sf.pal.announcement.db.allcommon.bhv;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import jp.sf.pal.announcement.db.allcommon.Entity;
+import jp.sf.pal.announcement.db.allcommon.bhv.batch.TokenFileReflectionFailure;
+import jp.sf.pal.announcement.db.allcommon.bhv.batch.TokenFileReflectionOption;
+import jp.sf.pal.announcement.db.allcommon.bhv.batch.TokenFileReflectionResult;
+import jp.sf.pal.announcement.db.allcommon.cbean.ConditionBean;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMeta;
+import jp.sf.pal.announcement.db.allcommon.helper.MapStringBuilder;
+import jp.sf.pal.announcement.db.allcommon.helper.MapStringBuilderImpl;
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.FileToken;
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.FileTokenizingCallback;
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.FileTokenizingHeaderInfo;
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.FileTokenizingOption;
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.FileTokenizingRowResource;
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.impl.FileTokenImpl;
+
+/**
+ * The abstract class of behavior-writable.
+ * @author DBFlute(AutoGenerator)
+ */
+public abstract class AbstractBehaviorWritable extends AbstractBehaviorReadable
+        implements BehaviorWritable {
+
+    // ===================================================================================
+    //                                                                 Basic Entity Update
+    //                                                                 ===================
+    // -----------------------------------------------------
+    //                                                Create
+    //                                                ------
+    /**
+     * Create.
+     * @param entity Entity. (NotNull)
+     */
+    public void create(Entity entity) {
+        doCreate(entity);
+    }
+
+    protected abstract void doCreate(Entity entity);
+
+    // -----------------------------------------------------
+    //                                                Modify
+    //                                                ------
+    /**
+     * Modify.
+     * @param entity Entity. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException When the entity has already been updated.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public void modify(Entity entity) {
+        doModify(entity);
+    }
+
+    protected abstract void doModify(Entity entity);
+
+    /**
+     * Modify non strict.
+     * @param entity Entity. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public void modifyNonstrict(Entity entity) {
+        doModifyNonstrict(entity);
+    }
+
+    protected abstract void doModifyNonstrict(Entity entity);
+
+    // -----------------------------------------------------
+    //                                      Create or Modify
+    //                                      ----------------
+    /**
+     * The implementation.
+     * @param entity Entity. This must contain primary-key value at least(Except use identity). (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException When the entity has already been updated.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public void createOrModify(jp.sf.pal.announcement.db.allcommon.Entity entity) {
+        assertEntityNotNull(entity);
+        doCreateOrUpdate(entity);
+    }
+
+    protected abstract void doCreateOrUpdate(Entity entity);
+
+    /**
+     * The implementation.
+     * @param entity Entity. This must contain primary-key value at least(Except use identity). (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public void createOrModifyNonstrict(
+            jp.sf.pal.announcement.db.allcommon.Entity entity) {
+        assertEntityNotNull(entity);
+        doCreateOrUpdateNonstrict(entity);
+    }
+
+    protected abstract void doCreateOrUpdateNonstrict(Entity entity);
+
+    // -----------------------------------------------------
+    //                                                Remove
+    //                                                ------
+    /**
+     * Remove.
+     * @param entity Entity. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException When the entity has already been updated.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public void remove(jp.sf.pal.announcement.db.allcommon.Entity entity) {
+        assertEntityNotNull(entity);
+        callRemove(entity);
+    }
+
+    protected abstract void doRemove(Entity entity);
+
+    // ===================================================================================
+    //                                                 Basic Entity Update Internal Helper
+    //                                                 ===================================
+    // -----------------------------------------------------
+    //                                                Update
+    //                                                ------
+    protected <ENTITY_TYPE extends Entity> void helpUpdateInternally(
+            ENTITY_TYPE entity, InternalUpdateCallback<ENTITY_TYPE> callback) {
+        assertEntityNotNull(entity);
+        assertEntityHasVersionNoValue(entity);
+        assertEntityHasUpdateDateValue(entity);
+        final int updatedCount = callback.callbackDelegateUpdate(entity);
+        if (updatedCount == 0) {
+            String msg = "The entity was Not Found! it has already been deleted: entity="
+                    + entity;
+            throw new jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException(
+                    msg);
+        } else if (updatedCount > 1) {
+            String msg = "The entity was Too Many! it has been duplicated. It should be the only one! But the updatedCount="
+                    + updatedCount;
+            msg = msg + ": entity=" + entity;
+            throw new jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException(
+                    msg);
+        }
+    }
+
+    protected static interface InternalUpdateCallback<ENTITY_TYPE extends Entity> {
+        public int callbackDelegateUpdate(ENTITY_TYPE entity);
+    }
+
+    protected <ENTITY_TYPE extends Entity> void helpUpdateNonstrictInternally(
+            ENTITY_TYPE entity,
+            InternalUpdateNonstrictCallback<ENTITY_TYPE> callback) {
+        assertEntityNotNull(entity);
+        final int updatedCount = callback
+                .callbackDelegateUpdateNonstrict(entity);
+        if (updatedCount == 0) {
+            String msg = "The entity was Not Found! it has already been deleted: entity="
+                    + entity;
+            throw new jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException(
+                    msg);
+        } else if (updatedCount > 1) {
+            String msg = "The entity was Too Many! it has been duplicated. It should be the only one! But the updatedCount="
+                    + updatedCount;
+            msg = msg + ": entity=" + entity;
+        }
+    }
+
+    protected static interface InternalUpdateNonstrictCallback<ENTITY_TYPE extends Entity> {
+        public int callbackDelegateUpdateNonstrict(ENTITY_TYPE entity);
+    }
+
+    // -----------------------------------------------------
+    //                                        InsertOrUpdate
+    //                                        --------------
+    protected <ENTITY_TYPE extends Entity, CB_TYPE extends ConditionBean> void helpInsertOrUpdateInternally(
+            ENTITY_TYPE entity,
+            InternalInsertOrUpdateCallback<ENTITY_TYPE, CB_TYPE> callback) {
+        assertEntityNotNull(entity);
+        if (!entity.hasPrimaryKeyValue()) {
+            callback.callbackInsert(entity);
+        } else {
+            RuntimeException exception = null;
+            try {
+                callback.callbackUpdate(entity);
+            } catch (jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException e) {
+                if (e.getRows() == 0) {
+                    exception = e;
+                }
+            } catch (jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException e) {
+                exception = e;
+            } catch (IllegalStateException e) {
+                exception = e;
+            }
+            if (exception != null) {
+                final CB_TYPE cb = callback.callbackNewMyConditionBean();
+                cb.acceptPrimaryKeyMapString(getDBMeta()
+                        .extractPrimaryKeyMapString(entity));
+                if (callback.callbackSelectCount(cb) == 0) {
+                    callback.callbackInsert(entity);
+                } else {
+                    throw exception;
+                }
+            }
+        }
+    }
+
+    protected static interface InternalInsertOrUpdateCallback<ENTITY_TYPE extends Entity, CB_TYPE extends ConditionBean> {
+        public void callbackInsert(ENTITY_TYPE entity);
+
+        public void callbackUpdate(ENTITY_TYPE entity);
+
+        public CB_TYPE callbackNewMyConditionBean();
+
+        public int callbackSelectCount(CB_TYPE cb);
+    }
+
+    protected <ENTITY_TYPE extends Entity> void helpInsertOrUpdateInternally(
+            ENTITY_TYPE entity,
+            InternalInsertOrUpdateNonstrictCallback<ENTITY_TYPE> callback) {
+        assertEntityNotNull(entity);
+        if (!entity.hasPrimaryKeyValue()) {
+            callback.callbackInsert(entity);
+        } else {
+            try {
+                callback.callbackUpdateNonstrict(entity);
+            } catch (jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException e) {
+                callback.callbackInsert(entity);
+            } catch (jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException e) {
+                callback.callbackInsert(entity);
+            }
+        }
+    }
+
+    protected static interface InternalInsertOrUpdateNonstrictCallback<ENTITY_TYPE extends Entity> {
+        public void callbackInsert(ENTITY_TYPE entity);
+
+        public void callbackUpdateNonstrict(ENTITY_TYPE entity);
+    }
+
+    // -----------------------------------------------------
+    //                                                Delete
+    //                                                ------
+    protected <ENTITY_TYPE extends Entity> void helpDeleteInternally(
+            ENTITY_TYPE entity, InternalDeleteCallback<ENTITY_TYPE> callback) {
+        assertEntityNotNull(entity);
+        assertEntityHasVersionNoValue(entity);
+        assertEntityHasUpdateDateValue(entity);
+        final int deletedCount = callback.callbackDelegateDelete(entity);
+        if (deletedCount == 0) {
+            String msg = "The entity was Not Found! The entity has already been deleted: entity="
+                    + entity;
+            throw new jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException(
+                    msg);
+        } else if (deletedCount > 1) {
+            String msg = "The deleted entity was duplicated. It should be the only one! But the deletedCount="
+                    + deletedCount;
+            msg = msg + ": entity=" + entity;
+        }
+    }
+
+    protected static interface InternalDeleteCallback<ENTITY_TYPE extends Entity> {
+        public int callbackDelegateDelete(ENTITY_TYPE entity);
+    }
+
+    protected <ENTITY_TYPE extends Entity> void helpDeleteNonstrictInternally(
+            ENTITY_TYPE entity,
+            InternalDeleteNonstrictCallback<ENTITY_TYPE> callback) {
+        assertEntityNotNull(entity);
+        final int deletedCount = callback
+                .callbackDelegateDeleteNonstrict(entity);
+        if (deletedCount == 0) {
+            String msg = "The entity was Not Found! The entity has already been deleted: entity="
+                    + entity;
+            throw new jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException(
+                    msg);
+        } else if (deletedCount > 1) {
+            String msg = "The deleted entity was duplicated. It should be the only one! But the deletedCount="
+                    + deletedCount;
+            msg = msg + ": entity=" + entity;
+        }
+    }
+
+    protected static interface InternalDeleteNonstrictCallback<ENTITY_TYPE extends Entity> {
+        public int callbackDelegateDeleteNonstrict(ENTITY_TYPE entity);
+    }
+
+    protected <ENTITY_TYPE extends Entity> void helpDeleteNonstrictIgnoreDeletedInternally(
+            ENTITY_TYPE entity,
+            InternalDeleteNonstrictIgnoreDeletedCallback<ENTITY_TYPE> callback) {
+        assertEntityNotNull(entity);
+        final int deletedCount = callback
+                .callbackDelegateDeleteNonstrict(entity);
+        if (deletedCount == 0) {
+            return;
+        } else if (deletedCount > 1) {
+            String msg = "The deleted entity was duplicated. It should be the only one! But the deletedCount="
+                    + deletedCount;
+            msg = msg + ": entity=" + entity;
+        }
+    }
+
+    protected static interface InternalDeleteNonstrictIgnoreDeletedCallback<ENTITY_TYPE extends Entity> {
+        public int callbackDelegateDeleteNonstrict(ENTITY_TYPE entity);
+    }
+
+    // ===================================================================================
+    //                                                                   Basic Lump Update
+    //                                                                   =================
+    /**
+     * Lump create the list.
+     * @param entityList Entity list. (NotNull and NotEmpty)
+     * @return The array of created count.
+     */
+    public int[] lumpCreate(java.util.List<Entity> entityList) {
+        assertListNotNullAndNotEmpty(entityList);
+        return callCreateList(entityList);
+    }
+
+    /**
+     * Lump Modify the list.
+     * @param entityList Entity list. (NotNull and NotEmpty)
+     * @return Modified count.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException If s2dao's version is over 1.0.47 (contains 1.0.47).
+     */
+    public int[] lumpModify(java.util.List<Entity> entityList) {
+        assertListNotNullAndNotEmpty(entityList);
+        return callModifyList(entityList);
+    }
+
+    /**
+     * Lump remove the list.
+     * @param entityList Entity list. (NotNull and NotEmpty)
+     * @return Removed count.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException If s2dao's version is over 1.0.47 (contains 1.0.47).
+     */
+    public int[] lumpRemove(java.util.List<Entity> entityList) {
+        assertListNotNullAndNotEmpty(entityList);
+        return callRemoveList(entityList);
+    }
+
+    /**
+     * Inject sequence to primary key if it needs.
+     * @param entity Entity. (NotNull)
+     */
+    protected void injectSequenceToPrimaryKeyIfNeeds(Entity entity) {
+        final DBMeta dbmeta = entity.getDBMeta();
+        if (!dbmeta.hasSequence() || dbmeta.hasTwoOrMorePrimaryKeys()
+                || entity.hasPrimaryKeyValue()) {
+            return;
+        }
+        final java.math.BigDecimal sequenceValue = readNextVal();
+        final String columnDbName = dbmeta.getPrimaryUniqueInfo()
+                .getFirstColumn().getColumnDbName();
+        final java.util.Map<String, String> map = new java.util.HashMap<String, String>();
+        map.put(columnDbName, sequenceValue.toString());
+        dbmeta.acceptPrimaryKeyMap(entity, map);
+    }
+
+    // =====================================================================================
+    //                                                                            Token File
+    //                                                                            ==========
+    public TokenFileReflectionExecutor tokenFileReflection() {
+        return new TokenFileReflectionExecutor();
+    }
+
+    public class TokenFileReflectionExecutor {
+
+        /**
+         * Reflect(insert or update) token-file to this table.
+         * @param filename Name of the file. (NotNull and NotEmpty)
+         * @param tokenFileReflectionOption token-file-reflection-option. (NotNull and Required{delimiter and encoding})
+         * @return Token-file-reflection-result. (NotNull)
+         * @throws java.io.FileNotFoundException
+         * @throws java.io.IOException
+         */
+        public TokenFileReflectionResult reflectTokenFile(String filename,
+                TokenFileReflectionOption tokenFileReflectionOption)
+                throws java.io.FileNotFoundException, java.io.IOException {
+            assertStringNotNullAndNotTrimmedEmpty("filename", filename);
+            assertFileTokenReflectionOption(tokenFileReflectionOption);
+
+            final TokenFileReflectionResult result = buildTokenFileReflectionResult();
+            final FileTokenizingCallback fileTokenizingCallback = buildFileTokenReflectionFileTokenizingCallback(
+                    tokenFileReflectionOption, result);
+            final FileTokenizingOption fileTokenizingOption = buildFileTokenReflectionFileTokenizingOption(tokenFileReflectionOption);
+            final FileToken fileToken = new FileTokenImpl();
+            fileToken.tokenize(filename, fileTokenizingCallback,
+                    fileTokenizingOption);
+            return result;
+        }
+
+        /**
+         * Reflect(insert or update) token-file to this table.
+         * @param inputStream Input stream. (NotNull and NotClosed)
+         * @param tokenFileReflectionOption token-file-reflection-option. (NotNull and Required{delimiter and encoding})
+         * @return Token-file-reflection-result. (NotNull)
+         * @throws java.io.FileNotFoundException
+         * @throws java.io.IOException
+         */
+        public TokenFileReflectionResult reflectTokenFile(
+                java.io.InputStream inputStream,
+                TokenFileReflectionOption tokenFileReflectionOption)
+                throws java.io.FileNotFoundException, java.io.IOException {
+            assertObjectNotNull("inputStream", inputStream);
+            assertFileTokenReflectionOption(tokenFileReflectionOption);
+
+            final TokenFileReflectionResult result = buildTokenFileReflectionResult();
+            final FileTokenizingCallback fileTokenizingCallback = buildFileTokenReflectionFileTokenizingCallback(
+                    tokenFileReflectionOption, result);
+            final FileTokenizingOption fileTokenizingOption = buildFileTokenReflectionFileTokenizingOption(tokenFileReflectionOption);
+            final FileToken fileToken = new FileTokenImpl();
+            fileToken.tokenize(inputStream, fileTokenizingCallback,
+                    fileTokenizingOption);
+            return result;
+        }
+
+        protected void assertFileTokenReflectionOption(
+                TokenFileReflectionOption tokenFileReflectionOption) {
+            assertObjectNotNull("tokenFileReflectionOption",
+                    tokenFileReflectionOption);
+
+            final String encoding = tokenFileReflectionOption.getEncoding();
+            final String delimiter = tokenFileReflectionOption.getDelimiter();
+            assertStringNotNullAndNotTrimmedEmpty("encoding", encoding);
+            assertObjectNotNull("delimiter", delimiter);
+        }
+
+        protected TokenFileReflectionResult buildTokenFileReflectionResult() {
+            final TokenFileReflectionResult result = new TokenFileReflectionResult();
+            final java.util.List<TokenFileReflectionFailure> failureList = new java.util.ArrayList<TokenFileReflectionFailure>();
+            result.setFailureList(failureList);
+            return result;
+        }
+
+        protected FileTokenizingCallback buildFileTokenReflectionFileTokenizingCallback(
+                TokenFileReflectionOption tokenFileReflectionOption,
+                final TokenFileReflectionResult result)
+                throws java.io.FileNotFoundException, java.io.IOException {
+            assertObjectNotNull("tokenFileReflectionOption",
+                    tokenFileReflectionOption);
+
+            final String encoding = tokenFileReflectionOption.getEncoding();
+            final String delimiter = tokenFileReflectionOption.getDelimiter();
+            final boolean interruptIfError = tokenFileReflectionOption
+                    .isInterruptIfError();
+            assertStringNotNullAndNotTrimmedEmpty("encoding", encoding);
+            assertObjectNotNull("delimiter", delimiter);
+            final java.util.List<TokenFileReflectionFailure> failureList = result
+                    .getFailureList();
+            assertObjectNotNull("failureList", failureList);
+
+            final FileTokenizingCallback fileTokenizingCallback = new FileTokenizingCallback() {
+                public void handleRowResource(
+                        FileTokenizingRowResource fileTokenizingRowResource) {
+                    final FileTokenizingHeaderInfo fileTokenizingHeaderInfo = fileTokenizingRowResource
+                            .getFileTokenizingHeaderInfo();
+                    final java.util.List<String> columnNameList = fileTokenizingHeaderInfo
+                            .getColumnNameList();
+                    final java.util.List<String> valueList = fileTokenizingRowResource
+                            .getValueList();
+
+                    // Set up columnNameList of result object.
+                    if (result.getColumnNameList() == null) {
+                        result.setColumnNameList(columnNameList);
+                    }
+
+                    Entity entity = null;
+                    try {
+                        // Create entity by the list of value composed of String.
+                        entity = createEntityByStringValueList(columnNameList,
+                                valueList);
+
+                        // Create or modify as non-strict.
+                        doCreateOrUpdateNonstrict(entity);
+
+                        // Increment successCount of result object.
+                        result.incrementSuccessCount();
+                    } catch (RuntimeException e) {
+                        if (interruptIfError) {
+                            throw e;
+                        }
+                        final TokenFileReflectionFailure failure = new TokenFileReflectionFailure();
+                        failure.setColumnNameList(columnNameList);
+                        failure.setValueList(valueList);
+                        failure.setRowString(fileTokenizingRowResource
+                                .getRowString());
+                        failure.setRowNumber(fileTokenizingRowResource
+                                .getRowNumber());
+                        failure.setLineNumber(fileTokenizingRowResource
+                                .getLineNumber());
+                        if (entity != null) {
+                            failure.setEntity(entity);
+                        }
+                        failure.setException(e);
+                        failureList.add(failure);
+                    }
+                }
+            };
+            return fileTokenizingCallback;
+        }
+
+        protected Entity createEntityByStringValueList(
+                java.util.List<String> columnNameList,
+                java.util.List<String> valueList) {
+            final MapStringBuilder builder = new MapStringBuilderImpl();
+            builder.setMsMapMark(MAP_STRING_MAP_MARK);
+            builder.setMsStartBrace(MAP_STRING_START_BRACE);
+            builder.setMsEndBrace(MAP_STRING_END_BRACE);
+            builder.setMsDelimiter(MAP_STRING_DELIMITER);
+            builder.setMsEqual(MAP_STRING_EQUAL);
+            builder.setColumnNameList(columnNameList);
+            final String mapString = builder.buildFromList(valueList);
+
+            final Entity entity = getDBMeta().newEntity();
+            getDBMeta().acceptColumnValueMapString(entity, mapString);
+            return entity;
+        }
+
+        protected FileTokenizingOption buildFileTokenReflectionFileTokenizingOption(
+                TokenFileReflectionOption tokenFileReflectionOption)
+                throws java.io.FileNotFoundException, java.io.IOException {
+            assertObjectNotNull("tokenFileReflectionOption",
+                    tokenFileReflectionOption);
+
+            final String encoding = tokenFileReflectionOption.getEncoding();
+            final String delimiter = tokenFileReflectionOption.getDelimiter();
+            assertStringNotNullAndNotTrimmedEmpty("encoding", encoding);
+            assertObjectNotNull("delimiter", delimiter);
+
+            final FileTokenizingOption fileTokenizingOption = new FileTokenizingOption();
+            fileTokenizingOption.setEncoding(encoding);
+            fileTokenizingOption.setDelimiter(delimiter);
+            if (tokenFileReflectionOption.isHandleEmptyAsNull()) {
+                fileTokenizingOption.handleEmptyAsNull();
+            }
+            return fileTokenizingOption;
+        }
+    }
+
+    // =====================================================================================
+    //                                                                       Delegate Method
+    //                                                                       ===============
+    // -----------------------------------------------------
+    //                                                Insert
+    //                                                ------
+    /**
+     * The implementation.
+     * @param entity Entity that the type is entity interface. (NotNull)
+     * @return Inserted count.
+     */
+    protected int callCreate(Entity entity) {
+        if (!processBeforeInsert(entity)) {
+            return 1;/*as Normal End*/
+        }
+        return getDaoWritable().create(entity);
+    }
+
+    /**
+     * Process before insert.
+     * @param entity Entity that the type is entity interface. (NotNull)
+     * @return Execution Determination. (true: execute / false: non)
+     */
+    protected boolean processBeforeInsert(Entity entity) {
+        if (!determineExecuteInsert(entity)) {
+            return false;
+        }
+        assertEntityNotNull(entity);// If this table use identity, the entity does not have primary-key.
+        frameworkFilterEntityOfInsert(entity);
+        filterEntityOfInsert(entity);
+        assertEntityOfInsert(entity);
+        return true;
+    }
+
+    // -----------------------------------------------------
+    //                                                Update
+    //                                                ------
+    /**
+     * The implementation.
+     * {modified only}
+     * @param entity Entity that the type is entity interface. (NotNull)
+     * @return Updated count.
+     */
+    protected int callModify(Entity entity) {
+        if (!processBeforeUpdate(entity)) {
+            return 1;/*as Normal End*/
+        }
+        return getDaoWritable().modifyModifiedOnly(entity);
+    }
+
+    /**
+     * Process before update.
+     * @param entity Entity that the type is entity interface. (NotNull)
+     * @return Execution Determination. (true: execute / false: non)
+     */
+    protected boolean processBeforeUpdate(Entity entity) {
+        if (!determineExecuteUpdate(entity)) {
+            return false;
+        }
+        assertEntityNotNullAndHasPrimaryKeyValue(entity);
+        frameworkFilterEntityOfUpdate(entity);
+        filterEntityOfUpdate(entity);
+        assertEntityOfUpdate(entity);
+        return true;
+    }
+
+    // -----------------------------------------------------
+    //                                                Delete
+    //                                                ------
+    /**
+     * The implementation.
+     * @param entity Entity that the type is entity interface. (NotNull)
+     * @return Deleted count.
+     */
+    protected int callRemove(Entity entity) {
+        if (!processBeforeDelete(entity)) {
+            return 1;/*as Normal End*/
+        }
+        return getDaoWritable().remove(entity);
+    }
+
+    /**
+     * Process before delete.
+     * @param entity Entity that the type is entity interface. (NotNull)
+     * @return Execution Determination. (true: execute / false: non)
+     */
+    protected boolean processBeforeDelete(Entity entity) {
+        if (!determineExecuteDelete(entity)) {
+            return false;
+        }
+        assertEntityNotNullAndHasPrimaryKeyValue(entity);
+        frameworkFilterEntityOfDelete(entity);
+        filterEntityOfDelete(entity);
+        assertEntityOfDelete(entity);
+        return true;
+    }
+
+    // -----------------------------------------------------
+    //                                    Pre-Process Insert
+    //                                    ------------------
+    /**
+     * Determine execution of insert.
+     * @param entity Entity. (NotNull)
+     * @return Execution Determination. (true: execute / false: non)
+     */
+    protected boolean determineExecuteInsert(Entity entity) {
+        return true;
+    }
+
+    /**
+     * {Framework Method} Filter the entity of insert.
+     * @param targetEntity Target entity that the type is entity interface. (NotNull)
+     */
+    protected void frameworkFilterEntityOfInsert(Entity targetEntity) {
+        injectSequenceToPrimaryKeyIfNeeds(targetEntity);
+        setupCommonColumnOfInsertIfNeeds(targetEntity);
+    }
+
+    /**
+     * Set up common columns of insert if it needs.
+     * @param targetEntity Target entity that the type is entity interface. (NotNull)
+     */
+    protected void setupCommonColumnOfInsertIfNeeds(Entity targetEntity) {
+    }
+
+    /**
+     * Filter the entity of insert.
+     * @param targetEntity Target entity that the type is entity interface. (NotNull)
+     */
+    protected void filterEntityOfInsert(Entity targetEntity) {
+    }
+
+    /**
+     * Assert the entity of insert.
+     * @param entity Entity that the type is entity interface. (NotNull)
+     */
+    protected void assertEntityOfInsert(Entity entity) {
+    }
+
+    // -----------------------------------------------------
+    //                                    Pre-Process Update
+    //                                    ------------------
+    /**
+     * Determine execution of update.
+     * @param entity Entity. (NotNull)
+     * @return Execution Determination. (true: execute / false: non)
+     */
+    protected boolean determineExecuteUpdate(Entity entity) {
+        return true;
+    }
+
+    /**
+     * {Framework Method} Filter the entity of update.
+     * @param targetEntity Target entity that the type is entity interface. (NotNull)
+     */
+    protected void frameworkFilterEntityOfUpdate(Entity targetEntity) {
+        setupCommonColumnOfUpdateIfNeeds(targetEntity);
+    }
+
+    /**
+     * Set up common columns of update if it needs.
+     * @param targetEntity Target entity that the type is entity interface. (NotNull)
+     */
+    protected void setupCommonColumnOfUpdateIfNeeds(Entity targetEntity) {
+    }
+
+    /**
+     * Filter the entity of update.
+     * @param targetEntity Target entity that the type is entity interface. (NotNull)
+     */
+    protected void filterEntityOfUpdate(Entity targetEntity) {
+    }
+
+    /**
+     * Assert the entity of update.
+     * @param entity Entity that the type is entity interface. (NotNull)
+     */
+    protected void assertEntityOfUpdate(Entity entity) {
+    }
+
+    // -----------------------------------------------------
+    //                                    Pre-Process Delete
+    //                                    ------------------
+    /**
+     * Determine execution of delete.
+     * @param entity Entity. (NotNull)
+     * @return Execution Determination. (true: execute / false: non)
+     */
+    protected boolean determineExecuteDelete(Entity entity) {
+        return true;
+    }
+
+    /**
+     * {Framework Method} Filter the entity of delete.
+     * @param targetEntity Target entity that the type is entity interface. (NotNull)
+     */
+    protected void frameworkFilterEntityOfDelete(Entity targetEntity) {
+        setupCommonColumnOfDeleteIfNeeds(targetEntity);
+    }
+
+    /**
+     * Set up common columns of delete if it needs.
+     * @param targetEntity Target entity that the type is entity interface. (NotNull)
+     */
+    protected void setupCommonColumnOfDeleteIfNeeds(Entity targetEntity) {
+    }
+
+    /**
+     * Filter the entity of delete.
+     * @param targetEntity Target entity that the type is entity interface. (NotNull)
+     */
+    protected void filterEntityOfDelete(Entity targetEntity) {
+    }
+
+    /**
+     * Assert the entity of delete.
+     * @param entity Entity that the type is entity interface. (NotNull)
+     */
+    protected void assertEntityOfDelete(Entity entity) {
+    }
+
+    /**
+     * The implementation.
+     * @param entityList Entity list that the type is entity interface. (NotNull)
+     * @return Inserted count.
+     */
+    public int[] callCreateList(java.util.List<Entity> entityList) {
+        assertObjectNotNull("entityList", entityList);
+        helpFilterBeforeInsertInternally(entityList);
+        return getDaoWritable().createList(entityList);
+    }
+
+    /**
+     * The implementation.
+     * @param entityList Entity list that the type is entity interface. (NotNull)
+     * @return Updated count.
+     */
+    public int[] callModifyList(java.util.List<Entity> entityList) {
+        assertObjectNotNull("entityList", entityList);
+        helpFilterBeforeUpdateInternally(entityList);
+        return getDaoWritable().modifyList(entityList);
+    }
+
+    /**
+     * The implementation.
+     * @param entityList Entity list that the type is entity interface. (NotNull)
+     * @return Deleted count.
+     */
+    public int[] callRemoveList(java.util.List<Entity> entityList) {
+        assertObjectNotNull("entityList", entityList);
+        helpFilterBeforeDeleteInternally(entityList);
+        return getDaoWritable().removeList(entityList);
+    }
+
+    protected void assertEntityHasVersionNoValue(Entity entity) {
+        if (!getDBMeta().hasVersionNo()) {
+            return;
+        }
+        if (hasVersionNoValue(entity)) {
+            return;
+        }
+        String msg = "Look! Read the message below." + getLineSeparator();
+        msg = msg
+                + "/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *"
+                + getLineSeparator();
+        msg = msg + "The value of 'version no' on the entity was Not Found!"
+                + getLineSeparator() + getLineSeparator();
+        msg = msg + "[Advice]" + getLineSeparator();
+        msg = msg
+                + "Please confirm the existence of the value of 'version no' on the entity."
+                + getLineSeparator();
+        msg = msg
+                + "You called the method in which the check for optimistic lock is indispensable. "
+                + getLineSeparator();
+        msg = msg + "So 'version no' is required on the entity. "
+                + getLineSeparator();
+        msg = msg
+                + "In addition, please confirm the necessity of optimistic lock. It might possibly be unnecessary."
+                + getLineSeparator() + getLineSeparator();
+        msg = msg + "[Entity]" + getLineSeparator();
+        msg = msg + "entity to string = " + entity + getLineSeparator();
+        msg = msg + "entity to map    = "
+                + entity.getDBMeta().convertToColumnValueMap(entity)
+                + getLineSeparator();
+        msg = msg + "* * * * * * * * * */" + getLineSeparator();
+        throw new IllegalStateException(msg);
+    }
+
+    protected void assertEntityHasUpdateDateValue(Entity entity) {
+        if (!getDBMeta().hasUpdateDate()) {
+            return;
+        }
+        if (hasUpdateDateValue(entity)) {
+            return;
+        }
+        String msg = "Look! Read the message below." + getLineSeparator();
+        msg = msg
+                + "/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *"
+                + getLineSeparator();
+        msg = msg + "The value of 'update date' on the entity was Not Found!"
+                + getLineSeparator() + getLineSeparator();
+        msg = msg + "[Advice]" + getLineSeparator();
+        msg = msg
+                + "Please confirm the existence of the value of 'update date' on the entity."
+                + getLineSeparator();
+        msg = msg
+                + "You called the method in which the check for optimistic lock is indispensable. "
+                + getLineSeparator();
+        msg = msg + "So 'update date' is required on the entity. "
+                + getLineSeparator();
+        msg = msg
+                + "In addition, please confirm the necessity of optimistic lock. It might possibly be unnecessary."
+                + getLineSeparator() + getLineSeparator();
+        msg = msg + "[Entity]" + getLineSeparator();
+        msg = msg + "entity to string = " + entity + getLineSeparator();
+        msg = msg + "entity to map    = "
+                + entity.getDBMeta().convertToColumnValueMap(entity)
+                + getLineSeparator();
+        msg = msg + "* * * * * * * * * */" + getLineSeparator();
+        throw new IllegalStateException(msg);
+    }
+
+    // ===================================================================================
+    //                                                     Delegate Method Internal Helper
+    //                                                     ===============================
+    protected <ENTITY extends Entity> List<ENTITY> helpFilterBeforeInsertInternally(
+            List<ENTITY> entityList) {
+        final List<ENTITY> filteredList = new ArrayList<ENTITY>();
+        for (final Iterator<ENTITY> ite = entityList.iterator(); ite.hasNext();) {
+            final ENTITY entity = ite.next();
+            if (!processBeforeInsert(entity)) {
+                continue;
+            }
+            filteredList.add(entity);
+        }
+        return filteredList;
+    }
+
+    protected <ENTITY extends Entity> List<ENTITY> helpFilterBeforeUpdateInternally(
+            List<ENTITY> entityList) {
+        final List<ENTITY> filteredList = new ArrayList<ENTITY>();
+        for (final Iterator<ENTITY> ite = entityList.iterator(); ite.hasNext();) {
+            final ENTITY entity = ite.next();
+            if (!processBeforeUpdate(entity)) {
+                continue;
+            }
+            filteredList.add(entity);
+        }
+        return filteredList;
+    }
+
+    protected <ENTITY extends Entity> List<ENTITY> helpFilterBeforeDeleteInternally(
+            List<ENTITY> entityList) {
+        final List<ENTITY> filteredList = new ArrayList<ENTITY>();
+        for (final Iterator<ENTITY> ite = entityList.iterator(); ite.hasNext();) {
+            final ENTITY entity = ite.next();
+            if (!processBeforeDelete(entity)) {
+                continue;
+            }
+            filteredList.add(entity);
+        }
+        return filteredList;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/AbstractBehaviorWritable.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/BehaviorReadable.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/BehaviorReadable.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/BehaviorReadable.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,221 @@
+package jp.sf.pal.announcement.db.allcommon.bhv;
+
+import jp.sf.pal.announcement.db.allcommon.DaoReadable;
+import jp.sf.pal.announcement.db.allcommon.Entity;
+import jp.sf.pal.announcement.db.allcommon.cbean.ConditionBean;
+import jp.sf.pal.announcement.db.allcommon.cbean.ListResultBean;
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingBean;
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingHandler;
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingInvoker;
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingResultBean;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMeta;
+
+/**
+ * The interface of behavior-readable.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public interface BehaviorReadable {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Map-string map-mark. */
+    public static final String MAP_STRING_MAP_MARK = "map:";
+
+    /** Map-string list-mark. */
+    public static final String MAP_STRING_LIST_MARK = "list:";
+
+    /** Map-string start-brace. */
+    public static final String MAP_STRING_START_BRACE = "@{";
+
+    /** Map-string end-brace. */
+    public static final String MAP_STRING_END_BRACE = "@}";
+
+    /** Map-string delimiter. */
+    public static final String MAP_STRING_DELIMITER = "@;";
+
+    /** Map-string equal. */
+    public static final String MAP_STRING_EQUAL = "@=";
+
+    // ===================================================================================
+    //                                                                          Table name
+    //                                                                          ==========
+    /**
+     * Get table db-name.
+     * 
+     * @return Table db-name. (NotNull)
+     */
+    public String getTableDbName();
+
+    // ===================================================================================
+    //                                                                              DBMeta
+    //                                                                              ======
+    /**
+     * Get dbmeta.
+     * 
+     * @return DBMeta. (NotNull)
+     */
+    public DBMeta getDBMeta();
+
+    // ===================================================================================
+    //                                                                        Dao Accessor
+    //                                                                        ============
+    /**
+     * Get dao-readable.
+     * 
+     * @return Dao-readable. (NotNull)
+     */
+    public DaoReadable getDaoReadable();
+
+    // ===================================================================================
+    //                                                                        New Instance
+    //                                                                        ============
+    /**
+     * New entity.
+     * 
+     * @return Entity. (NotNull)
+     */
+    public Entity newEntity();
+
+    /**
+     * New condition-bean.
+     * 
+     * @return Condition-bean. (NotNull)
+     */
+    public ConditionBean newConditionBean();
+
+    // ===================================================================================
+    //                                                                       Basic Get All
+    //                                                                       =============
+    /**
+     * Get count all.
+     * 
+     * @return Count all.
+     */
+    public int getCountAll();
+
+    // ===================================================================================
+    //                                                                    Basic Read Count
+    //                                                                    ================
+    /**
+     * Read count by condition-bean.
+     * <pre>
+     * If the argument 'condition-bean' is effective about fetch-scope,
+     * this method invoke select count ignoring the fetch-scope.
+     * </pre>
+     * @param cb Condition-bean. This condition-bean should not be set up about fetch-scope. (NotNull)
+     * @return Read count. (NotNull)
+     */
+    public int readCount(ConditionBean cb);
+
+    // ===================================================================================
+    //                                                                   Basic Read Entity
+    //                                                                   =================
+    /**
+     * Read entity by condition-bean.
+     * 
+     * @param cb Condition-bean. (NotNull)
+     * @return Read entity. (Nullalble)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public Entity readEntity(ConditionBean cb);
+
+    /**
+     * Read simple entity by condition-bean with deleted check.
+     * 
+     * @param cb Condition-bean. (NotNull)
+     * @return Read entity. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public Entity readEntityWithDeletedCheck(ConditionBean cb);
+
+    // ===================================================================================
+    //                                                                     Basic Read List
+    //                                                                     ===============
+    /**
+     * Read list as result-bean.
+     * 
+     * @param cb Condition-bean. (NotNull)
+     * @return List-result-bean. If the select result is zero, it returns empty list. (NotNull)
+     */
+    public ListResultBean<Entity> readList(ConditionBean cb);
+
+    /**
+     * Read page as result-bean.
+     * 
+     * @param cb Condition-bean. (NotNull)
+     * @return Read page. (NotNull)
+     */
+    public PagingResultBean<Entity> readPage(final ConditionBean cb);
+
+    // ===================================================================================
+    //                                                                            Sequence
+    //                                                                            ========
+    /**
+     * The implementation.
+     * 
+     * @return The value of sequence. (NotNull)
+     */
+    public java.math.BigDecimal readNextVal();
+
+    // ===================================================================================
+    //                                                                        Static Class
+    //                                                                        ============
+    /**
+     * The interface of select-page callback.
+     * 
+     * @param <T> The generic template for 'selectedList'.
+     */
+    public static interface SelectPageCallback<ENTITY> {
+        public PagingBean getPagingBean();
+
+        public int selectCountIgnoreFetchScope();
+
+        public java.util.List<ENTITY> selectListWithFetchScope();
+    }
+
+    public static class ResultBeanBuilder<ENTITY> extends
+            jp.sf.pal.announcement.db.allcommon.cbean.ResultBeanBuilder<ENTITY> {
+        public ResultBeanBuilder(BehaviorReadable bhv) {
+            super(bhv.getTableDbName());
+        }
+    }
+
+    public static interface SelectPageInvoker<ENTITY> {
+        public PagingResultBean<ENTITY> invokeSelectPage(
+                SelectPageCallback<ENTITY> callback);
+    }
+
+    public static class SelectPageSimpleInvoker<ENTITY> implements
+            SelectPageInvoker<ENTITY> {
+        protected BehaviorReadable _bhv;
+
+        public SelectPageSimpleInvoker(BehaviorReadable bhv) {
+            _bhv = bhv;
+        }
+
+        public PagingResultBean<ENTITY> invokeSelectPage(
+                final SelectPageCallback<ENTITY> callback) {
+            final PagingHandler<ENTITY> handler = new PagingHandler<ENTITY>() {
+                public PagingBean getPagingBean() {
+                    return callback.getPagingBean();
+                }
+
+                public int count() {
+                    return callback.selectCountIgnoreFetchScope();
+                }
+
+                public java.util.List<ENTITY> paging() {
+                    return callback.selectListWithFetchScope();
+                }
+            };
+            return new PagingInvoker<ENTITY>(_bhv.getTableDbName())
+                    .invokePaging(handler);
+        }
+    }
+
+    public static interface SimpleCBSetupper {
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/BehaviorReadable.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/BehaviorWritable.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/BehaviorWritable.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/BehaviorWritable.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,113 @@
+package jp.sf.pal.announcement.db.allcommon.bhv;
+
+import jp.sf.pal.announcement.db.allcommon.DaoWritable;
+import jp.sf.pal.announcement.db.allcommon.Entity;
+
+/**
+ * The interface of behavior-writable.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public interface BehaviorWritable extends BehaviorReadable {
+
+    /**
+     * Get dao-writable.
+     * 
+     * @return Dao-writable. (NotNull)
+     */
+    public DaoWritable getDaoWritable();
+
+    // =====================================================================================
+    //                                                                   Basic Entity Update
+    //                                                                   ===================
+    /**
+     * Create.
+     * 
+     * @param entity Entity. (NotNull)
+     */
+    public void create(jp.sf.pal.announcement.db.allcommon.Entity entity);
+
+    /**
+     * Modify.
+     * 
+     * @param entity Entity. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException When the entity has already been updated.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public void modify(jp.sf.pal.announcement.db.allcommon.Entity entity);
+
+    /**
+     * Modify non-strict.
+     * 
+     * @param entity Entity. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public void modifyNonstrict(Entity entity);
+
+    /**
+     * Create or modify. <br />
+     * {modify: modified only} <br />
+     * This method is faster than createOrModifyAfterSelect().
+     * 
+     * @param entity Entity. This must contain primary-key value at least(Except use identity). (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException When the entity has already been updated.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public void createOrModify(jp.sf.pal.announcement.db.allcommon.Entity entity);
+
+    /**
+     * Create or modify non-strict. <br />
+     * {modify: modified only} <br />
+     * This method is faster than createOrModifyAfterSelect().
+     * 
+     * @param entity Entity. This must contain primary-key value at least(Except use identity). (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public void createOrModifyNonstrict(
+            jp.sf.pal.announcement.db.allcommon.Entity entity);
+
+    /**
+     * Remove.
+     * 
+     * @param entity Entity. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException When the entity has already been updated.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public void remove(jp.sf.pal.announcement.db.allcommon.Entity entity);
+
+    // =====================================================================================
+    //                                                                    Basic Batch Update
+    //                                                                    ==================
+    /**
+     * Lump create the list.
+     * 
+     * @param entityList Entity-list. (NotNull and NotEmpty)
+     * @return The array of created count.
+     */
+    public int[] lumpCreate(java.util.List<Entity> entityList);
+
+    /**
+     * Lump Modify the list.
+     * 
+     * @param entityList Entity-list. (NotNull and NotEmpty)
+     * @return Modified count.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException When the entity has already been updated. And Only when s2dao's version is over 1.0.47 (contains 1.0.47).
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public int[] lumpModify(java.util.List<Entity> entityList);
+
+    /**
+     * Lump remove the list.
+     * 
+     * @param entityList Entity-list. (NotNull and NotEmpty)
+     * @return Removed count.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyUpdatedException When the entity has already been updated. And Only when s2dao's version is over 1.0.47 (contains 1.0.47).
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity has been duplicated.
+     */
+    public int[] lumpRemove(java.util.List<Entity> entityList);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/BehaviorWritable.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileOutputOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileOutputOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileOutputOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,87 @@
+package jp.sf.pal.announcement.db.allcommon.bhv.batch;
+
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.FileMakingOption;
+
+/**
+ * @author DBFlute(AutoGenerator)
+ */
+public class TokenFileOutputOption {
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected FileMakingOption _fileMakingOption = new FileMakingOption();
+
+    // =====================================================================================
+    //                                                                           Easy-to-Use
+    //                                                                           ===========
+    public TokenFileOutputOption delimitateByComma() {
+        _fileMakingOption.delimitateByComma();
+        return this;
+    }
+
+    public TokenFileOutputOption delimitateByTab() {
+        _fileMakingOption.delimitateByTab();
+        return this;
+    }
+
+    public TokenFileOutputOption encodeAsUTF8() {
+        _fileMakingOption.encodeAsUTF8();
+        return this;
+    }
+
+    public TokenFileOutputOption encodeAsWindows31J() {
+        _fileMakingOption.encodeAsWindows31J();
+        return this;
+    }
+
+    public TokenFileOutputOption separateCrLf() {
+        _fileMakingOption.separateCrLf();
+        return this;
+    }
+
+    public TokenFileOutputOption separateLf() {
+        _fileMakingOption.separateLf();
+        return this;
+    }
+
+    public TokenFileOutputOption goodByeDoubleQuotation() {
+        _fileMakingOption.goodByeDoubleQuotation();
+        return this;
+    }
+
+    // =====================================================================================
+    //                                                                              Accessor
+    //                                                                              ========
+    public String getEncoding() {
+        return _fileMakingOption.getEncoding();
+    }
+
+    public void setEncoding(String encoding) {
+        _fileMakingOption.setDelimiter(encoding);
+    }
+
+    public String getDelimiter() {
+        return _fileMakingOption.getDelimiter();
+    }
+
+    public void setDelimiter(String delimiter) {
+        _fileMakingOption.setDelimiter(delimiter);
+    }
+
+    public String getLineSeparator() {
+        return _fileMakingOption.getLineSeparator();
+    }
+
+    public void setLineSeparator(String lineSeparator) {
+        _fileMakingOption.setLineSeparator(lineSeparator);
+    }
+
+    public boolean isGoodByeDoubleQuotation() {
+        return _fileMakingOption.isGoodByeDoubleQuotation();
+    }
+
+    public FileMakingOption getFileMakingOption() {
+        return _fileMakingOption;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileOutputOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileOutputResult.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileOutputResult.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileOutputResult.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,25 @@
+package jp.sf.pal.announcement.db.allcommon.bhv.batch;
+
+import jp.sf.pal.announcement.db.allcommon.Entity;
+
+/**
+ * @author DBFlute(AutoGenerator)
+ */
+public class TokenFileOutputResult {
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected java.util.List<Entity> _selectedList;
+
+    // =====================================================================================
+    //                                                                              Accessor
+    //                                                                              ========
+    public java.util.List<Entity> getSelectedList() {
+        return _selectedList;
+    }
+
+    public void setSelectedList(java.util.List<Entity> selectedList) {
+        _selectedList = selectedList;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileOutputResult.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionFailure.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionFailure.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionFailure.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,87 @@
+package jp.sf.pal.announcement.db.allcommon.bhv.batch;
+
+import jp.sf.pal.announcement.db.allcommon.Entity;
+
+/**
+ * @author DBFlute(AutoGenerator)
+ */
+public class TokenFileReflectionFailure {
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected java.util.List<String> _columnNameList;
+
+    protected java.util.List<String> _valueList;
+
+    protected String rowString;
+
+    /** The row number. */
+    protected int _rowNumber;
+
+    /** The line number. */
+    protected int _lineNumber;
+
+    protected Entity _entity;
+
+    protected Exception _exception;
+
+    // =====================================================================================
+    //                                                                              Accessor
+    //                                                                              ========
+    public java.util.List<String> getColumnNameList() {
+        return _columnNameList;
+    }
+
+    public void setColumnNameList(java.util.List<String> columnNameList) {
+        this._columnNameList = columnNameList;
+    }
+
+    public java.util.List<String> getValueList() {
+        return _valueList;
+    }
+
+    public void setValueList(java.util.List<String> valueList) {
+        this._valueList = valueList;
+    }
+
+    public String getRowString() {
+        return rowString;
+    }
+
+    public void setRowString(String rowString) {
+        this.rowString = rowString;
+    }
+
+    public int getRowNumber() {
+        return _rowNumber;
+    }
+
+    public void setRowNumber(int rowNumber) {
+        _rowNumber = rowNumber;
+    }
+
+    public int getLineNumber() {
+        return _lineNumber;
+    }
+
+    public void setLineNumber(int lineNumber) {
+        _lineNumber = lineNumber;
+    }
+
+    public Entity getEntity() {
+        return _entity;
+    }
+
+    public void setEntity(Entity value) {
+        _entity = value;
+    }
+
+    public Exception getException() {
+        return _exception;
+    }
+
+    public void setException(Exception value) {
+        _exception = value;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionFailure.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,76 @@
+package jp.sf.pal.announcement.db.allcommon.bhv.batch;
+
+import jp.sf.pal.announcement.db.allcommon.helper.token.file.FileTokenizingOption;
+
+/**
+ * @author DBFlute(AutoGenerator)
+ */
+public class TokenFileReflectionOption {
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected boolean _interruptIfError;
+
+    protected FileTokenizingOption _fileTokenizingOption = new FileTokenizingOption();
+
+    // =====================================================================================
+    //                                                                           Easy-to-Use
+    //                                                                           ===========
+    public TokenFileReflectionOption delimitateByComma() {
+        _fileTokenizingOption.delimitateByComma();
+        return this;
+    }
+
+    public TokenFileReflectionOption delimitateByTab() {
+        _fileTokenizingOption.delimitateByTab();
+        return this;
+    }
+
+    public TokenFileReflectionOption encodeAsUTF8() {
+        _fileTokenizingOption.encodeAsUTF8();
+        return this;
+    }
+
+    public TokenFileReflectionOption encodeAsWindows31J() {
+        _fileTokenizingOption.encodeAsWindows31J();
+        return this;
+    }
+
+    public TokenFileReflectionOption handleEmptyAsNull() {
+        _fileTokenizingOption.handleEmptyAsNull();
+        return this;
+    }
+
+    public TokenFileReflectionOption interruptIfError() {
+        _interruptIfError = true;
+        return this;
+    }
+
+    // =====================================================================================
+    //                                                                              Accessor
+    //                                                                              ========
+    public String getDelimiter() {
+        return _fileTokenizingOption.getDelimiter();
+    }
+
+    public void setDelimiter(String delimiter) {
+        _fileTokenizingOption.setDelimiter(delimiter);
+    }
+
+    public String getEncoding() {
+        return _fileTokenizingOption.getEncoding();
+    }
+
+    public void setEncoding(String encoding) {
+        _fileTokenizingOption.setDelimiter(encoding);
+    }
+
+    public boolean isHandleEmptyAsNull() {
+        return _fileTokenizingOption.isHandleEmptyAsNull();
+    }
+
+    public boolean isInterruptIfError() {
+        return _interruptIfError;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionResult.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionResult.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionResult.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,51 @@
+package jp.sf.pal.announcement.db.allcommon.bhv.batch;
+
+/**
+ * @author DBFlute(AutoGenerator)
+ */
+public class TokenFileReflectionResult {
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected java.util.List<String> _columnNameList;
+
+    protected int _successCount;
+
+    protected java.util.List<TokenFileReflectionFailure> _failureList;
+
+    // =====================================================================================
+    //                                                                           Easy-to-Use
+    //                                                                           ===========
+    public void incrementSuccessCount() {
+        ++_successCount;
+    }
+
+    // =====================================================================================
+    //                                                                              Accessor
+    //                                                                              ========
+    public java.util.List<String> getColumnNameList() {
+        return _columnNameList;
+    }
+
+    public void setColumnNameList(java.util.List<String> columnNameList) {
+        this._columnNameList = columnNameList;
+    }
+
+    public int getSuccessCount() {
+        return _successCount;
+    }
+
+    public void setSuccessCount(int successCount) {
+        _successCount = successCount;
+    }
+
+    public java.util.List<TokenFileReflectionFailure> getFailureList() {
+        return _failureList;
+    }
+
+    public void setFailureList(
+            java.util.List<TokenFileReflectionFailure> failureList) {
+        this._failureList = failureList;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/batch/TokenFileReflectionResult.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/load/LoadRefererOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/load/LoadRefererOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/load/LoadRefererOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,74 @@
+package jp.sf.pal.announcement.db.allcommon.bhv.load;
+
+import jp.sf.pal.announcement.db.allcommon.Entity;
+import jp.sf.pal.announcement.db.allcommon.bhv.setup.ConditionBeanSetupper;
+import jp.sf.pal.announcement.db.allcommon.bhv.setup.EntityListSetupper;
+import jp.sf.pal.announcement.db.allcommon.cbean.ConditionBean;
+
+/**
+ * The class of load referrer option.
+ * 
+ * @param <REFERRER_CONDITION_BEAN> The type of referrer condition-bean.
+ * @param <REFERRER_ENTITY> The type of referrer entity.
+ * @author DBFlute(AutoGenerator)
+ */
+public class LoadRefererOption<REFERRER_CONDITION_BEAN extends ConditionBean, REFERRER_ENTITY extends Entity>
+        extends LoadReferrerOption<REFERRER_CONDITION_BEAN, REFERRER_ENTITY> {
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    public LoadRefererOption() {
+    }
+
+    public LoadRefererOption(
+            ConditionBeanSetupper<REFERRER_CONDITION_BEAN> conditionBeanSetupper) {
+        super(conditionBeanSetupper);
+    }
+
+    public LoadRefererOption(
+            ConditionBeanSetupper<REFERRER_CONDITION_BEAN> conditionBeanSetupper,
+            EntityListSetupper<REFERRER_ENTITY> entityListSetupper) {
+        super(conditionBeanSetupper, entityListSetupper);
+    }
+
+    public LoadRefererOption(
+            LoadReferrerOption<REFERRER_CONDITION_BEAN, REFERRER_ENTITY> option) {
+        super(option);
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    /**
+     * @return The condition-bean of referrer.
+     * @deprecated Sorry! This methid have typo! Please use getRefererConditionBean().
+     */
+    public REFERRER_CONDITION_BEAN getReffererConditionBean() {
+        return super.getReferrerConditionBean();
+    }
+
+    /**
+     * @param referrerConditionBean The condition-bean of referrer.
+     * @deprecated Sorry! This methid have typo! Please use setReferrerConditionBean().
+     */
+    public void setReffererConditionBean(
+            REFERRER_CONDITION_BEAN referrerConditionBean) {
+        super.setReferrerConditionBean(referrerConditionBean);
+    }
+
+    /**
+     * @return The condition-bean of referrer.
+     */
+    public REFERRER_CONDITION_BEAN getRefererConditionBean() {
+        return super.getReferrerConditionBean();
+    }
+
+    /**
+     * @param referrerConditionBean The condition-bean of referrer.
+     */
+    public void setRefererConditionBean(
+            REFERRER_CONDITION_BEAN referrerConditionBean) {
+        super.setReferrerConditionBean(referrerConditionBean);
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/load/LoadRefererOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/load/LoadReferrerOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/load/LoadReferrerOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/load/LoadReferrerOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,139 @@
+package jp.sf.pal.announcement.db.allcommon.bhv.load;
+
+import jp.sf.pal.announcement.db.allcommon.Entity;
+import jp.sf.pal.announcement.db.allcommon.bhv.setup.ConditionBeanSetupper;
+import jp.sf.pal.announcement.db.allcommon.bhv.setup.EntityListSetupper;
+import jp.sf.pal.announcement.db.allcommon.cbean.ConditionBean;
+
+/**
+ * The class of load referrer option.
+ * 
+ * @param <REFERRER_CONDITION_BEAN> The type of referrer condition-bean.
+ * @param <REFERRER_ENTITY> The type of referrer entity.
+ * @author DBFlute(AutoGenerator)
+ */
+public class LoadReferrerOption<REFERRER_CONDITION_BEAN extends ConditionBean, REFERRER_ENTITY extends Entity> {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected ConditionBeanSetupper<REFERRER_CONDITION_BEAN> _conditionBeanSetupper;
+
+    protected EntityListSetupper<REFERRER_ENTITY> _entityListSetupper;
+
+    protected REFERRER_CONDITION_BEAN _referrerConditionBean;
+
+    protected boolean _toLastKeyCondtion;
+
+    protected boolean _stopOrderByKey;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    public LoadReferrerOption() {
+    }
+
+    public LoadReferrerOption(
+            ConditionBeanSetupper<REFERRER_CONDITION_BEAN> conditionBeanSetupper) {
+        this._conditionBeanSetupper = conditionBeanSetupper;
+    }
+
+    public LoadReferrerOption(
+            ConditionBeanSetupper<REFERRER_CONDITION_BEAN> conditionBeanSetupper,
+            EntityListSetupper<REFERRER_ENTITY> entityListSetupper) {
+        this._conditionBeanSetupper = conditionBeanSetupper;
+        this._entityListSetupper = entityListSetupper;
+    }
+
+    public LoadReferrerOption(
+            LoadReferrerOption<REFERRER_CONDITION_BEAN, REFERRER_ENTITY> option) {
+        this._conditionBeanSetupper = option._conditionBeanSetupper;
+        this._entityListSetupper = option._entityListSetupper;
+        this._referrerConditionBean = option._referrerConditionBean;
+        this._toLastKeyCondtion = option._toLastKeyCondtion;
+        this._stopOrderByKey = option._stopOrderByKey;
+    }
+
+    // ===================================================================================
+    //                                                                         Easy-to-Use
+    //                                                                         ===========
+    /**
+     * Specify that the key condition is added as last condition. <br />
+     * This method is valid only after you use reffererConditionBean and add your original condition to it. <br />
+     * 
+     * @return this. (NotNull)
+     */
+    public LoadReferrerOption<REFERRER_CONDITION_BEAN, REFERRER_ENTITY> toLastKeyCondtion() {
+        _toLastKeyCondtion = true;
+        return this;
+    }
+
+    /**
+     * Specify that it stops adding order-by of the key. <br />
+     * This method is valid only after you use reffererConditionBean and add your original order-by to it. <br />
+     * 
+     * @return this. (NotNull)
+     */
+    public LoadReferrerOption<REFERRER_CONDITION_BEAN, REFERRER_ENTITY> stopOrderByKey() {
+        _stopOrderByKey = true;
+        return this;
+    }
+
+    public void delegateKeyConditionExchangingFirstWhereClauseForLastOne(
+            REFERRER_CONDITION_BEAN cb) {// Internal
+        if (!_toLastKeyCondtion) {
+            cb.getSqlClause().exchangeFirstWhereClauseForLastOne();
+        }
+    }
+
+    public void delegateConditionBeanSettingUp(REFERRER_CONDITION_BEAN cb) {// Internal
+        if (_conditionBeanSetupper != null) {
+            _conditionBeanSetupper.setup(cb);
+        }
+    }
+
+    public void delegateEntitySettingUp(
+            java.util.List<REFERRER_ENTITY> entityList) {// Internal
+        if (_entityListSetupper != null) {
+            _entityListSetupper.setup(entityList);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    public ConditionBeanSetupper<REFERRER_CONDITION_BEAN> getConditionBeanSetupper() {
+        return _conditionBeanSetupper;
+    }
+
+    public void setConditionBeanSetupper(
+            ConditionBeanSetupper<REFERRER_CONDITION_BEAN> conditionBeanSetupper) {
+        this._conditionBeanSetupper = conditionBeanSetupper;
+    }
+
+    public EntityListSetupper<REFERRER_ENTITY> getEntityListSetupper() {
+        return _entityListSetupper;
+    }
+
+    public void setEntityListSetupper(
+            EntityListSetupper<REFERRER_ENTITY> entityListSetupper) {
+        this._entityListSetupper = entityListSetupper;
+    }
+
+    public REFERRER_CONDITION_BEAN getReferrerConditionBean() {
+        return _referrerConditionBean;
+    }
+
+    public void setReferrerConditionBean(
+            REFERRER_CONDITION_BEAN referrerConditionBean) {
+        this._referrerConditionBean = referrerConditionBean;
+    }
+
+    public boolean isToLastKeyCondtion() {
+        return _toLastKeyCondtion;
+    }
+
+    public boolean isStopOrderByKey() {
+        return _stopOrderByKey;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/load/LoadReferrerOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ConditionBeanSetupper.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ConditionBeanSetupper.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ConditionBeanSetupper.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,19 @@
+package jp.sf.pal.announcement.db.allcommon.bhv.setup;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.ConditionBean;
+
+/**
+ * The interface of condition-bean setupper.
+ * 
+ * @param <CONDITION_BEAN> The type of condition-bean.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface ConditionBeanSetupper<CONDITION_BEAN extends ConditionBean> {
+
+    /**
+     * Set up condition.
+     * 
+     * @param cb Condition-bean. (NotNull)
+     */
+    public void setup(CONDITION_BEAN cb);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ConditionBeanSetupper.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/EntityListSetupper.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/EntityListSetupper.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/EntityListSetupper.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,19 @@
+package jp.sf.pal.announcement.db.allcommon.bhv.setup;
+
+import jp.sf.pal.announcement.db.allcommon.Entity;
+
+/**
+ * The interface of entity list setupper.
+ * 
+ * @param <ENTITY> The type of entity.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface EntityListSetupper<ENTITY extends Entity> {
+
+    /**
+     * Set up entity list.
+     * 
+     * @param entityList Entity list. (NotNull)
+     */
+    public void setup(java.util.List<ENTITY> entityList);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/EntityListSetupper.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ValueLabelBox.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ValueLabelBox.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ValueLabelBox.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,25 @@
+package jp.sf.pal.announcement.db.allcommon.bhv.setup;
+
+/**
+ * The class of Value-Label Box.
+ * @author DBFlute(AutoGenerator)
+ */
+public class ValueLabelBox {
+
+    protected Object _value;
+
+    protected String _label;
+
+    public void setValueLabel(Object value, String label) {
+        this._value = value;
+        this._label = label;
+    }
+
+    public Object getValue() {
+        return _value;
+    }
+
+    public String getLabel() {
+        return _label;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ValueLabelBox.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ValueLabelSetupper.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ValueLabelSetupper.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ValueLabelSetupper.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,18 @@
+package jp.sf.pal.announcement.db.allcommon.bhv.setup;
+
+import jp.sf.pal.announcement.db.allcommon.Entity;
+
+/**
+ * The interface of Value-Label Setupper.
+ * @param <ENTITY> The type of entity.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface ValueLabelSetupper<ENTITY extends Entity> {
+
+    /**
+     * Set up value-label.
+     * @param box Value-label box. (NotNull)
+     * @param entity Entity. (NotNull)
+     */
+    public void setup(ValueLabelBox box, ENTITY entity);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/bhv/setup/ValueLabelSetupper.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/AbstractConditionBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/AbstractConditionBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/AbstractConditionBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,626 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.OrderByClause;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClause;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.WhereClauseSimpleFilter;
+import jp.sf.pal.announcement.db.allcommon.helper.MapListString;
+import jp.sf.pal.announcement.db.allcommon.helper.MapListStringImpl;
+import jp.sf.pal.announcement.db.allcommon.jdbc.StatementConfig;
+import jp.sf.pal.announcement.db.allcommon.util.SimpleSystemUtil;
+
+/**
+ * The condition-bean as abstract.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public abstract class AbstractConditionBean implements ConditionBean {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** SQL clause instance. */
+    protected final SqlClause _sqlClause;
+    {
+        _sqlClause = ConditionBeanContext.createSqlClause(this);
+    }
+
+    /** Safety max result size. */
+    protected int _safetyMaxResultSize;
+
+    /** The config of statement. (Nullable) */
+    protected StatementConfig _statementConfig;
+
+    // ===================================================================================
+    //                                                                           SqlClause
+    //                                                                           =========
+    /**
+     * The implementation.
+     * 
+     * @return Sql clause. (NotNull)
+     */
+    public SqlClause getSqlClause() {
+        return _sqlClause;
+    }
+
+    // ===================================================================================
+    //                                                                 Where Clause Filter
+    //                                                                 ===================
+    public void addWhereClauseSimpleFilter(
+            WhereClauseSimpleFilter whereClauseSimpleFilter) {
+        this._sqlClause.addWhereClauseSimpleFilter(whereClauseSimpleFilter);
+    }
+
+    // ===================================================================================
+    //                                                                      ConditionQuery
+    //                                                                      ==============
+    /**
+     * Get condition query as interface. At the future, change public to protected.
+     * 
+     * @return Instance of query as interface. (NotNull)
+     */
+    abstract public ConditionQuery getConditionQueryAsInterface();
+
+    /**
+     * The implementation.
+     * 
+     * @return The conditionQuery of the local table as interface. (NotNull)
+     */
+    public ConditionQuery localCQ() {
+        return getConditionQueryAsInterface();
+    }
+
+    // ===================================================================================
+    //                                                                   Accept PrimaryKey
+    //                                                                   =================
+    /**
+     * The implementation.
+     * 
+     * @param primaryKeyMapString Primary-key map. (NotNull and NotEmpty)
+     */
+    public void acceptPrimaryKeyMapString(String primaryKeyMapString) {
+        if (primaryKeyMapString == null) {
+            String msg = "The argument[primaryKeyMapString] must not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+        final String prefix = MAP_STRING_MAP_MARK + MAP_STRING_START_BRACE;
+        final String suffix = MAP_STRING_END_BRACE;
+        if (!primaryKeyMapString.trim().startsWith(prefix)) {
+            primaryKeyMapString = prefix + primaryKeyMapString;
+        }
+        if (!primaryKeyMapString.trim().endsWith(suffix)) {
+            primaryKeyMapString = primaryKeyMapString + suffix;
+        }
+        MapListString mapListString = new MapListStringImpl();
+        mapListString.setMapMark(MAP_STRING_MAP_MARK);
+        mapListString.setListMark(MAP_STRING_LIST_MARK);
+        mapListString.setDelimiter(MAP_STRING_DELIMITER);
+        mapListString.setStartBrace(MAP_STRING_START_BRACE);
+        mapListString.setEndBrace(MAP_STRING_END_BRACE);
+        mapListString.setEqual(MAP_STRING_EQUAL);
+        acceptPrimaryKeyMap(mapListString.generateMap(primaryKeyMapString));
+    }
+
+    protected void checkTypeString(Object value, String propertyName,
+            String typeName) {
+        if (value == null) {
+            throw new IllegalArgumentException("The value should not be null: "
+                    + propertyName);
+        }
+        if (!(value instanceof String)) {
+            String msg = "The value of " + propertyName + " should be "
+                    + typeName + " or String: ";
+            msg = msg + "valueType=" + value.getClass() + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    protected long parseDateStringAsMillis(Object value, String propertyName,
+            String typeName) {
+        checkTypeString(value, propertyName, typeName);
+        try {
+            final String valueString = (String) value;
+            if (valueString.indexOf("-") >= 0
+                    && valueString.indexOf("-") != valueString.lastIndexOf("-")) {
+                return java.sql.Timestamp.valueOf(valueString).getTime();
+            } else {
+                return getParseDateFormat().parse((String) value).getTime();
+            }
+        } catch (java.text.ParseException e) {
+            String msg = "The value of " + propertyName + " should be "
+                    + typeName + ". but: " + value;
+            throw new RuntimeException(msg + " threw the exception: value=["
+                    + value + "]", e);
+        } catch (RuntimeException e) {
+            String msg = "The value of " + propertyName + " should be "
+                    + typeName + ". but: " + value;
+            throw new RuntimeException(msg + " threw the exception: value=["
+                    + value + "]", e);
+        }
+    }
+
+    private java.text.DateFormat getParseDateFormat() {
+        return java.text.DateFormat.getDateTimeInstance();
+    }
+
+    // ===================================================================================
+    //                                                        Implementation of PagingBean
+    //                                                        ============================
+    // -----------------------------------------------------
+    //                                  Paging Determination
+    //                                  --------------------
+    // * * * * * * * *
+    // For SQL Comment
+    // * * * * * * * *
+    /**
+     * The implementation.
+     * @return Determination.
+     */
+    public boolean isPaging() {
+        String msg = "This method is unsupported on ConditionBean!";
+        throw new UnsupportedOperationException(msg);
+    }
+
+    /**
+     * The implementation.
+     * @param paging Determination.
+     */
+    public void xsetPaging(boolean paging) {
+        String msg = "This method is unsupported on ConditionBean!";
+        throw new UnsupportedOperationException(msg);
+    }
+
+    // -----------------------------------------------------
+    //                                         Fetch Setting
+    //                                         -------------
+    /**
+     * The implementation.
+     * @param fetchSize Fetch-size. (NotMinus & NotZero)
+     * @return this. (NotNUll)
+     */
+    public PagingBean fetchFirst(int fetchSize) {
+        getSqlClause().fetchFirst(fetchSize);
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * @param fetchStartIndex Fetch-start-index. 0 origin. (NotMinus)
+     * @param fetchSize Fetch-size. (NotMinus & NotZero)
+     * @return this. (NotNUll)
+     */
+    public PagingBean fetchScope(int fetchStartIndex, int fetchSize) {
+        getSqlClause().fetchScope(fetchStartIndex, fetchSize);
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * @param fetchPageNumber Fetch-page-number. 1 origin. (NotMinus & NotZero: If minus or zero, set one.)
+     * @return this. (NotNull)
+     */
+    public PagingBean fetchPage(int fetchPageNumber) {
+        getSqlClause().fetchPage(fetchPageNumber);
+        return this;
+    }
+
+    // -----------------------------------------------------
+    //                                        Fetch Property
+    //                                        --------------
+    /**
+     * The implementation.
+     * @return Fetch-start-index.
+     */
+    public int getFetchStartIndex() {
+        return getSqlClause().getFetchStartIndex();
+    }
+
+    /**
+     * The implementation.
+     * @return Fetch-size.
+     */
+    public int getFetchSize() {
+        return getSqlClause().getFetchSize();
+    }
+
+    /**
+     * The implementation.
+     * @return Fetch-page-number.
+     */
+    public int getFetchPageNumber() {
+        return getSqlClause().getFetchPageNumber();
+    }
+
+    /**
+     * The implementation.
+     * @return Page start index. 0 origin. (NotMinus)
+     */
+    public int getPageStartIndex() {
+        return getSqlClause().getPageStartIndex();
+    }
+
+    /**
+     * The implementation.
+     * @return Page end index. 0 origin. (NotMinus)
+     */
+    public int getPageEndIndex() {
+        return getSqlClause().getPageEndIndex();
+    }
+
+    /**
+     * Is fetch scope effective?
+     * @return Determiantion.
+     */
+    public boolean isFetchScopeEffective() {
+        return getSqlClause().isFetchScopeEffective();
+    }
+
+    // -----------------------------------------------------
+    //                                         Hint Property
+    //                                         -------------
+    /**
+     * Get select-hint. {select [select-hint] * from table...}
+     * @return select-hint. (NotNull)
+     */
+    public String getSelectHint() {
+        return getSqlClause().getSelectHint();
+    }
+
+    /**
+     * Get from-base-table-hint. {select * from table [from-base-table-hint] where ...}
+     * @return from-base-table-hint. (NotNull)
+     */
+    public String getFromBaseTableHint() {
+        return getSqlClause().getFromBaseTableHint();
+    }
+
+    /**
+     * Get from-hint. {select * from table left outer join ... on ... [from-hint] where ...}
+     * @return from-hint. (NotNull)
+     */
+    public String getFromHint() {
+        return getSqlClause().getFromHint();
+    }
+
+    /**
+     * Get where clause.
+     * @return Where clause. (NotNull)
+     */
+    public String getWhereClause() {
+        return getSqlClause().getWhereClause();
+    }
+
+    /**
+     * Get sql-suffix. {select * from table where ... order by ... [sql-suffix]}
+     * @return Sql-suffix.  (NotNull)
+     */
+    public String getSqlSuffix() {
+        return getSqlClause().getSqlSuffix();
+    }
+
+    // ===================================================================================
+    //                                                Implementation of FetchNarrowingBean
+    //                                                ====================================
+    /**
+     * The implementation.
+     * @return Fetch start index.
+     */
+    public int getFetchNarrowingSkipStartIndex() {
+        return getSqlClause().getFetchNarrowingSkipStartIndex();
+    }
+
+    /**
+     * The implementation.
+     * @return Fetch size.
+     */
+    public int getFetchNarrowingLoopCount() {
+        return getSqlClause().getFetchNarrowingLoopCount();
+    }
+
+    /**
+     * The implementation.
+     * @return Determination.
+     */
+    public boolean isFetchNarrowingSkipStartIndexEffective() {
+        return !getSqlClause().isFetchStartIndexSupported();
+    }
+
+    /**
+     * The implementation.
+     * @return Determination.
+     */
+    public boolean isFetchNarrowingLoopCountEffective() {
+        return !getSqlClause().isFetchSizeSupported();
+    }
+
+    /**
+     * The implementation.
+     * @return Determiantion.
+     */
+    public boolean isFetchNarrowingEffective() {
+        return getSqlClause().isFetchNarrowingEffective();
+    }
+
+    /**
+     * Ignore fetch narrowing. Only checking safety result size is valid. {INTERNAL METHOD}
+     */
+    public void ignoreFetchNarrowing() {
+        String msg = "This method is unsupported on ConditionBean!";
+        throw new UnsupportedOperationException(msg);
+    }
+
+    /**
+     * Restore ignored fetch narrowing. {INTERNAL METHOD}
+     */
+    public void restoreIgnoredFetchNarrowing() {
+        // Do nothing!
+    }
+
+    /**
+     * Get safety max result size.
+     * @return Safety max result size.
+     */
+    public int getSafetyMaxResultSize() {
+        return _safetyMaxResultSize;
+    }
+
+    /**
+     * Check safety result.
+     * @param safetyMaxResultSize Safety max result size. (If zero or minus, ignore checking)
+     */
+    public void checkSafetyResult(int safetyMaxResultSize) {
+        this._safetyMaxResultSize = safetyMaxResultSize;
+    }
+
+    // ===================================================================================
+    //                                                       Implementation of OrderByBean
+    //                                                       =============================
+    /**
+     * The implementation.
+     * @return Sql component of order-by clause. (NotNull)
+     */
+    public OrderByClause getSqlComponentOfOrderByClause() {
+        return getSqlClause().getSqlComponentOfOrderByClause();
+    }
+
+    /**
+     * The implementation.
+     * @return Order-by clause. (NotNull)
+     */
+    public String getOrderByClause() {
+        return _sqlClause.getOrderByClause();
+    }
+
+    /**
+     * The implementation.
+     * @return this. (NotNull)
+     */
+    public OrderByBean clearOrderBy() {
+        getSqlClause().clearOrderBy();
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * @return this. (NotNull)
+     */
+    public OrderByBean ignoreOrderBy() {
+        getSqlClause().ignoreOrderBy();
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * @return this. (NotNull)
+     */
+    public OrderByBean makeOrderByEffective() {
+        getSqlClause().makeOrderByEffective();
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                        Limit Select
+    //                                                                        ============
+    /** Is limit-select PK only? */
+    protected boolean _isLimitSelectPKOnly;
+
+    /**
+     * Is limit-select PK only?
+     * @return Determination.
+     */
+    public boolean isLimitSelect_PKOnly() {
+        return _isLimitSelectPKOnly;
+    }
+
+    /**
+     * Limit select PK only.
+     * @return this. (NotNull)
+     */
+    public ConditionBean limitSelect_PKOnly() {
+        _isLimitSelectPKOnly = true;
+        return this;
+    }
+
+    /**
+     * Limit select off.
+     * @return this. (NotNull)
+     */
+    public ConditionBean limitSelect_Off() {
+        _isLimitSelectPKOnly = false;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                        Lock Setting
+    //                                                                        ============
+    /**
+     * The implementation.
+     * @return this. (NotNull)
+     */
+    public ConditionBean lockForUpdate() {
+        getSqlClause().lockForUpdate();
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                        Select Count
+    //                                                                        ============
+    /**
+     * Set up various things for select-count-ignore-fetch-scope. {Internal}
+     * This method is for INTERNAL. Don't invoke this!
+     * @return this. (NotNull)
+     */
+    public ConditionBean xsetupSelectCountIgnoreFetchScope() {
+        _isSelectCountIgnoreFetchScope = true;
+
+        // If the query uses union query, it needs included-select-column.
+        if (!hasUnionQueryOrUnionAllQuery()) {
+            getSqlClause().ignoreIncludedSelectColumn();
+        }
+
+        getSqlClause().ignoreOrderBy();
+        getSqlClause().ignoreFetchScope();
+        return this;
+    }
+
+    /**
+     * Do after-care for select-count-ignore-fetch-scope. {Internal}
+     * This method is for INTERNAL. Don't invoke this!
+     * @return this. (NotNull)
+     */
+    public ConditionBean xafterCareSelectCountIgnoreFetchScope() {
+        _isSelectCountIgnoreFetchScope = false;
+
+        // If the query uses union query, it needs included-select-column.
+        if (!hasUnionQueryOrUnionAllQuery()) {
+            getSqlClause().makeIncludedSelectColumnEffective();
+        }
+
+        getSqlClause().makeOrderByEffective();
+        getSqlClause().makeFetchScopeEffective();
+        return this;
+    }
+
+    /** Is set up various things for select-count-ignore-fetch-scope? */
+    protected boolean _isSelectCountIgnoreFetchScope;
+
+    /**
+     * Is set up various things for select-count-ignore-fetch-scope?
+     * This method is for INTERNAL. Don't invoke this!
+     * @return Determination.
+     */
+    public boolean isSelectCountIgnoreFetchScope() {
+        return _isSelectCountIgnoreFetchScope;
+    }
+
+    // =====================================================================================
+    //                                                                      Statement Config
+    //                                                                      ================
+    /**
+     * @param statementConfig The config of statement. (Nullable)
+     */
+    public void configure(StatementConfig statementConfig) {
+        _statementConfig = statementConfig;
+    }
+
+    /**
+     * @return The config of statement. (Nullable)
+     */
+    public StatementConfig getStatementConfig() {
+        return _statementConfig;
+    }
+
+    // ===================================================================================
+    //                                                                          Format SQL
+    //                                                                          ==========
+    public void formatSql() {
+        getSqlClause().makeFormatClauseEffective();
+    }
+
+    public boolean isFormatSql() {
+        return getSqlClause().isFormatClauseEffective();
+    }
+
+    // ===================================================================================
+    //                                                                       Assert Helper
+    //                                                                       =============
+    protected void assertSetupSelectBeforeUnion(String methodName) {
+        if (hasUnionQueryOrUnionAllQuery()) {
+            throwSetupSelectAfterUnionException(
+                    this.getClass().getSimpleName(), methodName);
+        }
+    }
+
+    protected void throwSetupSelectAfterUnionException(String className,
+            String methodName) {
+        String msg = "Look! Read the message below." + getLineSeparator();
+        msg = msg
+                + "/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *"
+                + getLineSeparator();
+        msg = msg + "You should NOT call " + methodName
+                + " after calling union()!" + getLineSeparator();
+        msg = msg + getLineSeparator();
+        msg = msg + "[Advice]" + getLineSeparator();
+        msg = msg + methodName + " should be called before calling union()."
+                + getLineSeparator();
+        msg = msg + "  For example:" + getLineSeparator();
+        msg = msg + "    /- - - - - - - - - - - - - - - - - - - - "
+                + getLineSeparator();
+        msg = msg + "    " + className + " cb = new " + className + "();"
+                + getLineSeparator();
+        msg = msg + "    cb." + methodName + "; // You shuold call here!"
+                + getLineSeparator();
+        msg = msg + "    cb.query().setXxx...;" + getLineSeparator();
+        msg = msg + "    {" + getLineSeparator();
+        msg = msg + "        " + className + " unionCB = new " + className
+                + "();" + getLineSeparator();
+        msg = msg + "        unionCB.query().setXxx;" + getLineSeparator();
+        msg = msg + "        cb.union(unionCB);" + getLineSeparator();
+        msg = msg + "    }" + getLineSeparator();
+        msg = msg
+                + "    // You should not call setupSelect after calling union()!"
+                + getLineSeparator();
+        msg = msg + "    // cb." + methodName + ";" + getLineSeparator();
+        msg = msg + "    - - - - - - - - - -/" + getLineSeparator();
+        msg = msg + getLineSeparator();
+        msg = msg + "[SetupSelect Method]" + getLineSeparator() + methodName
+                + getLineSeparator();
+        msg = msg + getLineSeparator();
+        msg = msg + "[ConditionBean SQL]" + getLineSeparator() + toDisplaySql()
+                + getLineSeparator();
+        msg = msg + "* * * * * * * * * */" + getLineSeparator();
+        throw new IllegalStateException(msg);
+    }
+
+    // ===================================================================================
+    //                                                                      General Helper
+    //                                                                      ==============
+    protected String getLineSeparator() {
+        return SimpleSystemUtil.getLineSeparator();
+    }
+
+    // ===================================================================================
+    //                                                                         Display SQL
+    //                                                                         ===========
+    /**
+     * Convert this conditionBean to SQL for display.
+     * @return SQL for display. (NotNull and NotEmpty)
+     */
+    public String toDisplaySql() {
+        return ConditionBeanContext.convertConditionBean2DisplaySql(this);
+    }
+
+    // ===================================================================================
+    //                                                                      Basic Override
+    //                                                                      ==============
+    /**
+     * The override.
+     * @return SQL for display. (NotNull)
+     */
+    public String toString() {
+        try {
+            return toDisplaySql();
+        } catch (RuntimeException e) {
+            return getSqlClause().getClause();
+        }
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/AbstractConditionBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/AbstractConditionQuery.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/AbstractConditionQuery.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/AbstractConditionQuery.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,1152 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.ckey.ConditionKey;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.FromToOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.InScopeOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.LikeSearchOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClause;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMeta;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMetaInstanceHandler;
+import jp.sf.pal.announcement.db.allcommon.exception.RequiredOptionNotFoundException;
+import jp.sf.pal.announcement.db.allcommon.util.SimpleStringUtil;
+import jp.sf.pal.announcement.db.allcommon.util.SimpleSystemUtil;
+
+/**
+ * The abstract class of condition-query.
+ * @author DBFlute(AutoGenerator)
+ */
+public abstract class AbstractConditionQuery implements ConditionQuery {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** Condition value for DUMMY. */
+    protected static final ConditionValue DUMMY_CONDITION_VALUE = new ConditionValue();
+
+    /** Object for DUMMY. */
+    protected static final Object DUMMY_OBJECT = new Object();
+
+    /** The property of condition-query. */
+    protected static final String CQ_PROPERTY = "conditionQuery";
+
+    /** SQL clause. */
+    protected final SqlClause _sqlClause;
+
+    /** My alias name. */
+    protected final String _aliasName;
+
+    /** The level of nest. */
+    protected final int _nestLevel;
+
+    /** The level of subQuery. */
+    protected int _subQueryLevel;
+
+    // -----------------------------------------------------
+    //                                          Foreign Info
+    //                                          ------------
+    /** The property name of foreign. */
+    protected String _foreignPropertyName;
+
+    /** The path of relation. */
+    protected String _relationPath;
+
+    /** The query of child. */
+    protected final ConditionQuery _childQuery;
+
+    // -----------------------------------------------------
+    //                                                Inline
+    //                                                ------
+    /** Is it the inline for on-clause. (Property for Inline Only) */
+    protected boolean _onClauseInline;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * Constructor.
+     * @param childQuery Child query. (Nullable: If null, this is base instance.)
+     * @param sqlClause SQL clause instance. (NotNull)
+     * @param aliasName My alias name. (NotNull)
+     * @param nestLevel Nest level.
+     */
+    public AbstractConditionQuery(ConditionQuery childQuery,
+            SqlClause sqlClause, String aliasName, int nestLevel) {
+        _childQuery = childQuery;
+        _sqlClause = sqlClause;
+        _aliasName = aliasName;
+        _nestLevel = nestLevel;
+    }
+
+    // ===================================================================================
+    //                                                                  Important Accessor
+    //                                                                  ==================
+    /**
+     * Get child query.
+     * @return Child query. (Nullable)
+     */
+    public ConditionQuery getChildQuery() {
+        return _childQuery;
+    }
+
+    /**
+     * Get sql clause.
+     * @return Sql clause. (NotNull)
+     */
+    public SqlClause getSqlClause() {
+        return _sqlClause;
+    }
+
+    /**
+     * Get alias name.
+     * @return Alias name. (NotNull)
+     */
+    public String getAliasName() {
+        return _aliasName;
+    }
+
+    /**
+     * Get nest level.
+     * @return Nest level.
+     */
+    public int getNestLevel() {
+        return _nestLevel;
+    }
+
+    /**
+     * Get next nest level.
+     * @return Next nest level.
+     */
+    public int getNextNestLevel() {
+        return _nestLevel + 1;
+    }
+
+    /**
+     * Is base query?
+     * @param query Condition query. (NotNull)
+     * @return Determination.
+     */
+    public boolean isBaseQuery(ConditionQuery query) {
+        return (query.getChildQuery() == null);
+    }
+
+    /**
+     * Get the level of subQuery.
+     * @return The level of subQuery.
+     */
+    public int getSubQueryLevel() {
+        return _subQueryLevel;
+    }
+
+    // -----------------------------------------------------
+    //                                             Real Name
+    //                                             ---------
+    /**
+     * Get real alias name(that has nest level mark).
+     * @return Real alias name.
+     */
+    public String getRealAliasName() {
+        return getAliasName();
+    }
+
+    /**
+     * Get real column name(with real alias name).
+     * @param columnName Column name without alias name. This should not contain comma. (NotNull)
+     * @return Real column name.
+     */
+    public String getRealColumnName(String columnName) {
+        assertColumnName(columnName);
+        return buildRealColumnName(getRealAliasName(), columnName);
+    }
+
+    /**
+     * Build real column name.
+     * @param aliasName Alias name. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @return Real column name. (NotNull)
+     */
+    protected String buildRealColumnName(String aliasName, String columnName) {
+        return aliasName + "." + columnName;
+    }
+
+    // -----------------------------------------------------
+    //                                          Foreign Info
+    //                                          ------------
+    public String getForeignPropertyName() {
+        return _foreignPropertyName;
+    }
+
+    public void xsetForeignPropertyName(String foreignPropertyName) {
+        this._foreignPropertyName = foreignPropertyName;
+    }
+
+    public String getRelationPath() {
+        return _relationPath;
+    }
+
+    public void xsetRelationPath(String relationPath) {
+        this._relationPath = relationPath;
+    }
+
+    // -----------------------------------------------------
+    //                                                Inline
+    //                                                ------
+    public void xsetOnClauseInline(boolean onClauseInline) {
+        _onClauseInline = onClauseInline;
+    }
+
+    // ===================================================================================
+    //                                                                            Location
+    //                                                                            ========
+    /**
+     * Get location.
+     * @param columnPropertyName Column property name.
+     * @param key Condition key.
+     * @return Next nest level.
+     */
+    protected String getLocation(String columnPropertyName, ConditionKey key) {
+        return getLocationBase(columnPropertyName) + "."
+                + key.getConditionKey();
+    }
+
+    protected String getLocationBase() {
+        final StringBuffer sb = new StringBuffer();
+        ConditionQuery query = this;
+        while (true) {
+            if (query.isBaseQuery(query)) {
+                sb.insert(0, CQ_PROPERTY + ".");
+                break;
+            } else {
+                final String foreignPropertyName = query
+                        .getForeignPropertyName();
+                if (foreignPropertyName == null) {
+                    String msg = "The foreignPropertyName of the query should not be null:";
+                    msg = msg + " query=" + query;
+                    throw new IllegalStateException(msg);
+                }
+                sb.insert(0, CQ_PROPERTY + initCap(foreignPropertyName) + ".");
+            }
+            query = query.getChildQuery();
+        }
+        return sb.toString();
+    }
+
+    protected String getLocationBase(String columnPropertyName) {
+        return getLocationBase() + columnPropertyName;
+    }
+
+    // ===================================================================================
+    //                                                                         Union Query
+    //                                                                         ===========
+    /** The map of union query. */
+    protected Map<String, ConditionQuery> _unionQueryMap;
+
+    /**
+     * Get the map of union query.
+     * 
+     * @return The map of union query. (NotNull)
+     */
+    public Map<String, ConditionQuery> getUnionQueryMap() {// for Internal
+        if (_unionQueryMap == null) {
+            _unionQueryMap = new LinkedHashMap<String, ConditionQuery>();
+        }
+        return _unionQueryMap;
+    }
+
+    /**
+     * Set union query. {Internal}
+     * <pre>
+     * Add union query to condition bean.
+     * </pre>
+     * @param unionQuery Union query. (NotNull)
+     */
+    public void xsetUnionQuery(ConditionQuery unionQuery) {
+        xsetupUnion(unionQuery, false, getUnionQueryMap());
+    }
+
+    /** The map of union all query. */
+    protected Map<String, ConditionQuery> _unionAllQueryMap;
+
+    /**
+     * Get the map of union all query.
+     * 
+     * @return The map of union all query. (NotNull)
+     */
+    public Map<String, ConditionQuery> getUnionAllQueryMap() {// for Internal
+        if (_unionAllQueryMap == null) {
+            _unionAllQueryMap = new LinkedHashMap<String, ConditionQuery>();
+        }
+        return _unionAllQueryMap;
+    }
+
+    /**
+     * Set union all query. {Internal}
+     * <pre>
+     * Add union all query to condition bean.
+     * </pre>
+     * @param unionAllQuery Union all query. (NotNull)
+     */
+    public void xsetUnionAllQuery(ConditionQuery unionAllQuery) {
+        xsetupUnion(unionAllQuery, true, getUnionAllQueryMap());
+    }
+
+    protected void xsetupUnion(ConditionQuery unionQuery, boolean unionAll,
+            Map<String, ConditionQuery> unionQueryMap) {
+        if (unionQuery == null) {
+            String msg = "The argument[unionQuery] should not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+        reflectRelationOnUnionQuery(this, unionQuery);// Reflect Relation!
+        getSqlClause().copyIncludedSelectColumn(unionQuery.getSqlClause());// Reflect IncludedSelectColumn!
+        if (getSqlClause().isFormatClauseEffective()) {
+            unionQuery.getSqlClause().makeFormatClauseEffective();// Reflect FormatClause!
+        }
+        final String key = (unionAll ? "unionAllQuery" : "unionQuery")
+                + unionQueryMap.size();
+        unionQueryMap.put(key, unionQuery);
+        registerUnionQuery(unionQuery, unionAll, (unionAll ? "unionAllQueryMap"
+                : "unionQueryMap")
+                + "." + key);
+    }
+
+    /**
+     * Reflect relation on union query.
+     * 
+     * @param baseQueryAsSuper Base query as super. (NotNull)
+     * @param unionQueryAsSuper Union query as super. (NotNull)
+     */
+    abstract protected void reflectRelationOnUnionQuery(
+            ConditionQuery baseQueryAsSuper, ConditionQuery unionQueryAsSuper);
+
+    /**
+     * Has union query or union all query?
+     * 
+     * @return Determination.
+     */
+    public boolean hasUnionQueryOrUnionAllQuery() {
+        return (_unionQueryMap != null && !_unionQueryMap.isEmpty())
+                || (_unionAllQueryMap != null && !_unionAllQueryMap.isEmpty());
+    }
+
+    /**
+     * Get the list of union query.
+     * 
+     * @return The list of union query. (NotNull)
+     */
+    public List<ConditionQuery> getUnionQueryList() {
+        if (_unionQueryMap == null) {
+            return new ArrayList<ConditionQuery>();
+        }
+        return new ArrayList<ConditionQuery>(_unionQueryMap.values());
+    }
+
+    /**
+     * Get the list of union all query.
+     * 
+     * @return The list of union all query. (NotNull)
+     */
+    public List<ConditionQuery> getUnionAllQueryList() {
+        if (_unionAllQueryMap == null) {
+            return new ArrayList<ConditionQuery>();
+        }
+        return new ArrayList<ConditionQuery>(_unionAllQueryMap.values());
+    }
+
+    // ===================================================================================
+    //                                                                            Register
+    //                                                                            ========
+    // -----------------------------------------------------
+    //                                       Include-As-Mine
+    //                                       ---------------
+    /**
+     * Register included-select-column.
+     * 
+     * @param aliasName Alias name. This should not contain comma. (NotNull)
+     * @param realColumnName Real column name. This should not contain comma. (NotNull)
+     */
+    protected void registerIncludedSelectColumn(String aliasName,
+            String realColumnName) {
+        assertAliasName(aliasName);
+        assertColumnName(realColumnName);
+        getSqlClause().registerIncludedSelectColumn(aliasName, realColumnName);
+    }
+
+    // -----------------------------------------------------
+    //                                                 Query
+    //                                                 -----
+    protected void registerQuery(ConditionKey key, Object value,
+            ConditionValue cvalue, String colName, String capPropName,
+            String uncapPropName) {
+        if (key.isValidRegistration(cvalue, value, key.getConditionKey()
+                + " of " + getRealAliasName() + "." + colName)) {
+            setupConditionValueAndRegisterWhereClause(key, value, cvalue,
+                    colName, capPropName, uncapPropName);
+        }
+    }
+
+    protected void registerQuery(ConditionKey key, Object value,
+            ConditionValue cvalue, String colName, String capPropName,
+            String uncapPropName, ConditionOption option) {
+        if (key.isValidRegistration(cvalue, value, key.getConditionKey()
+                + " of " + getRealAliasName() + "." + colName)) {
+            setupConditionValueAndRegisterWhereClause(key, value, cvalue,
+                    colName, capPropName, uncapPropName, option);
+        }
+    }
+
+    // -----------------------------------------------------
+    //                                          FromTo Query
+    //                                          ------------
+    protected void registerFromToQuery(java.util.Date fromDate,
+            java.util.Date toDate, ConditionValue cvalue, String colName,
+            String capPropName, String uncapPropName, FromToOption option) {
+        {
+            final java.util.Date filteredFromDate = option
+                    .filterFromDate(fromDate);
+            final ConditionKey fromKey = option.getFromDateConditionKey();
+            if (fromKey.isValidRegistration(cvalue, filteredFromDate, fromKey
+                    .getConditionKey()
+                    + " of " + getRealAliasName() + "." + uncapPropName)) {
+                setupConditionValueAndRegisterWhereClause(fromKey,
+                        filteredFromDate, cvalue, colName, capPropName,
+                        uncapPropName);
+            }
+        }
+        {
+            final java.util.Date filteredToDate = option.filterToDate(toDate);
+            final ConditionKey toKey = option.getToDateConditionKey();
+            if (toKey.isValidRegistration(cvalue, filteredToDate, toKey
+                    .getConditionKey()
+                    + " of " + getRealAliasName() + "." + uncapPropName)) {
+                setupConditionValueAndRegisterWhereClause(toKey,
+                        filteredToDate, cvalue, colName, capPropName,
+                        uncapPropName);
+            }
+        }
+    }
+
+    // -----------------------------------------------------
+    //                                      LikeSearch Query
+    //                                      ----------------
+    protected void registerLikeSearchQuery(ConditionKey key, String value,
+            ConditionValue cvalue, String colName, String capPropName,
+            String uncapPropName, LikeSearchOption option) {
+        final String validationMsg = key.getConditionKey() + " of "
+                + getRealAliasName() + "." + colName;
+        if (!key.isValidRegistration(cvalue, value, validationMsg)) {
+            return;
+        }
+        if (option == null) {
+            throwLikeSearchOptionNotFoundException(capPropName, value);
+            return;// Unreachable!
+        }
+        if (value == null || !option.isSplit()) {
+            // As Normal Condition.
+            setupConditionValueAndRegisterWhereClause(key, value, cvalue,
+                    colName, capPropName, uncapPropName, option);
+            return;
+        }
+        // - - - - - - - - -
+        // Use splitByXxx().
+        // - - - - - - - - -
+        final String[] strArray = option.generateSplitValueArray(value);
+        if (!option.isAsOrSplit()) {
+            // As 'and' Condition
+            for (int i = 0; i < strArray.length; i++) {
+                final String currentValue = strArray[i];
+                setupConditionValueAndRegisterWhereClause(key, currentValue,
+                        cvalue, colName, capPropName, uncapPropName, option);
+
+                // Callback for LikeAsOr!
+                final List<LikeSearchOption.LikeAsOrCallback> callbackList = option
+                        .getLikeAsOrCallbackList();
+                if (!callbackList.isEmpty()) {
+                    getSqlClause().makeAdditionalConditionAsOrEffective();
+                    for (Iterator<LikeSearchOption.LikeAsOrCallback> ite = callbackList
+                            .iterator(); ite.hasNext();) {
+                        final LikeSearchOption.LikeAsOrCallback likeAsOrCallback = (LikeSearchOption.LikeAsOrCallback) ite
+                                .next();
+                        final String additionalTargetPropertyName = likeAsOrCallback
+                                .getAdditionalTargetPropertyName();
+                        final String filteredValue = likeAsOrCallback
+                                .filterValue(currentValue);
+                        final LikeSearchOption optionDeepCopy = (LikeSearchOption) option
+                                .createDeepCopy();
+                        optionDeepCopy.clearLikeAsOrCallback();
+                        final LikeSearchOption filteredOption = likeAsOrCallback
+                                .filterOption(optionDeepCopy);
+                        invokeSetterLikeSearch(additionalTargetPropertyName,
+                                filteredValue, filteredOption);
+                    }
+                    getSqlClause().ignoreAdditionalConditionAsOr();
+                }
+            }
+        } else {
+            // As 'or' Condition
+            for (int i = 0; i < strArray.length; i++) {
+                final String currentValue = strArray[i];
+                if (i == 0) {
+                    setupConditionValueAndRegisterWhereClause(key,
+                            currentValue, cvalue, colName, capPropName,
+                            uncapPropName, option);
+                } else {
+                    getSqlClause().makeAdditionalConditionAsOrEffective();
+                    invokeSetterLikeSearch(uncapPropName, currentValue, option);
+                }
+            }
+
+            // @jflute -- Callback for LikeAsOr!
+            // final List<LikeSearchOption.LikeAsOrCallback> callbackList = option.getLikeAsOrCallbackList();
+            // ...
+
+            getSqlClause().ignoreAdditionalConditionAsOr();
+        }
+    }
+
+    protected void throwLikeSearchOptionNotFoundException(String capPropName,
+            String value) {
+        String msg = "Look! Read the message below." + getLineSeparator();
+        msg = msg
+                + "/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *"
+                + getLineSeparator();
+        msg = msg + "The likeSearchOption was Not Found! (Should not be null!)"
+                + getLineSeparator();
+        msg = msg + getLineSeparator();
+        msg = msg + "[Advice]" + getLineSeparator();
+        msg = msg + "Please confirm your method call:" + getLineSeparator();
+        final String beanName = getClass().getSimpleName();
+        final String methodName = "set" + capPropName + "_LikeSearch('" + value
+                + "', likeSearchOption);";
+        msg = msg + "    " + beanName + "." + methodName + getLineSeparator();
+        msg = msg + "* * * * * * * * * */" + getLineSeparator();
+        throw new RequiredOptionNotFoundException(msg);
+    }
+
+    protected void invokeSetterLikeSearch(String columnFlexibleName,
+            Object value, LikeSearchOption option) {
+        if (value == null) {
+            return;
+        }
+        final DBMeta dbmeta = DBMetaInstanceHandler
+                .findDBMeta(getTableDbName());
+        final String columnCapPropName = initCap(dbmeta
+                .findPropertyName(columnFlexibleName));
+        String methodName = "set" + columnCapPropName + "_"
+                + "likeSearch".substring(0, 1).toUpperCase()
+                + "likeSearch".substring(1);
+        java.lang.reflect.Method method = null;
+        try {
+            method = this.getClass().getMethod(methodName,
+                    new Class[] { value.getClass(), LikeSearchOption.class });
+        } catch (NoSuchMethodException e) {
+            String msg = "The columnFlexibleName is not existing in this table: columnFlexibleName="
+                    + columnFlexibleName;
+            msg = msg + " tableName=" + getTableDbName() + " methodName="
+                    + methodName;
+            throw new RuntimeException(msg, e);
+        }
+        try {
+            method.invoke(this, new Object[] { value, option });
+        } catch (IllegalAccessException e) {
+            throw new RuntimeException(e);
+        } catch (java.lang.reflect.InvocationTargetException e) {
+            throw new RuntimeException(e.getCause());
+        }
+    }
+
+    // -----------------------------------------------------
+    //                                         InScope Query
+    //                                         -------------
+    protected void registerInScopeQuery(ConditionKey key, String value,
+            ConditionValue cvalue, String colName, String capPropName,
+            String uncapPropName, InScopeOption option) {
+        if (key.isValidRegistration(cvalue, value, key.getConditionKey()
+                + " of " + getRealAliasName() + "." + colName)) {
+            if (value != null && option.isSplit()) {
+                final String[] strArray = option.generateSplitValueArray(value);
+                final List<String> realValueList = new ArrayList<String>();
+                for (int i = 0; i < strArray.length; i++) {
+                    final String currentValue = strArray[i];
+                    realValueList.add(currentValue);
+                }
+                setupConditionValueAndRegisterWhereClause(key, realValueList,
+                        cvalue, colName, capPropName, uncapPropName, option);
+            } else {
+                setupConditionValueAndRegisterWhereClause(key, value, cvalue,
+                        colName, capPropName, uncapPropName, option);
+            }
+        }
+    }
+
+    // -----------------------------------------------------
+    //                                          Inline Query
+    //                                          ------------
+    protected void registerInlineQuery(ConditionKey key, Object value,
+            ConditionValue cvalue, String colName, String capPropName,
+            String uncapPropName) {
+        if (key.isValidRegistration(cvalue, value, key.getConditionKey()
+                + " of " + getRealAliasName() + "." + colName)) {
+            key.setupConditionValue(cvalue, value, getLocation(uncapPropName,
+                    key));// If Java, it is necessary to use uncapPropName!
+            if (isBaseQuery(this)) {
+                getSqlClause().registerBaseTableInlineWhereClause(colName, key,
+                        cvalue);
+            } else {
+                getSqlClause().registerOuterJoinInlineWhereClause(
+                        getRealAliasName(), colName, key, cvalue,
+                        _onClauseInline);
+            }
+        }
+    }
+
+    protected void registerInlineQuery(ConditionKey key, Object value,
+            ConditionValue cvalue, String colName, String capPropName,
+            String uncapPropName, ConditionOption option) {
+        if (key.isValidRegistration(cvalue, value, key.getConditionKey()
+                + " of " + getRealAliasName() + "." + colName)) {
+            key.setupConditionValue(cvalue, value, getLocation(uncapPropName,
+                    key), option);// If Java, it is necessary to use uncapPropName!
+            if (isBaseQuery(this)) {
+                getSqlClause().registerBaseTableInlineWhereClause(colName, key,
+                        cvalue, option);
+            } else {
+                getSqlClause().registerOuterJoinInlineWhereClause(
+                        getRealAliasName(), colName, key, cvalue, option,
+                        _onClauseInline);
+            }
+        }
+    }
+
+    // -----------------------------------------------------
+    //                                       InScopeSubQuery
+    //                                       ---------------
+    protected void registerInScopeSubQuery(ConditionQuery subQuery,
+            String columnName, String relatedColumnName, String propertyName) {
+        final String realColumnName = getInScopeSubQueryRealColumnName(columnName);
+        final String subQueryClause = getInScopeSubQuerySql(subQuery,
+                relatedColumnName, propertyName);
+        registerWhereClause(realColumnName + " in (" + subQueryClause + ")");
+    }
+
+    protected String getInScopeSubQueryRealColumnName(String columnName) {
+        return getRealColumnName(columnName);
+    }
+
+    protected String getInScopeSubQuerySql(ConditionQuery subQuery,
+            String relatedColumnName, String propertyName) {
+        final String selectClause = "select "
+                + getSqlClause().getLocalTableAliasName() + "."
+                + relatedColumnName;
+        String fromWhereClause = subQuery.getSqlClause()
+                .getClauseFromWhereWithUnionTemplate();
+        fromWhereClause = replaceString(fromWhereClause, ".conditionQuery.",
+                "." + getLocationBase(propertyName) + ".");// Very Important!
+
+        // Replace template marks. These are very important!
+        fromWhereClause = replaceString(fromWhereClause, getSqlClause()
+                .getUnionSelectClauseMark(), selectClause);
+        fromWhereClause = replaceString(fromWhereClause, getSqlClause()
+                .getUnionWhereClauseMark(), "");
+        fromWhereClause = replaceString(fromWhereClause, getSqlClause()
+                .getUnionWhereFirstConditionMark(), "");
+
+        return selectClause + " " + fromWhereClause;
+    }
+
+    // -----------------------------------------------------
+    //                                        ExistsSubQuery
+    //                                        --------------
+    protected void registerExistsSubQuery(ConditionQuery subQuery,
+            String columnName, String relatedColumnName, String propertyName) {
+        final String realColumnName = getExistsSubQueryRealColumnName(columnName);
+        final String subQueryClause = getExistsSubQuerySql(subQuery,
+                realColumnName, relatedColumnName, propertyName);
+        registerWhereClause("exists (" + subQueryClause + ")");
+    }
+
+    protected String getExistsSubQueryRealColumnName(String columnName) {
+        return getRealColumnName(columnName);
+    }
+
+    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
+    // *Unsupport ExistsSubQuery as inline because it's so dangerous.
+    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
+
+    protected String getExistsSubQuerySql(ConditionQuery subQuery,
+            String realColumnName, String relatedColumnName, String propertyName) {
+        final int subQueryLevel = subQuery.getSubQueryLevel();
+        if (_subQueryLevel <= subQueryLevel) {
+            _subQueryLevel = subQueryLevel + 1;
+        }
+        final String tableAliasName = "dfsublocal_" + subQueryLevel;
+        final String selectClause = "select " + tableAliasName + "."
+                + relatedColumnName;
+        String fromWhereClause = subQuery.getSqlClause()
+                .getClauseFromWhereWithWhereUnionTemplate();
+        fromWhereClause = replaceString(fromWhereClause, "dflocal",
+                tableAliasName);// Very Important!
+        fromWhereClause = replaceString(fromWhereClause, ".conditionQuery.",
+                "." + getLocationBase(propertyName) + ".");// Very Important!
+
+        final String joinCondition = tableAliasName + "." + relatedColumnName
+                + " = " + realColumnName;
+
+        // Replace template marks. These are very important!
+        fromWhereClause = replaceString(fromWhereClause, getSqlClause()
+                .getWhereClauseMark(), "where " + joinCondition);
+        fromWhereClause = replaceString(fromWhereClause, getSqlClause()
+                .getWhereFirstConditionMark(), joinCondition + " and ");
+        fromWhereClause = replaceString(fromWhereClause, getSqlClause()
+                .getUnionSelectClauseMark(), selectClause);
+        fromWhereClause = replaceString(fromWhereClause, getSqlClause()
+                .getUnionWhereClauseMark(), "where " + joinCondition);
+        fromWhereClause = replaceString(fromWhereClause, getSqlClause()
+                .getUnionWhereFirstConditionMark(), joinCondition + " and ");
+
+        return selectClause + " " + fromWhereClause;
+    }
+
+    // -----------------------------------------------------
+    //                                          Where Clause
+    //                                          ------------
+    protected void setupConditionValueAndRegisterWhereClause(ConditionKey key,
+            Object value, ConditionValue cvalue, String colName,
+            String capPropName, String uncapPropName) {
+        key.setupConditionValue(cvalue, value, getLocation(uncapPropName, key));// If Java, it is necessary to use uncapPropName!
+        getSqlClause().registerWhereClause(getRealColumnName(colName), key,
+                cvalue);
+    }
+
+    protected void setupConditionValueAndRegisterWhereClause(ConditionKey key,
+            Object value, ConditionValue cvalue, String colName,
+            String capPropName, String uncapPropName, ConditionOption option) {
+        key.setupConditionValue(cvalue, value, getLocation(uncapPropName, key),
+                option);// If Java, it is necessary to use uncapPropName!
+        getSqlClause().registerWhereClause(getRealColumnName(colName), key,
+                cvalue, option);
+    }
+
+    protected void registerWhereClause(String whereClause) {
+        getSqlClause().registerWhereClause(whereClause);
+    }
+
+    protected void registerInlineWhereClause(String whereClause) {
+        if (isBaseQuery(this)) {
+            getSqlClause().registerBaseTableInlineWhereClause(whereClause);
+        } else {
+            getSqlClause().registerOuterJoinInlineWhereClause(
+                    getRealAliasName(), whereClause, _onClauseInline);
+        }
+    }
+
+    // -----------------------------------------------------
+    //                                           Union Query
+    //                                           -----------
+    public void registerUnionQuery(ConditionQuery unionQuery, boolean unionAll,
+            String unionQueryPropertyName) {
+        final String unionQueryClause = getUnionQuerySql(unionQuery,
+                unionQueryPropertyName);
+
+        // At the future, building SQL will be moved to sqlClause.
+        getSqlClause().registerUnionQuery(unionQueryClause, unionAll);
+    }
+
+    protected String getUnionQuerySql(ConditionQuery unionQuery,
+            String unionQueryPropertyName) {
+        final String fromClause = unionQuery.getSqlClause().getFromClause();
+        final String whereClause = unionQuery.getSqlClause().getWhereClause();
+        final String unionQueryClause;
+        if (whereClause.trim().length() <= 0) {
+            unionQueryClause = fromClause + " "
+                    + getSqlClause().getUnionWhereClauseMark();
+        } else {
+            final int whereIndex = whereClause.indexOf("where ");
+            if (whereIndex < 0) {
+                String msg = "The whereClause should have 'where' string: "
+                        + whereClause;
+                throw new IllegalStateException(msg);
+            }
+            final int clauseIndex = whereIndex + "where ".length();
+            final String mark = getSqlClause()
+                    .getUnionWhereFirstConditionMark();
+            unionQueryClause = fromClause + " "
+                    + whereClause.substring(0, clauseIndex) + mark
+                    + whereClause.substring(clauseIndex);
+        }
+        final String oldStr = ".conditionQuery.";
+        final String newStr = ".conditionQuery." + unionQueryPropertyName + ".";
+        return replaceString(unionQueryClause, oldStr, newStr);// Very Important!
+    }
+
+    // -----------------------------------------------------
+    //                                               OrderBy
+    //                                               -------
+    public void withNullsFirst() {// is User Public!
+        getSqlClause().addNullsFirstToPreviousOrderBy();
+    }
+
+    public void withNullsLast() {// is User Public!
+        getSqlClause().addNullsLastToPreviousOrderBy();
+    }
+
+    protected void registerOrderBy(String columnName, boolean ascOrDesc) {
+        getSqlClause().registerOrderBy(getRealColumnName(columnName), null,
+                ascOrDesc);
+    }
+
+    // ===================================================================================
+    //                                                                       Name Resolver
+    //                                                                       =============
+    /**
+     * Resolve join alias name.
+     * @param relationPath Relation path. (NotNull)
+     * @param nestLevel Nest level.
+     * @return Resolved join alias name. (NotNull)
+     */
+    protected String resolveJoinAliasName(String relationPath, int nestLevel) {
+        return getSqlClause().resolveJoinAliasName(relationPath, nestLevel);
+    }
+
+    protected String resolveNestLevelExpression(String name) {
+        return getSqlClause().resolveNestLevelExpression(name, getNestLevel());
+    }
+
+    protected String resolveNextRelationPath(String tableName,
+            String relationPropertyName) {
+        final int relationNo = getSqlClause().resolveRelationNo(tableName,
+                relationPropertyName);
+        String nextRelationPath = "_" + relationNo;
+        if (_relationPath != null) {
+            nextRelationPath = _relationPath + nextRelationPath;
+        }
+        return nextRelationPath;
+    }
+
+    // ===================================================================================
+    //                                                                     Fixed Condition
+    //                                                                     ===============
+    protected String prepareFixedCondition(String fixedCondition,
+            String localAliasName, String foreignAliasName) {
+        fixedCondition = replaceString(fixedCondition, "$$alias$$",
+                foreignAliasName);
+        fixedCondition = replaceString(fixedCondition, "$$foreignAlias$$",
+                foreignAliasName);
+        fixedCondition = replaceString(fixedCondition, "$$localAlias$$",
+                localAliasName);
+        return fixedCondition;
+    }
+
+    // ===================================================================================
+    //                                                                              Invoke
+    //                                                                              ======
+    /**
+     * The implementation.
+     * 
+     * @param columnFlexibleName The flexible name of the column. (NotNull and NotEmpty)
+     * @return The conditionValue. (NotNull)
+     */
+    public ConditionValue invokeValue(String columnFlexibleName) {
+        final DBMeta dbmeta = DBMetaInstanceHandler
+                .findDBMeta(getTableDbName());
+        final String columnCapPropName = initCap(dbmeta
+                .findPropertyName(columnFlexibleName));
+        String methodName = "get" + columnCapPropName;
+        java.lang.reflect.Method method = null;
+        try {
+            method = this.getClass().getMethod(methodName, new Class[] {});
+        } catch (NoSuchMethodException e) {
+            String msg = "The columnFlexibleName is not existing in this table: columnFlexibleName="
+                    + columnFlexibleName;
+            msg = msg + " tableName=" + getTableDbName() + " methodName="
+                    + methodName;
+            throw new RuntimeException(msg, e);
+        }
+        try {
+            final Object result = method.invoke(this, new Object[] {});
+            return (ConditionValue) result;
+        } catch (IllegalAccessException e) {
+            throw new RuntimeException(e);
+        } catch (java.lang.reflect.InvocationTargetException e) {
+            throw new RuntimeException(e.getCause());
+        }
+    }
+
+    /**
+     * Invoke setting query.
+     * 
+     * @param columnFlexibleName The flexible name of the column. (NotNull and NotEmpty)
+     * @param conditionKeyName The name of the conditionKey. (NotNull)
+     * @param value The value of the condition. (NotNull)
+     */
+    public void invokeQuery(String columnFlexibleName, String conditionKeyName,
+            Object value) {
+        if (value == null) {
+            return;
+        }
+        final DBMeta dbmeta = DBMetaInstanceHandler
+                .findDBMeta(getTableDbName());
+        final String columnCapPropName = initCap(dbmeta
+                .findPropertyName(columnFlexibleName));
+        String methodName = "set" + columnCapPropName + "_"
+                + conditionKeyName.substring(0, 1).toUpperCase()
+                + conditionKeyName.substring(1);
+        java.lang.reflect.Method method = null;
+        try {
+            method = this.getClass().getMethod(methodName,
+                    new Class[] { value.getClass() });
+        } catch (NoSuchMethodException e) {
+            String msg = "The columnFlexibleName is not existing in this table: columnFlexibleName="
+                    + columnFlexibleName;
+            msg = msg + " tableName=" + getTableDbName() + " methodName="
+                    + methodName;
+            throw new RuntimeException(msg, e);
+        }
+        try {
+            method.invoke(this, new Object[] { value });
+        } catch (IllegalAccessException e) {
+            throw new RuntimeException(e);
+        } catch (java.lang.reflect.InvocationTargetException e) {
+            throw new RuntimeException(e.getCause());
+        }
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param columnFlexibleName The flexible name of a column. (NotNull and NotEmpty)
+     * @param isAsc Is it ascend?
+     */
+    public void invokeOrderBy(String columnFlexibleName, boolean isAsc) {
+        String ascDesc = null;
+        if (isAsc) {
+            ascDesc = "Asc";
+        } else {
+            ascDesc = "Desc";
+        }
+        final DBMeta dbmeta = DBMetaInstanceHandler
+                .findDBMeta(getTableDbName());
+        final String columnCapPropName = initCap(dbmeta
+                .findPropertyName(columnFlexibleName));
+        final String methodName = "addOrderBy_" + columnCapPropName + "_"
+                + ascDesc;
+
+        java.lang.reflect.Method method = null;
+        try {
+            method = this.getClass().getMethod(methodName, new Class[] {});
+        } catch (NoSuchMethodException e) {
+            String msg = "The columnFlexibleName is not existing in this table: columnFlexibleName="
+                    + columnFlexibleName;
+            msg = msg + " tableName=" + getTableDbName() + " methodName="
+                    + methodName;
+            throw new RuntimeException(msg, e);
+        }
+        try {
+            method.invoke(this, new Object[] {});
+        } catch (IllegalAccessException e) {
+            throw new RuntimeException(e);
+        } catch (java.lang.reflect.InvocationTargetException e) {
+            throw new RuntimeException(e.getCause());
+        }
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param foreignPropertyName The property name of foreign. (NotNull and NotEmpty)
+     * @return The conditionQuery of foreign as interface. (NotNull)
+     */
+    public ConditionQuery invokeForeignCQ(String foreignPropertyName) {
+        final String methodName = "query"
+                + foreignPropertyName.substring(0, 1).toUpperCase()
+                + foreignPropertyName.substring(1);
+        java.lang.reflect.Method method = null;
+        try {
+            method = this.getClass().getMethod(methodName, new Class[] {});
+        } catch (NoSuchMethodException e) {
+            String msg = "The foreignPropertyName is not existing in this table: foreignPropertyName="
+                    + foreignPropertyName;
+            msg = msg + " tableName=" + getTableDbName() + " methodName="
+                    + methodName;
+            throw new RuntimeException(msg, e);
+        }
+        try {
+            return (ConditionQuery) method.invoke(this, new Object[] {});
+        } catch (IllegalAccessException e) {
+            throw new RuntimeException(e);
+        } catch (java.lang.reflect.InvocationTargetException e) {
+            throw new RuntimeException(e.getCause());
+        }
+    }
+
+    // ===================================================================================
+    //                                                                       Assist Helper
+    //                                                                       =============
+    /**
+     * @param value Query-value-string. (Nullable)
+     * @return Filtered value. (Nullable)
+     */
+    protected String filterRemoveEmptyString(String value) {
+        return ((value != null && !"".equals(value)) ? value : null);
+    }
+
+    /**
+     * @param col Target collection. (Nullable)
+     * @param <PROPERTY_TYPE> The type of property.
+     * @return List. (Nullable: If the argument is null, returns null.)
+     */
+    protected <PROPERTY_TYPE> List<PROPERTY_TYPE> convertToList(
+            Collection<PROPERTY_TYPE> col) {
+        if (col == null) {
+            return null;
+        }
+        if (col instanceof List) {
+            return filterRemoveNullOrEmptyValueFromList((List<PROPERTY_TYPE>) col);
+        }
+        return filterRemoveNullOrEmptyValueFromList(new ArrayList<PROPERTY_TYPE>(
+                col));
+    }
+
+    private <PROPERTY_TYPE> List<PROPERTY_TYPE> filterRemoveNullOrEmptyValueFromList(
+            List<PROPERTY_TYPE> ls) {
+        if (ls == null) {
+            return null;
+        }
+        List<PROPERTY_TYPE> newList = new ArrayList<PROPERTY_TYPE>();
+        for (Iterator<PROPERTY_TYPE> ite = ls.iterator(); ite.hasNext();) {
+            final PROPERTY_TYPE element = ite.next();
+            if (element == null) {
+                continue;
+            }
+            if (element instanceof String) {
+                if (((String) element).length() == 0) {
+                    continue;
+                }
+            }
+            newList.add(element);
+        }
+        return newList;
+    }
+
+    // ===================================================================================
+    //                                                                      General Helper
+    //                                                                      ==============
+    protected final String replaceString(String text, String fromText,
+            String toText) {
+        return SimpleStringUtil.replace(text, fromText, toText);
+    }
+
+    protected String initCap(String str) {
+        return SimpleStringUtil.initCap(str);
+    }
+
+    protected String getLineSeparator() {
+        return SimpleSystemUtil.getLineSeparator();
+    }
+
+    // -----------------------------------------------------
+    //                                         Assert Object
+    //                                         -------------
+    /**
+     * Assert that the object is not null.
+     * 
+     * @param variableName Variable name. (NotNull)
+     * @param value Value. (NotNull)
+     * @exception IllegalArgumentException
+     */
+    protected void assertObjectNotNull(String variableName, Object value) {
+        if (variableName == null) {
+            String msg = "The value should not be null: variableName="
+                    + variableName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+        if (value == null) {
+            String msg = "The value should not be null: variableName="
+                    + variableName;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    /**
+     * Assert that the column-name is not null and is not empty and does not contain comma.
+     * 
+     * @param columnName Column-name. (NotNull)
+     * @exception IllegalArgumentException
+     */
+    protected void assertColumnName(String columnName) {
+        if (columnName == null) {
+            String msg = "The columnName should not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+        if (columnName.trim().length() == 0) {
+            String msg = "The columnName should not be empty-string.";
+            throw new IllegalArgumentException(msg);
+        }
+        if (columnName.indexOf(",") >= 0) {
+            String msg = "The columnName should not contain comma ',': "
+                    + columnName;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    /**
+     * Assert that the alias-name is not null and is not empty and does not contain comma.
+     * 
+     * @param aliasName Alias-name. (NotNull)
+     * @exception IllegalArgumentException
+     */
+    protected void assertAliasName(String aliasName) {
+        if (aliasName == null) {
+            String msg = "The aliasName should not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+        if (aliasName.trim().length() == 0) {
+            String msg = "The aliasName should not be empty-string.";
+            throw new IllegalArgumentException(msg);
+        }
+        if (aliasName.indexOf(",") >= 0) {
+            String msg = "The aliasName should not contain comma ',': "
+                    + aliasName;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    // -----------------------------------------------------
+    //                                         Assert String
+    //                                         -------------
+    /**
+     * Assert that the entity is not null and not trimmed empty.
+     * 
+     * @param variableName Variable name. (NotNull)
+     * @param value Value. (NotNull)
+     */
+    protected void assertStringNotNullAndNotTrimmedEmpty(String variableName,
+            String value) {
+        assertObjectNotNull("variableName", variableName);
+        assertObjectNotNull("value", value);
+        if (value.trim().length() == 0) {
+            String msg = "The value should not be empty: variableName="
+                    + variableName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                      Basic Override
+    //                                                                      ==============
+    @Override
+    public String toString() {
+        return getClass().getSimpleName() + ":{aliasName=" + _aliasName
+                + ", nestLevel=" + _nestLevel + ", subQueryLevel="
+                + _subQueryLevel + ", foreignPropertyName="
+                + _foreignPropertyName + ", relationPath=" + _relationPath
+                + ", onClauseInline=" + _onClauseInline + "}";
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/AbstractConditionQuery.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,200 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClause;
+import jp.sf.pal.announcement.db.allcommon.jdbc.StatementConfig;
+
+/**
+ * The interface of condition-bean.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface ConditionBean extends PagingBean {
+
+    // =====================================================================================
+    //                                                                            Definition
+    //                                                                            ==========
+    /** Map-string map-mark. */
+    public static final String MAP_STRING_MAP_MARK = "map:";
+
+    /** Map-string list-mark. */
+    public static final String MAP_STRING_LIST_MARK = "list:";
+
+    /** Map-string start-brace. */
+    public static final String MAP_STRING_START_BRACE = "@{";
+
+    /** Map-string end-brace. */
+    public static final String MAP_STRING_END_BRACE = "@}";
+
+    /** Map-string delimiter. */
+    public static final String MAP_STRING_DELIMITER = "@;";
+
+    /** Map-string equal. */
+    public static final String MAP_STRING_EQUAL = "@=";
+
+    // ===================================================================================
+    //                                                                          Table Name
+    //                                                                          ==========
+    /**
+     * Get table DB-name.
+     * @return Table DB-name. (NotNull)
+     */
+    public String getTableDbName();
+
+    /**
+     * Get table SQL-name.
+     * @return Table SQL-name. (NotNull)
+     */
+    public String getTableSqlName();
+
+    // ===================================================================================
+    //                                                                           SqlClause
+    //                                                                           =========
+    /**
+     * Get SQL-clause instance.
+     * 
+     * @return SQL-clause. (NotNull)
+     */
+    public SqlClause getSqlClause();
+
+    // ===================================================================================
+    //                                                                      PrimaryKey Map
+    //                                                                      ==============
+    /**
+     * Accept primary-key map-string.
+     * @param primaryKeyMap Primary-key map. (NotNull and NotEmpty)
+     */
+    public void acceptPrimaryKeyMap(
+            java.util.Map<String, ? extends Object> primaryKeyMap);
+
+    /**
+     * Accept primary-key map-string. Delimiter is at-mark and semicolon.
+     * @param primaryKeyMapString Primary-key map. (NotNull and NotEmpty)
+     */
+    public void acceptPrimaryKeyMapString(String primaryKeyMapString);
+
+    // ===================================================================================
+    //                                                                     OrderBy Setting
+    //                                                                     ===============
+    /**
+     * Add order-by PrimaryKey asc. {order by primaryKey1 asc, primaryKey2 asc...}
+     * @return this. (NotNull)
+     */
+    public ConditionBean addOrderBy_PK_Asc();
+
+    /**
+     * Add order-by PrimaryKey desc. {order by primaryKey1 desc, primaryKey2 desc...}
+     * @return this. (NotNull)
+     */
+    public ConditionBean addOrderBy_PK_Desc();
+
+    // ===================================================================================
+    //                                                                               Query
+    //                                                                               =====
+    /**
+     * Get condition-query as interface.
+     * @return Instance of query as interface. (NotNull)
+     * @deprecated
+     */
+    public ConditionQuery getConditionQueryAsInterface();
+
+    /**
+     * Get the conditionQuery of the local table as interface.
+     * @return The conditionQuery of the local table as interface. (NotNull)
+     */
+    public ConditionQuery localCQ();
+
+    // ===================================================================================
+    //                                                                         Union Query
+    //                                                                         ===========
+    /**
+     * Has union query or union all query?
+     * @return Determination.
+     */
+    public boolean hasUnionQueryOrUnionAllQuery();
+
+    // ===================================================================================
+    //                                                                        Limit Select
+    //                                                                        ============
+    /**
+     * Limit select PK only.
+     * @return this. (NotNull)
+     */
+    public ConditionBean limitSelect_PKOnly();
+
+    /**
+     * Limit select off.
+     * @return this. (NotNull)
+     */
+    public ConditionBean limitSelect_Off();
+
+    /**
+     * Is limit-select PK only?
+     * @return Determination.
+     */
+    public boolean isLimitSelect_PKOnly();
+
+    // =====================================================================================
+    //                                                                          Lock Setting
+    //                                                                          ============
+    /**
+     * Lock for update.
+     * <p>
+     * If you invoke this, your SQL lock target records for update.
+     * It depends whether this method supports this on the database type.
+     * </p>
+     * @return this. (NotNull)
+     */
+    public ConditionBean lockForUpdate();
+
+    // =====================================================================================
+    //                                                                          Select Count
+    //                                                                          ============
+    /**
+     * Set up various things for select-count-ignore-fetch-scope. {Internal}
+     * This method is for INTERNAL. Don't invoke this!
+     * @return this. (NotNull)
+     */
+    public ConditionBean xsetupSelectCountIgnoreFetchScope();
+
+    /**
+     * Do after-care for select-count-ignore-fetch-scope. {Internal}
+     * This method is for INTERNAL. Don't invoke this!
+     * @return this. (NotNull)
+     */
+    public ConditionBean xafterCareSelectCountIgnoreFetchScope();
+
+    /**
+     * Is set up various things for select-count-ignore-fetch-scope? {Internal}
+     * This method is for INTERNAL. Don't invoke this!
+     * @return Determination.
+     */
+    public boolean isSelectCountIgnoreFetchScope();
+
+    // =====================================================================================
+    //                                                                      Statement Config
+    //                                                                      ================
+    /**
+     * @param statementConfig The config of statement. (Nullable)
+     */
+    public void configure(StatementConfig statementConfig);
+
+    /**
+     * @return The config of statement. (Nullable)
+     */
+    public StatementConfig getStatementConfig();
+
+    // ===================================================================================
+    //                                                                          Format SQL
+    //                                                                          ==========
+    public void formatSql();
+
+    public boolean isFormatSql();
+
+    // ===================================================================================
+    //                                                                         Display SQL
+    //                                                                         ===========
+    /**
+     * Convert this conditionBean to SQL for display.
+     * @return SQL for display. (NotNull and NotEmpty)
+     */
+    public String toDisplaySql();
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionBeanContext.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionBeanContext.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionBeanContext.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,395 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import java.util.Collections;
+import java.util.LinkedHashMap;
+import java.util.Map;
+
+import jp.sf.pal.announcement.db.allcommon.DBFluteConfig;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClause;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClauseDb2;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClauseDerby;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClauseFirebird;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClauseH2;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClauseMySql;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClauseOracle;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClausePostgreSql;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClauseSqlServer;
+import jp.sf.pal.announcement.db.allcommon.s2dao.internal.sqlparser.InternalSqlParser;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * Condition-Bean context.
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionBeanContext {
+
+    /** Log instance. */
+    private static final Log _log = LogFactory
+            .getLog(ConditionBeanContext.class);
+
+    // ===================================================================================
+    //                                                                        Thread Local
+    //                                                                        ============
+    /** The thread-local for this. */
+    private static final ThreadLocal<ConditionBean> _threadLocal = new ThreadLocal<ConditionBean>();
+
+    /**
+     * Get condition-bean on thread.
+     * @return Condition-bean context. (Nullable)
+     */
+    public static ConditionBean getConditionBeanOnThread() {
+        return (ConditionBean) _threadLocal.get();
+    }
+
+    /**
+     * Set condition-bean on thread.
+     * @param cb Condition-bean. (NotNull)
+     */
+    public static void setConditionBeanOnThread(ConditionBean cb) {
+        if (cb == null) {
+            String msg = "The argument[cb] must not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+        _threadLocal.set(cb);
+    }
+
+    /**
+     * Is existing condition-bean on thread?
+     * @return Determination.
+     */
+    public static boolean isExistConditionBeanOnThread() {
+        return (_threadLocal.get() != null);
+    }
+
+    /**
+     * Clear condition-bean on thread.
+     */
+    public static void clearConditionBeanOnThread() {
+        _threadLocal.set(null);
+    }
+
+    // ===================================================================================
+    //                                         Initialize against the ClassLoader Headache
+    //                                         ===========================================
+    @SuppressWarnings("unused")
+    public static void initialize() {
+        boolean debugEnabled = _log.isDebugEnabled();
+        // Against the ClassLoader Headache!
+        final StringBuilder sb = new StringBuilder();
+        {
+            final Class<?> clazz = jp.sf.pal.announcement.db.allcommon.cbean.SimplePagingBean.class;
+            if (debugEnabled) {
+                sb.append(
+                        "  ...Loading class of " + clazz.getName() + " by "
+                                + clazz.getClassLoader().getClass()).append(
+                        getLineSeparator());
+            }
+        }
+        {
+            Class<?> clazz = jp.sf.pal.announcement.db.allcommon.cbean.coption.FromToOption.class;
+            clazz = jp.sf.pal.announcement.db.allcommon.cbean.coption.LikeSearchOption.class;
+            clazz = jp.sf.pal.announcement.db.allcommon.cbean.coption.InScopeOption.class;
+            clazz = jp.sf.pal.announcement.db.allcommon.cbean.grouping.GroupingOption.class;
+            clazz = jp.sf.pal.announcement.db.allcommon.cbean.grouping.GroupingRowEndDeterminer.class;
+            clazz = jp.sf.pal.announcement.db.allcommon.cbean.grouping.GroupingRowResource.class;
+            clazz = jp.sf.pal.announcement.db.allcommon.cbean.grouping.GroupingRowSetupper.class;
+            clazz = jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.PageNumberLink.class;
+            clazz = jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.PageNumberLinkSetupper.class;
+            clazz = jp.sf.pal.announcement.db.allcommon.jdbc.CursorHandler.class;
+            if (debugEnabled) {
+                sb.append("  ...Loading class of ...and so on");
+            }
+        }
+        if (debugEnabled) {
+            _log.debug("{Initialize against the ClassLoader Headache}"
+                    + getLineSeparator() + sb);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                  Type Determination
+    //                                                                  ==================
+    /**
+     * Is the argument condition-bean?
+     * @param dtoInstance DTO instance.
+     * @return Determination.
+     */
+    public static boolean isTheArgumentConditionBean(final Object dtoInstance) {
+        if (dtoInstance instanceof ConditionBean) {
+            return true;
+        } else {
+            return false;
+        }
+    }
+
+    /**
+     * Is the type condition-bean?
+     * @param dtoClass DtoClass.
+     * @return Determination.
+     */
+    public static boolean isTheTypeConditionBean(final Class<?> dtoClass) {
+        if (ConditionBean.class.isAssignableFrom(dtoClass)) {
+            return true;
+        } else {
+            return false;
+        }
+    }
+
+    // ===================================================================================
+    //                                                                        Product Name
+    //                                                                        ============
+    public static final String DB_NAME_DERBY = "derby";
+
+    public static final String DB_NAME_H2 = "h2";
+
+    public static final String DB_NAME_ORACLE = "oracle";
+
+    public static final String DB_NAME_MYSQL = "mysql";
+
+    public static final String DB_NAME_POSTGRESQL = "postgresql";
+
+    public static final String DB_NAME_FIREBIRD = "firebird";
+
+    public static final String DB_NAME_MSSQL = "mssql";
+
+    public static final String DB_NAME_SYBASE = "sybase";
+
+    public static final String DB_NAME_DB2 = "db2";
+
+    protected static final Map<String, String> _driverHintDatabaseProductNameMap;
+    static {
+        final Map<String, String> tmpMap = Collections
+                .synchronizedMap(new LinkedHashMap<String, String>());
+        tmpMap.put("org.apache.derby", DB_NAME_DERBY);
+        tmpMap.put("org.h2", DB_NAME_H2);
+        tmpMap.put("oracle", DB_NAME_ORACLE);
+        tmpMap.put("mysql", DB_NAME_MYSQL);
+        tmpMap.put("postgresql", DB_NAME_POSTGRESQL);
+        tmpMap.put("firebird", DB_NAME_FIREBIRD);
+        tmpMap.put("sqlserver", DB_NAME_MSSQL);
+        tmpMap.put("sybase", DB_NAME_SYBASE);
+        tmpMap.put("db2", DB_NAME_DB2);
+        _driverHintDatabaseProductNameMap = java.util.Collections
+                .unmodifiableMap(tmpMap);
+    }
+
+    public static boolean setupDatabaseProductNameByDriverClassName(
+            String driverClassName) {
+        final java.util.Set<String> keySet = _driverHintDatabaseProductNameMap
+                .keySet();
+        for (final java.util.Iterator<String> ite = keySet.iterator(); ite
+                .hasNext();) {
+            final String driverHint = (String) ite.next();
+            if (driverClassName.indexOf(driverHint) >= 0) {
+                final String databaseProductName = (String) _driverHintDatabaseProductNameMap
+                        .get(driverHint);
+                setDatabaseProductName(databaseProductName);
+                return true;
+            }
+        }
+        return false;
+    }
+
+    /** The database product name. */
+    private static String _databaseProductName;
+
+    /**
+     * Get database product name.
+     * @return Database product name.
+     */
+    public static String getDatabaseProductName() {
+        return _databaseProductName;
+    }
+
+    /**
+     * Set database product name.
+     * @param name Database product name. (NotNull)
+     */
+    public static void setDatabaseProductName(String name) {
+        if (_databaseProductName != null) {
+            String msg = "Already set up: current=" + _databaseProductName
+                    + " your=" + name;
+            throw new IllegalStateException(msg);
+        }
+        _databaseProductName = name;
+    }
+
+    // ===================================================================================
+    //                                                                   SqlClause Creator
+    //                                                                   =================
+    /**
+     * Create SQL-clause. {for condition-bean}
+     * @param cb Condition-bean. (NotNull) 
+     * @return SQL-clause. (NotNull)
+     */
+    public static SqlClause createSqlClause(ConditionBean cb) {
+        final String tableSqlName = cb.getTableSqlName();
+        final SqlClause sqlClause = createSqlClause(tableSqlName);
+        if (DBFluteConfig.getInstance().isConditionBeanFormatSql()) {
+            sqlClause.makeFormatClauseEffective();
+        }
+        return sqlClause;
+    }
+
+    /**
+     * Create SQL-clause. {for SimplePagingBean}
+     * @param tableDbName The DB name of table. (NotNull) 
+     * @return SQL-clause. (NotNull)
+     */
+    public static SqlClause createSqlClause(String tableDbName) {
+        final String databaseProductName = getDatabaseProductName();
+        if (databaseProductName == null) {
+            return new SqlClauseMySql(tableDbName);
+        }
+        final String name = databaseProductName.toLowerCase();
+        if (name.equalsIgnoreCase(DB_NAME_DERBY)) {
+            return new SqlClauseDerby(tableDbName);
+        } else if (name.equalsIgnoreCase(DB_NAME_H2)) {
+            return new SqlClauseH2(tableDbName);
+        } else if (name.equalsIgnoreCase(DB_NAME_ORACLE)) {
+            return new SqlClauseOracle(tableDbName);
+        } else if (name.equalsIgnoreCase(DB_NAME_FIREBIRD)) {
+            return new SqlClauseFirebird(tableDbName);
+        } else if (name.equalsIgnoreCase(DB_NAME_MYSQL)) {
+            return new SqlClauseMySql(tableDbName);
+        } else if (name.equalsIgnoreCase(DB_NAME_POSTGRESQL)) {
+            return new SqlClausePostgreSql(tableDbName);
+        } else if (name.equalsIgnoreCase(DB_NAME_MSSQL)) {
+            return new SqlClauseSqlServer(tableDbName);
+        } else if (name.equalsIgnoreCase(DB_NAME_DB2)) {
+            return new SqlClauseDb2(tableDbName);
+        } else {
+            return new SqlClauseMySql(tableDbName);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                  Exception Handling
+    //                                                                  ==================
+    public static void throwEntityAlreadyDeletedException(Object searchKey4Log) {
+        String msg = "Look! Read the message below." + getLineSeparator();
+        msg = msg
+                + "/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *"
+                + getLineSeparator();
+        msg = msg + "The entity was Not Found! it has already been deleted!"
+                + getLineSeparator();
+        msg = msg + getLineSeparator();
+        msg = msg + "[Advice]" + getLineSeparator();
+        msg = msg
+                + "Please confirm the existence of your target record on your database."
+                + getLineSeparator();
+        msg = msg
+                + "Does the target record really created before this operation?"
+                + getLineSeparator();
+        msg = msg + "Has the target record been deleted by other thread?"
+                + getLineSeparator();
+        msg = msg
+                + "It is precondition that the record exists on your database."
+                + getLineSeparator();
+        msg = msg + getLineSeparator();
+        if (searchKey4Log != null && searchKey4Log instanceof ConditionBean) {
+            final ConditionBean cb = (ConditionBean) searchKey4Log;
+            final String dispalySql;
+            if (cb.isFormatSql()) {
+                dispalySql = cb.toDisplaySql();
+            } else {
+                dispalySql = filterDisplaySql(cb.toDisplaySql(), cb
+                        .getTableSqlName());
+            }
+            msg = msg + "[Executed SQL for Display]" + getLineSeparator()
+                    + dispalySql + getLineSeparator();
+        } else {
+            msg = msg + "[Search Condition]" + getLineSeparator()
+                    + searchKey4Log + getLineSeparator();
+        }
+        msg = msg + "* * * * * * * * * */";
+        throw new jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException(
+                msg);
+    }
+
+    public static void throwEntityDuplicatedException(String resultCountString,
+            Object searchKey4Log, Throwable cause) {
+        String msg = "Look! Read the message below." + getLineSeparator();
+        msg = msg
+                + "/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *"
+                + getLineSeparator();
+        msg = msg
+                + "The entity was Too Many! it has been duplicated. It should be the only one! But the resultCount="
+                + resultCountString + getLineSeparator();
+        msg = msg + getLineSeparator();
+        msg = msg + "[Advice]" + getLineSeparator();
+        msg = msg
+                + "Please confirm your search condition. Does it really select the only one?"
+                + getLineSeparator();
+        msg = msg
+                + "Please confirm your database. Does it really exist the only one?"
+                + getLineSeparator();
+        msg = msg + getLineSeparator();
+        if (searchKey4Log != null && searchKey4Log instanceof ConditionBean) {
+            final ConditionBean cb = (ConditionBean) searchKey4Log;
+            final String dispalySql;
+            if (cb.isFormatSql()) {
+                dispalySql = cb.toDisplaySql();
+            } else {
+                dispalySql = filterDisplaySql(cb.toDisplaySql(), cb
+                        .getTableSqlName());
+            }
+            msg = msg + "[Executed SQL for Display]" + getLineSeparator()
+                    + dispalySql + getLineSeparator();
+        } else {
+            msg = msg + "[Search Condition]" + getLineSeparator()
+                    + searchKey4Log + getLineSeparator();
+        }
+        msg = msg + "* * * * * * * * * */";
+        if (cause != null) {
+            throw new jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException(
+                    msg, cause);
+        } else {
+            throw new jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException(
+                    msg);
+        }
+    }
+
+    protected static String filterDisplaySql(String displaySql,
+            String tableDbName) {
+        if (displaySql == null || displaySql.trim().length() == 0) {
+            return null;
+        }
+        if (displaySql.indexOf(getLineSeparator()) >= 0) {
+            return displaySql;
+        }
+        int basePointIndex = displaySql.indexOf(" from " + tableDbName);
+        if (basePointIndex < 0) {
+            return displaySql;
+        }
+        return displaySql.substring(0, basePointIndex) + getLineSeparator()
+                + " " + displaySql.substring(basePointIndex);
+    }
+
+    // ===================================================================================
+    //                                                                         Display SQL
+    //                                                                         ===========
+    public static String convertConditionBean2DisplaySql(ConditionBean cb) {
+        final String twoWaySql;
+        if (cb.isLimitSelect_PKOnly()) {
+            twoWaySql = cb.getSqlClause().getClausePKOnly();
+        } else {
+            twoWaySql = cb.getSqlClause().getClause();
+        }
+        return InternalSqlParser.convertTwoWaySql2DisplaySql(twoWaySql, cb);
+    }
+
+    // ===================================================================================
+    //                                                                              Helper
+    //                                                                              ======
+    /**
+     * Get the value of line separator.
+     * 
+     * @return The value of line separator. (NotNull)
+     */
+    protected static String getLineSeparator() {
+        return System.getProperty("line.separator");
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionBeanContext.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionQuery.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionQuery.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionQuery.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,122 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClause;
+
+/**
+ * The condition-query as interface.
+ * @author DBFlute(AutoGenerator)
+ */
+ @ SuppressWarnings("unchecked")
+public interface ConditionQuery {
+
+    // ===================================================================================
+    //                                                                  Important Accessor
+    //                                                                  ==================
+    /**
+     * Get table DB-name.
+     * @return Table DB-name. (NotNull)
+     */
+    public String getTableDbName();
+
+    /**
+     * Get table SQL-name.
+     * @return Table SQL-name. (NotNull)
+     */
+    public String getTableSqlName();
+
+    /**
+     * Get real alias name(that has nest level mark).
+     * @return Real alias name. (NotNull)
+     */
+    public String getRealAliasName();
+
+    /**
+     * Get real column name(with real alias name).
+     * @param columnName Column name without alias name. (NotNull)
+     * @return Real column name. (NotNull)
+     */
+    public String getRealColumnName(String columnName);
+
+    /**
+     * Get child query.
+     * @return Child query. (Nullable)
+     */
+    public ConditionQuery getChildQuery();
+
+    /**
+     * Get sql clause.
+     * @return Sql clause. (NotNull)
+     */
+    public SqlClause getSqlClause();
+
+    /**
+     * Get alias name.
+     * @return Alias name. (NotNull)
+     */
+    public String getAliasName();
+
+    /**
+     * Get nest level.
+     * @return Nest level.
+     */
+    public int getNestLevel();
+
+    /**
+     * Get next nest level.
+     * @return Next nest level.
+     */
+    public int getNextNestLevel();
+
+    /**
+     * Is base query?
+     * @param query Condition query. (NotNull)
+     * @return Determination.
+     */
+    public boolean isBaseQuery(ConditionQuery query);
+
+    /**
+     * Get the level of subQuery.
+     * @return The level of subQuery.
+     */
+    public int getSubQueryLevel();
+
+    /**
+     * Get the property name of foreign relation.
+     * @return The property name of foreign relation. (NotNull)
+     */
+    public String getForeignPropertyName();
+
+    // ===================================================================================
+    //                                                                              Invoke
+    //                                                                              ======
+    /**
+     * Invoke getting value.
+     * @param columnFlexibleName The flexible name of the column. (NotNull and NotEmpty)
+     * @return The conditionValue. (NotNull)
+     */
+    public ConditionValue invokeValue(String columnFlexibleName);
+
+    /**
+     * Invoke setting query.
+     * @param columnFlexibleName The flexible name of the column. (NotNull and NotEmpty)
+     * @param conditionKeyName The name of the conditionKey. (NotNull)
+     * @param value The value of the condition. (NotNull)
+     */
+    public void invokeQuery(String columnFlexibleName, String conditionKeyName,
+            Object value);
+
+    /**
+     * Invoke adding orderBy.
+     * @param columnFlexibleName The flexible name of the column. (NotNull and NotEmpty)
+     * @param isAsc Is it ascend?
+     */
+    public void invokeOrderBy(String columnFlexibleName, boolean isAsc);
+
+    /**
+     * Invoke getting foreign conditionQuery.
+     * @param foreignPropertyName The property name of the foreign relation. (NotNull and NotEmpty)
+     * @return The conditionQuery of the foreign relation as interface. (NotNull)
+     */
+    public ConditionQuery invokeForeignCQ(String foreignPropertyName);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ConditionQuery.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/FetchNarrowingBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/FetchNarrowingBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/FetchNarrowingBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,61 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+/**
+ * The bean of fetch narrowing.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public interface FetchNarrowingBean {
+
+    /**
+     * Get fetch start index.
+     * 
+     * @return Fetch start index.
+     */
+    public int getFetchNarrowingSkipStartIndex();
+
+    /**
+     * Get fetch size.
+     * 
+     * @return Fetch size.
+     */
+    public int getFetchNarrowingLoopCount();
+
+    /**
+     * Is fetch start index supported?
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchNarrowingSkipStartIndexEffective();
+
+    /**
+     * Is fetch size supported?
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchNarrowingLoopCountEffective();
+
+    /**
+     * Is fetch-narrowing effective?
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchNarrowingEffective();
+
+    /**
+     * Ignore fetch narrowing. Only checking safety result size is valid. {INTERNAL METHOD}
+     */
+    public void ignoreFetchNarrowing();
+
+    /**
+     * Restore ignored fetch narrowing. {INTERNAL METHOD}
+     */
+    public void restoreIgnoredFetchNarrowing();
+
+    /**
+     * Get safety max result size.
+     * 
+     * @return Safety max result size.
+     */
+    public int getSafetyMaxResultSize();
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/FetchNarrowingBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/FetchNarrowingBeanContext.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/FetchNarrowingBeanContext.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/FetchNarrowingBeanContext.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,79 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+/**
+ * Fetch-Narrowing-Bean context. (referring to s2pager)
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class FetchNarrowingBeanContext {
+
+    /** The thread-local for this. */
+    private static ThreadLocal<FetchNarrowingBean> _threadLocal = new ThreadLocal<FetchNarrowingBean>();
+
+    /**
+     * Get fetch-narrowing-bean on thread.
+     * 
+     * @return Condition-bean context. (Nullable)
+     */
+    public static FetchNarrowingBean getFetchNarrowingBeanOnThread() {
+        return (FetchNarrowingBean) _threadLocal.get();
+    }
+
+    /**
+     * Set fetch-narrowing-bean on thread.
+     * 
+     * @param cb Condition-bean. (NotNull)
+     */
+    public static void setFetchNarrowingBeanOnThread(FetchNarrowingBean cb) {
+        if (cb == null) {
+            String msg = "The argument[cb] must not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+        _threadLocal.set(cb);
+    }
+
+    /**
+     * Is existing fetch-narrowing-bean on thread?
+     * 
+     * @return Determination.
+     */
+    public static boolean isExistFetchNarrowingBeanOnThread() {
+        return (_threadLocal.get() != null);
+    }
+
+    /**
+     * Clear fetch-narrowing-bean on thread.
+     */
+    public static void clearFetchNarrowingBeanOnThread() {
+        _threadLocal.set(null);
+    }
+
+    /**
+     * Is the argument fetch-narrowing-bean?
+     * 
+     * @param dtoInstance Dto instance.
+     * @return Determination.
+     */
+    public static boolean isTheArgumentFetchNarrowingBean(
+            final Object dtoInstance) {
+        if (dtoInstance instanceof FetchNarrowingBean) {
+            return true;
+        } else {
+            return false;
+        }
+    }
+
+    /**
+     * Is the type fetch-narrowing-bean?
+     * 
+     * @param dtoClass DtoClass.
+     * @return Determination.
+     */
+    public static boolean isTheTypeFetchNarrowingBean(final Class dtoClass) {
+        if (FetchNarrowingBean.class.isAssignableFrom(dtoClass)) {
+            return true;
+        } else {
+            return false;
+        }
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/FetchNarrowingBeanContext.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ListResultBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ListResultBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ListResultBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,346 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.grouping.GroupingOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.grouping.GroupingRowEndDeterminer;
+import jp.sf.pal.announcement.db.allcommon.cbean.grouping.GroupingRowResource;
+import jp.sf.pal.announcement.db.allcommon.cbean.grouping.GroupingRowSetupper;
+import jp.sf.pal.announcement.db.allcommon.cbean.mapping.EntityDtoMapper;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.OrderByClause;
+
+/**
+ * The list-result-bean for ListResultBean.
+ * @param <ENTITY> The type of entity for the element of selected list.
+ * @author DBFlute(AutoGenerator)
+ */
+public class ListResultBean<ENTITY> implements List<ENTITY>,
+        java.io.Serializable {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Serial version UID. (Default) */
+    private static final long serialVersionUID = 1L;
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** The value of table db-name. */
+    protected String _tableDbName;
+
+    /** The value of all record count. */
+    protected int _allRecordCount;
+
+    /** Selected list. */
+    protected List<ENTITY> _selectedList = new java.util.ArrayList<ENTITY>();
+
+    /** Order-by clause. */
+    protected OrderByClause _orderByClause = new OrderByClause();
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * Constructor.
+     */
+    public ListResultBean() {
+    }
+
+    // ===================================================================================
+    //                                                                            Grouping
+    //                                                                            ========
+    public <ROW> List<ROW> groupingList(
+            GroupingRowSetupper<ROW, ENTITY> groupingRowSetupper,
+            GroupingOption<ENTITY> groupingOption) {
+        final List<ROW> groupingList = new ArrayList<ROW>();
+        GroupingRowEndDeterminer<ENTITY> rowEndDeterminer = groupingOption
+                .getGroupingRowEndDeterminer();
+        if (rowEndDeterminer == null) {
+            rowEndDeterminer = new GroupingRowEndDeterminer<ENTITY>() {
+                public boolean determine(int columnIndex, int columnCount,
+                        GroupingRowResource<ENTITY> rowResource,
+                        ENTITY nextEntity) {
+                    return columnIndex == (columnCount - 1);
+                }
+            };// as Default
+        }
+        GroupingRowResource<ENTITY> rowResource = new GroupingRowResource<ENTITY>();
+        int columnCount = groupingOption.getColumnCount();
+        int columnIndex = 0;
+        int rowIndex = 0;
+        for (ENTITY entity : _selectedList) {
+            // Set up row resource.
+            rowResource.addGroupingRowList(entity);
+
+            if (_selectedList.size() == (rowIndex + 1)) {// Last Loop!
+                // Callback!
+                final ROW groupingRowObject = groupingRowSetupper
+                        .setup(rowResource);
+
+                // Register!
+                groupingList.add(groupingRowObject);
+                break;
+            }
+
+            ENTITY nextElement = null;
+            if (_selectedList.size() > (rowIndex + 1)) {
+                nextElement = _selectedList.get(rowIndex);
+            }
+
+            // Do at row end.
+            if (rowEndDeterminer.determine(columnIndex, columnCount,
+                    rowResource, nextElement)) {
+                // Callback!
+                final ROW groupingRowObject = groupingRowSetupper
+                        .setup(rowResource);
+
+                // Register!
+                groupingList.add(groupingRowObject);
+
+                // Initialize!
+                rowResource = new GroupingRowResource<ENTITY>();
+                columnIndex = 0;
+                ++rowIndex;
+                continue;
+            }
+            ++columnIndex;
+            ++rowIndex;
+        }
+        return groupingList;
+    }
+
+    // ===================================================================================
+    //                                                                             Mapping
+    //                                                                             =======
+    public <DTO> ListResultBean<DTO> mappingList(
+            EntityDtoMapper<ENTITY, DTO> entityDtoMapper) {
+        final ListResultBean<DTO> mappingList = new ListResultBean<DTO>();
+        for (ENTITY entity : _selectedList) {
+            mappingList.add(entityDtoMapper.map(entity));
+        }
+        mappingList.setTableDbName(getTableDbName());
+        mappingList.setAllRecordCount(getAllRecordCount());
+        mappingList.setOrderByClause(getOrderByClause());
+        return mappingList;
+    }
+
+    // ===================================================================================
+    //                                                                       Determination
+    //                                                                       =============
+    /**
+     * Has this result selected?
+     * @return Determination.
+     */
+    public boolean isSelectedResult() {
+        return _tableDbName != null;
+    }
+
+    // ===================================================================================
+    //                                                                      Basic Override
+    //                                                                      ==============
+    /**
+     * @return Hash-code from primary-keys.
+     */
+    public int hashCode() {
+        if (_selectedList == null) {
+            return super.hashCode();
+        }
+        return _selectedList.hashCode();
+    }
+
+    /**
+     * @param other Other entity. (Nullable)
+     * @return Comparing result. If other is null, returns false.
+     */
+    public boolean equals(Object other) {
+        if (_selectedList == null) {
+            return false;
+        }
+        if (other == null) {
+            return false;
+        }
+        if (!(other instanceof List)) {
+            return false;
+        }
+        return _selectedList.equals(other);
+    }
+
+    /**
+     * @return The view string of all attribute values. (NotNull)
+     */
+    @Override
+    public String toString() {
+        final StringBuilder sb = new StringBuilder();
+
+        sb.append(" tableDbName=").append(_tableDbName);
+        sb.append(" allRecordCount=").append(_allRecordCount);
+        sb.append(" selectedList.size()=").append(_selectedList.size());
+        sb.append(" orderByClause=").append(_orderByClause);
+
+        return sb.toString();
+    }
+
+    // ===================================================================================
+    //                                                                       List Elements
+    //                                                                       =============
+    public boolean add(ENTITY o) {
+        return _selectedList.add(o);
+    }
+
+    public boolean addAll(java.util.Collection<? extends ENTITY> c) {
+        return _selectedList.addAll(c);
+    }
+
+    public void clear() {
+        _selectedList.clear();
+    }
+
+    public boolean contains(Object o) {
+        return _selectedList.contains(o);
+    }
+
+    public boolean containsAll(java.util.Collection<?> c) {
+        return _selectedList.containsAll(c);
+    }
+
+    public boolean isEmpty() {
+        return _selectedList.isEmpty();
+    }
+
+    public java.util.Iterator<ENTITY> iterator() {
+        return _selectedList.iterator();
+    }
+
+    public boolean remove(Object o) {
+        return _selectedList.remove(o);
+    }
+
+    public boolean removeAll(java.util.Collection<?> c) {
+        return _selectedList.removeAll(c);
+    }
+
+    public boolean retainAll(java.util.Collection<?> c) {
+        return _selectedList.retainAll(c);
+    }
+
+    public int size() {
+        return _selectedList.size();
+    }
+
+    public Object[] toArray() {
+        return _selectedList.toArray();
+    }
+
+    public <TYPE> TYPE[] toArray(TYPE[] a) {
+        return _selectedList.toArray(a);
+    }
+
+    public void add(int index, ENTITY element) {
+        _selectedList.add(index, element);
+    }
+
+    public boolean addAll(int index, java.util.Collection<? extends ENTITY> c) {
+        return _selectedList.addAll(index, c);
+    }
+
+    public ENTITY get(int index) {
+        return _selectedList.get(index);
+    }
+
+    public int indexOf(Object o) {
+        return _selectedList.indexOf(o);
+    }
+
+    public int lastIndexOf(Object o) {
+        return _selectedList.lastIndexOf(o);
+    }
+
+    public java.util.ListIterator<ENTITY> listIterator() {
+        return _selectedList.listIterator();
+    }
+
+    public java.util.ListIterator<ENTITY> listIterator(int index) {
+        return _selectedList.listIterator(index);
+    }
+
+    public ENTITY remove(int index) {
+        return _selectedList.remove(index);
+    }
+
+    public ENTITY set(int index, ENTITY element) {
+        return _selectedList.set(index, element);
+    }
+
+    public java.util.List<ENTITY> subList(int fromIndex, int toIndex) {
+        return _selectedList.subList(fromIndex, toIndex);
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    /**
+     * Get the value of tableDbName.
+     * @return The value of tableDbName. (Nullable: If it's null, it means 'Not Selected Yet'.)
+     */
+    public String getTableDbName() {
+        return _tableDbName;
+    }
+
+    /**
+     * Set the value of tableDbName.
+     * @param tableDbName The value of tableDbName. (NotNull)
+     */
+    public void setTableDbName(String tableDbName) {
+        _tableDbName = tableDbName;
+    }
+
+    /**
+     * Get the value of allRecordCount.
+     * @return The value of allRecordCount.
+     */
+    public int getAllRecordCount() {
+        return _allRecordCount;
+    }
+
+    /**
+     * Set the value of allRecordCount.
+     * @param allRecordCount The value of allRecordCount.
+     */
+    public void setAllRecordCount(int allRecordCount) {
+        _allRecordCount = allRecordCount;
+    }
+
+    /**
+     * Get the value of selectedList.
+     * @return Selected list. (Nullable: If it's null, it means 'Not Selected Yet'.)
+     */
+    public List<ENTITY> getSelectedList() {
+        return _selectedList;
+    }
+
+    /**
+     * Set the value of selectedList.
+     * @param selectedList Selected list. (NotNull)
+     */
+    public void setSelectedList(List<ENTITY> selectedList) {
+        _selectedList = selectedList;
+    }
+
+    /**
+     * Get the value of orderByClause.
+     * @return The value of orderByClause. (Nullable: If it's null, it means 'Not Selected Yet'.)
+     */
+    public OrderByClause getOrderByClause() {
+        return _orderByClause;
+    }
+
+    /**
+     * Set the value of orderByClause.
+     * @param orderByClause The value of orderByClause. (NotNull)
+     */
+    public void setOrderByClause(OrderByClause orderByClause) {
+        _orderByClause = orderByClause;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ListResultBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/MapParameterBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/MapParameterBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/MapParameterBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,16 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import java.util.Map;
+
+/**
+ * The bean of map parameter.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface MapParameterBean {
+
+    /**
+     * Get the map of parameter.
+     * @return The map of parameter. (Nullable)
+     */
+    public Map<String, Object> getParameterMap();
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/MapParameterBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/OrderByBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/OrderByBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/OrderByBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,46 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.OrderByClause;
+
+/**
+ * The order-by-bean as interface.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public interface OrderByBean extends SelectResource {
+
+    /**
+     * Get sql component of order-by clause.
+     * 
+     * @return Sql component of order-by clause. (NotNull)
+     */
+    public OrderByClause getSqlComponentOfOrderByClause();
+
+    /**
+     * Get order-by clause.
+     * 
+     * @return Order-by clause. (NotNull)
+     */
+    public String getOrderByClause();
+
+    /**
+     * Clear order-by.
+     * 
+     * @return this. (NotNull)
+     */
+    public OrderByBean clearOrderBy();
+
+    /**
+     * Ignore order-by.
+     * 
+     * @return this. (NotNull)
+     */
+    public OrderByBean ignoreOrderBy();
+
+    /**
+     * Make order-by effective.
+     * 
+     * @return this. (NotNull)
+     */
+    public OrderByBean makeOrderByEffective();
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/OrderByBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,134 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+/**
+ * The bean of paging.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public interface PagingBean extends FetchNarrowingBean, OrderByBean {
+
+    // ===================================================================================
+    //                                                                Paging Determination
+    //                                                                ====================
+    // * * * * * * * *
+    // For SQL Comment
+    // * * * * * * * *
+    /**
+     * Is the execution for paging(NOT count)?
+     * 
+     * @return Determination.
+     */
+    public boolean isPaging();
+
+    /**
+     * Set whether the execution for paging(NOT count). {INTERNAL METHOD}
+     * 
+     * @param paging Determination.
+     */
+    public void xsetPaging(boolean paging);
+
+    // ===================================================================================
+    //                                                                       Fetch Setting
+    //                                                                       =============
+    /**
+     * Fetch first. <br />
+     * If you invoke this, your SQL returns [fetch-size] records from first. <br />
+     * 
+     * @param fetchSize The size of fetch. (NotMinus & NotZero)
+     * @return this. (NotNull)
+     */
+    public PagingBean fetchFirst(int fetchSize);
+
+    /**
+     * Fetch scope. <br />
+     * If you invoke this, your SQL returns [fetch-size] records from [fetch-start-index]. <br />
+     * 
+     * @param fetchStartIndex The start index of fetch. 0 origin. (NotMinus)
+     * @param fetchSize The size of fetch. (NotMinus & NotZero)
+     * @return this. (NotNull)
+     */
+    public PagingBean fetchScope(int fetchStartIndex, int fetchSize);
+
+    /**
+     * Fetch page. <br />
+     * When you invoke this, it is normally necessary to invoke 'fetchFirst()' or 'fetchScope()' ahead of that. <br />
+     * But you also can use default-fetch-size without invoking 'fetchFirst()' or 'fetchScope()'. <br />
+     * If you invoke this, your SQL returns [fetch-size] records from [fetch-start-index] calculated by [fetch-page-number]. <br />
+     * 
+     * @param fetchPageNumber The page number of fetch. 1 origin. (NotMinus & NotZero: If minus or zero, set one.)
+     * @return this. (NotNull)
+     */
+    public PagingBean fetchPage(int fetchPageNumber);
+
+    // ===================================================================================
+    //                                                                      Fetch Property
+    //                                                                      ==============
+    /**
+     * Get fetch-start-index.
+     * 
+     * @return Fetch-start-index.
+     */
+    public int getFetchStartIndex();
+
+    /**
+     * Get fetch-size.
+     * 
+     * @return Fetch-size.
+     */
+    public int getFetchSize();
+
+    /**
+     * Get fetch-page-number.
+     * 
+     * @return Fetch-page-number.
+     */
+    public int getFetchPageNumber();
+
+    /**
+     * Get page start index.
+     * 
+     * @return Page start index. 0 origin. (NotMinus)
+     */
+    public int getPageStartIndex();
+
+    /**
+     * Get page end index.
+     * 
+     * @return Page end index. 0 origin. (NotMinus)
+     */
+    public int getPageEndIndex();
+
+    /**
+     * Is fetch scope effective?
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchScopeEffective();
+
+    // ===================================================================================
+    //                                                                       Hint Property
+    //                                                                       =============
+    // * * * * * * * *
+    // For SQL Comment
+    // * * * * * * * *
+    /**
+     * Get select-hint. {select [select-hint] * from table...}
+     * 
+     * @return Select-hint. (NotNull)
+     */
+    public String getSelectHint();
+
+    /**
+     * Get from-hint. {select * from table [from-hint] where ...}
+     * 
+     * @return From-hint. (NotNull)
+     */
+    public String getFromHint();
+
+    /**
+     * Get sql-suffix. {select * from table where ... order by ... [sql-suffix]}
+     * 
+     * @return Sql-suffix. (NotNull)
+     */
+    public String getSqlSuffix();
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingHandler.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingHandler.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingHandler.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,31 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+/**
+ * The handler of paging.
+ * 
+ * @param <ENTITY> The type of entity.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface PagingHandler<ENTITY> {
+
+    /**
+     * Get the bean of paging.
+     * 
+     * @return The bean of paging. (NotNull)
+     */
+    public PagingBean getPagingBean();
+
+    /**
+     * Execute SQL for count.
+     * 
+     * @return The count of execution.
+     */
+    public int count();
+
+    /**
+     * Execute SQL for paging.
+     * 
+     * @return The list of entity. (NotNull)
+     */
+    public java.util.List<ENTITY> paging();
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingHandler.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingInvoker.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingInvoker.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingInvoker.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,91 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+/**
+ * The invoker of paging.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class PagingInvoker<ENTITY> {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected String _tableDbName;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    public PagingInvoker(String tableDbName) {
+        _tableDbName = tableDbName;
+    }
+
+    // ===================================================================================
+    //                                                                              Invoke
+    //                                                                              ======
+    /**
+     * Invoke select-page by handler.
+     * 
+     * @param handler The handler of paging. (NotNull)
+     * @return The result bean of paging. (NotNull)
+     */
+    public PagingResultBean<ENTITY> invokePaging(PagingHandler<ENTITY> handler) {
+        assertObjectNotNull("handler", handler);
+        final PagingBean pagingBean = handler.getPagingBean();
+        assertObjectNotNull("handler.getPagingBean()", pagingBean);
+        if (!pagingBean.isFetchScopeEffective()) {
+            String msg = "The paging bean is not effective about fetch-scope!";
+            msg = msg
+                    + " When you select page, you should set up fetch-scope of paging bean(Should invoke fetchFirst() and fetchPage()!).";
+            msg = msg + " The paging bean is: " + pagingBean;
+            throw new IllegalStateException(msg);
+        }
+        final int allRecordCount = handler.count();
+        final java.util.List<ENTITY> selectedList = handler.paging();
+        final PagingResultBean<ENTITY> rb = new ResultBeanBuilder<ENTITY>(
+                _tableDbName).buildPagingResultBean(pagingBean, allRecordCount,
+                selectedList);
+        if (isNecessaryToReadPageAgain(rb)) {
+            pagingBean.fetchPage(rb.getAllPageCount());
+            final int reAllRecordCount = handler.count();
+            final java.util.List<ENTITY> reSelectedList = handler.paging();
+            return new ResultBeanBuilder<ENTITY>(_tableDbName)
+                    .buildPagingResultBean(pagingBean, reAllRecordCount,
+                            reSelectedList);
+        } else {
+            return rb;
+        }
+    }
+
+    /**
+     * Is it necessary to read page again?
+     * 
+     * @param rb The result bean of paging. (NotNull)
+     * @return Determination.
+     */
+    protected boolean isNecessaryToReadPageAgain(PagingResultBean<ENTITY> rb) {
+        return rb.getAllRecordCount() > 0 && rb.getSelectedList().isEmpty();
+    }
+
+    // ===================================================================================
+    //                                                                              Helper
+    //                                                                              ======
+    /**
+     * Assert that the object is not null.
+     * 
+     * @param variableName Variable name. (NotNull)
+     * @param value Value. (NotNull)
+     * @exception IllegalArgumentException
+     */
+    protected void assertObjectNotNull(String variableName, Object value) {
+        if (variableName == null) {
+            String msg = "The value should not be null: variableName="
+                    + variableName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+        if (value == null) {
+            String msg = "The value should not be null: variableName="
+                    + variableName;
+            throw new IllegalArgumentException(msg);
+        }
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingInvoker.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingResultBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingResultBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingResultBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,338 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.mapping.EntityDtoMapper;
+import jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.group.PageGroupBean;
+import jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.group.PageGroupOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.range.PageRangeBean;
+import jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.range.PageRangeOption;
+
+/**
+ * The paging-result-bean for specified entity.
+ * @param <ENTITY> The type of entity for the element of selected list.
+ * @author DBFlute(AutoGenerator)
+ */
+public class PagingResultBean<ENTITY> extends ListResultBean<ENTITY> {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Serial version UID. (Default) */
+    private static final long serialVersionUID = 1L;
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    // -----------------------------------------------------
+    //                                       Page Basic Info
+    //                                       ---------------
+    /** The value of current page number. */
+    protected int _pageSize;
+
+    /** The value of current page number. */
+    protected int _currentPageNumber;
+
+    // -----------------------------------------------------
+    //                                            Page Group
+    //                                            ----------
+    /** The value of page-group bean. */
+    protected PageGroupBean _pageGroupBean;
+
+    /** The value of page-group option. */
+    protected PageGroupOption _pageGroupOption;
+
+    // -----------------------------------------------------
+    //                                            Page Range
+    //                                            ----------
+    /** The value of page-range bean. */
+    protected PageRangeBean _pageRangeBean;
+
+    /** The value of page-range option. */
+    protected PageRangeOption _pageRangeOption;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * Constructor.
+     */
+    public PagingResultBean() {
+    }
+
+    // ===================================================================================
+    //                                                                 Calculated Property
+    //                                                                 ===================
+    /**
+     * Get the value of allPageCount that is calculated.
+     * @return The value of allPageCount.
+     */
+    public int getAllPageCount() {
+        return calculateAllPageCount(_allRecordCount, _pageSize);
+    }
+
+    /**
+     * Get the value of currentStartRecordNumber that is calculated.
+     * @return The value of currentStartRecordNumber.
+     */
+    public int getCurrentStartRecordNumber() {
+        return calculateCurrentStartRecordNumber(_currentPageNumber, _pageSize);
+    }
+
+    /**
+     * Get the value of currentEndRecordNumber that is calculated.
+     * @return The value of currentEndRecordNumber.
+     */
+    public int getCurrentEndRecordNumber() {
+        return calculateCurrentEndRecordNumber(_currentPageNumber, _pageSize);
+    }
+
+    // ===================================================================================
+    //                                                                    Page Group/Range
+    //                                                                    ================
+    // -----------------------------------------------------
+    //                                            Page Group
+    //                                            ----------
+    /**
+     * Get the value of pageGroupSize.
+     * @return The value of pageGroupSize.
+     */
+    public int getPageGroupSize() {
+        return _pageGroupOption != null ? _pageGroupOption.getPageGroupSize()
+                : 0;
+    }
+
+    /**
+     * Set the value of pageGroupSize.
+     * @param pageGroupSize The value of pageGroupSize.
+     */
+    public void setPageGroupSize(int pageGroupSize) {
+        final PageGroupOption option = new PageGroupOption();
+        option.setPageGroupSize(pageGroupSize);
+        setPageGroupOption(option);
+    }
+
+    /**
+     * Set the value of pageGroupOption.
+     * @param pageGroupOption The value of pageGroupOption. (Nullable)
+     */
+    public void setPageGroupOption(PageGroupOption pageGroupOption) {
+        _pageGroupOption = pageGroupOption;
+    }
+
+    /**
+     * Get the value of pageGroupBean.
+     * @return The value of pageGroupBean. (NotNull)
+     */
+    public PageGroupBean pageGroup() {
+        assertPageGroupValid();
+        if (_pageGroupBean == null) {
+            _pageGroupBean = new PageGroupBean();
+        }
+        _pageGroupBean.setPageGroupOption(_pageGroupOption);
+        _pageGroupBean.setCurrentPageNumber(getCurrentPageNumber());
+        _pageGroupBean.setAllPageCount(getAllPageCount());
+        return _pageGroupBean;
+    }
+
+    protected void assertPageGroupValid() {
+        if (_pageGroupOption == null) {
+            String msg = "The pageGroupOption should not be null. Please invoke setPageGroupOption().";
+            throw new IllegalStateException(msg);
+        }
+        if (_pageGroupOption.getPageGroupSize() == 0) {
+            String msg = "The pageGroupSize should be greater than 1. But the value is zero.";
+            msg = msg + " pageGroupSize=" + _pageGroupOption.getPageGroupSize();
+            throw new IllegalStateException(msg);
+        }
+        if (_pageGroupOption.getPageGroupSize() == 1) {
+            String msg = "The pageGroupSize should be greater than 1. But the value is one.";
+            msg = msg + " pageGroupSize=" + _pageGroupOption.getPageGroupSize();
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    // -----------------------------------------------------
+    //                                            Page Range
+    //                                            ----------
+    /**
+     * Get the value of pageRangeSize.
+     * @return The value of pageRangeSize.
+     */
+    public int getPageRangeSize() {
+        return _pageRangeOption != null ? _pageRangeOption.getPageRangeSize()
+                : 0;
+    }
+
+    /**
+     * Set the value of pageRangeSize.
+     * @param pageRangeSize The value of pageRangeSize.
+     */
+    public void setPageRangeSize(int pageRangeSize) {
+        final PageRangeOption option = new PageRangeOption();
+        option.setPageRangeSize(pageRangeSize);
+        setPageRangeOption(option);
+    }
+
+    /**
+     * Set the value of pageRangeOption.
+     * @param pageRangeOption The value of pageRangeOption. (Nullable)
+     */
+    public void setPageRangeOption(PageRangeOption pageRangeOption) {
+        this._pageRangeOption = pageRangeOption;
+    }
+
+    /**
+     * Get the value of pageRangeBean.
+     * @return The value of pageRangeBean. (NotNull)
+     */
+    public PageRangeBean pageRange() {
+        assertPageRangeValid();
+        if (_pageRangeBean == null) {
+            _pageRangeBean = new PageRangeBean();
+        }
+        _pageRangeBean.setPageRangeOption(_pageRangeOption);
+        _pageRangeBean.setCurrentPageNumber(getCurrentPageNumber());
+        _pageRangeBean.setAllPageCount(getAllPageCount());
+        return _pageRangeBean;
+    }
+
+    protected void assertPageRangeValid() {
+        if (_pageRangeOption == null) {
+            String msg = "The pageRangeOption should not be null. Please invoke setPageRangeOption().";
+            throw new IllegalStateException(msg);
+        }
+        final int pageRangeSize = _pageRangeOption.getPageRangeSize();
+        if (pageRangeSize == 0) {
+            String msg = "The pageRangeSize should be greater than 1. But the value is zero.";
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                       Determination
+    //                                                                       =============
+    /**
+     * Is existing previous page?
+     * Using values are currentPageNumber.
+     * @return Determination.
+     */
+    public boolean isExistPrePage() {
+        return (_allRecordCount > 0 && _currentPageNumber > 1);
+    }
+
+    /**
+     * Is existing next page?
+     * Using values are currentPageNumber and allPageCount.
+     * @return Determination.
+     */
+    public boolean isExistNextPage() {
+        return (_allRecordCount > 0 && _currentPageNumber < getAllPageCount());
+    }
+
+    // ===================================================================================
+    //                                                                             Mapping
+    //                                                                             =======
+    public <DTO> PagingResultBean<DTO> mappingList(
+            EntityDtoMapper<ENTITY, DTO> entityDtoMapper) {
+        final ListResultBean<DTO> ls = super.mappingList(entityDtoMapper);
+        final PagingResultBean<DTO> mappingList = new PagingResultBean<DTO>();
+        mappingList.setSelectedList(ls.getSelectedList());
+        mappingList.setTableDbName(getTableDbName());
+        mappingList.setAllRecordCount(getAllRecordCount());
+        mappingList.setOrderByClause(getOrderByClause());
+        mappingList.setPageSize(getPageSize());
+        mappingList.setCurrentPageNumber(getCurrentPageNumber());
+        mappingList.setPageRangeOption(_pageRangeOption);
+        mappingList.setPageGroupOption(_pageGroupOption);
+        return mappingList;
+    }
+
+    // ===================================================================================
+    //                                                                 Calculate(Internal)
+    //                                                                 ===================
+    /**
+     * Calculate all page count.
+     * @param allRecordCount All record count.
+     * @param pageSize Fetch-size.
+     * @return All page count.
+     */
+    protected int calculateAllPageCount(int allRecordCount, int pageSize) {
+        if (allRecordCount == 0) {
+            return 1;
+        }
+        int pageCountBase = (allRecordCount / pageSize);
+        if (allRecordCount % pageSize > 0) {
+            pageCountBase++;
+        }
+        return pageCountBase;
+    }
+
+    protected int calculateCurrentStartRecordNumber(int currentPageNumber,
+            int pageSize) {
+        return ((currentPageNumber - 1) * pageSize) + 1;
+    }
+
+    protected int calculateCurrentEndRecordNumber(int currentPageNumber,
+            int pageSize) {
+        return calculateCurrentStartRecordNumber(currentPageNumber, pageSize)
+                + _selectedList.size() - 1;
+    }
+
+    // ===================================================================================
+    //                                                                      Basic Override
+    //                                                                      ==============
+    /**
+     * @return The view string of all attribute values. (NotNull)
+     */
+    @Override
+    public String toString() {
+        final StringBuilder sb = new StringBuilder();
+
+        sb.append(getCurrentPageNumber()).append("/").append(getAllPageCount());
+        sb.append(" of ").append(getAllRecordCount());
+        sb.append(" listSize=").append(
+                getSelectedList() != null ? new Integer(getSelectedList()
+                        .size()) : null);
+        sb.append(" pageSize=").append(getPageSize());
+        sb.append(" page:{").append(isExistPrePage()).append("/").append(
+                isExistNextPage()).append("}");
+        sb.append(" groupSize=").append(getPageGroupSize());
+        sb.append(" rangeSize=").append(getPageRangeSize());
+
+        return sb.toString();
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    /**
+     * Get the value of pageSize.
+     * @return The value of pageSize.
+     */
+    public int getPageSize() {
+        return _pageSize;
+    }
+
+    /**
+     * Set the value of pageSize.
+     * @param pageSize The value of pageSize.
+     */
+    public void setPageSize(int pageSize) {
+        _pageSize = pageSize;
+    }
+
+    /**
+     * Get the value of currentPageNumber.
+     * @return The value of currentPageNumber.
+     */
+    public int getCurrentPageNumber() {
+        return _currentPageNumber;
+    }
+
+    /**
+     * Set the value of currentPageNumber.
+     * @param currentPageNumber The value of currentPageNumber.
+     */
+    public void setCurrentPageNumber(int currentPageNumber) {
+        _currentPageNumber = currentPageNumber;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/PagingResultBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ResultBeanBuilder.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ResultBeanBuilder.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ResultBeanBuilder.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,64 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import java.util.List;
+
+/**
+ * The list-result-bean for ${myClassName}.
+ * 
+ * @param <ENTITY> The type of entity.
+ * @author DBFlute(AutoGenerator)
+ */
+public class ResultBeanBuilder<ENTITY> {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected String _tableDbName;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    public ResultBeanBuilder(String tableDbName) {
+        _tableDbName = tableDbName;
+    }
+
+    // ===================================================================================
+    //                                                                             Builder
+    //                                                                             =======
+    /**
+     * Build the result bean of list.
+     * 
+     * @param ob The bean of orderBy. (NotNull)
+     * @param selectedList Selected list. (NotNull)
+     * @return The result bean of list. (NotNull)
+     */
+    public ListResultBean<ENTITY> buildListResultBean(ConditionBean ob,
+            List<ENTITY> selectedList) {
+        ListResultBean<ENTITY> rb = new ListResultBean<ENTITY>();
+        rb.setTableDbName(_tableDbName);
+        rb.setAllRecordCount(selectedList.size());
+        rb.setSelectedList(selectedList);
+        rb.setOrderByClause(ob.getSqlComponentOfOrderByClause());
+        return rb;
+    }
+
+    /**
+     * Build the result bean of paging.
+     * 
+     * @param pb The bean of paging. (NotNull)
+     * @param allRecordCount All record count.
+     * @param selectedList The list of selected entity. (NotNull)
+     * @return The result bean of paging. (NotNull)
+     */
+    public PagingResultBean<ENTITY> buildPagingResultBean(PagingBean pb,
+            int allRecordCount, List<ENTITY> selectedList) {
+        PagingResultBean<ENTITY> rb = new PagingResultBean<ENTITY>();
+        rb.setTableDbName(_tableDbName);
+        rb.setAllRecordCount(allRecordCount);
+        rb.setSelectedList(selectedList);
+        rb.setOrderByClause(pb.getSqlComponentOfOrderByClause());
+        rb.setPageSize(pb.getFetchSize());
+        rb.setCurrentPageNumber(pb.getFetchPageNumber());
+        return rb;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ResultBeanBuilder.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SelectResource.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SelectResource.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SelectResource.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,16 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+/**
+ * The select-resource as marker-interface.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public interface SelectResource {
+
+    /**
+     * Check safety result.
+     * 
+     * @param safetyMaxResultSize Safety max result size. (If zero or minus, ignore checking)
+     */
+    public void checkSafetyResult(int safetyMaxResultSize);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SelectResource.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SimpleOrderByBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SimpleOrderByBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SimpleOrderByBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,155 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.OrderByClause;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClause;
+
+/**
+ * @deprecated
+ */
+public class SimpleOrderByBean implements OrderByBean {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** SQL clause instance. */
+    protected final SqlClause _sqlClause;
+    {
+        _sqlClause = ConditionBeanContext.createSqlClause("Dummy");
+    }
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * Constructor.
+     */
+    public SimpleOrderByBean() {
+    }
+
+    // ===================================================================================
+    //                                                                           SqlClause
+    //                                                                           =========
+    /**
+     * Get sql-clause.
+     * 
+     * @return Sql clause. (NotNull)
+     */
+    protected SqlClause getSqlClause() {
+        return _sqlClause;
+    }
+
+    // ===================================================================================
+    //                                                                     Select Resource
+    //                                                                     ===============
+    /**
+     * Check safety result.
+     * 
+     * @param safetyMaxResultSize Safety max result size. (If zero or minus, ignore checking)
+     */
+    public void checkSafetyResult(int safetyMaxResultSize) {
+        throw new UnsupportedOperationException();
+    }
+
+    // ===================================================================================
+    //                                                                             OrderBy
+    //                                                                             =======
+    /**
+     * The implementation.
+     * 
+     * @return Sql component of order-by clause. (NotNull)
+     */
+    public OrderByClause getSqlComponentOfOrderByClause() {
+        return getSqlClause().getSqlComponentOfOrderByClause();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Order-by clause. (NotNull)
+     */
+    public String getOrderByClause() {
+        return getSqlClause().getOrderByClause();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public OrderByBean clearOrderBy() {
+        getSqlClause().clearOrderBy();
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public OrderByBean ignoreOrderBy() {
+        getSqlClause().ignoreOrderBy();
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public OrderByBean makeOrderByEffective() {
+        getSqlClause().makeOrderByEffective();
+        return this;
+    }
+
+    /**
+     * Register order-by-asc.
+     * 
+     * @param orderByProperty Order-by-property. 'aliasName.columnName/aliasName.columnName/...' (NotNull)
+     * @return this. (NotNull)
+     * @deprecated
+     */
+    public OrderByBean registerOrderByAsc(String orderByProperty) {
+        getSqlClause().registerOrderBy(orderByProperty, orderByProperty, true);
+        return this;
+    }
+
+    /**
+     * Register order-by-desc.
+     * 
+     * @param orderByProperty Order-by-property. 'aliasName.columnName/aliasName.columnName/...' (NotNull)
+     * @return this. (NotNull)
+     * @deprecated
+     */
+    public OrderByBean registerOrderByDesc(String orderByProperty) {
+        getSqlClause().registerOrderBy(orderByProperty, orderByProperty, false);
+        return this;
+    }
+
+    /**
+     * Reverse order-by or Override order-by asc.
+     * 
+     * @param orderByProperty Order-by-property. 'aliasName.columnName/aliasName.columnName/...' (NotNull)
+     * @return this. (NotNull)
+     * @deprecated
+     */
+    public OrderByBean reverseOrderBy_Or_OverrideOrderByAsc(
+            String orderByProperty) {
+        getSqlClause().reverseOrderBy_Or_OverrideOrderBy(orderByProperty,
+                orderByProperty, true);
+        return this;
+    }
+
+    /**
+     * Reverse order-by or Override order-by desc.
+     * 
+     * @param orderByProperty Order-by-property. 'aliasName.columnName/aliasName.columnName/...' (NotNull)
+     * @return this. (NotNull)
+     * @deprecated
+     */
+    public OrderByBean reverseOrderBy_Or_OverrideOrderByDesc(
+            String orderByProperty) {
+        getSqlClause().reverseOrderBy_Or_OverrideOrderBy(orderByProperty,
+                orderByProperty, false);
+        return this;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SimpleOrderByBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SimplePagingBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SimplePagingBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SimplePagingBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,386 @@
+package jp.sf.pal.announcement.db.allcommon.cbean;
+
+import java.util.LinkedHashMap;
+import java.util.Map;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.OrderByClause;
+import jp.sf.pal.announcement.db.allcommon.cbean.sqlclause.SqlClause;
+
+/**
+ * The simple pagingBean.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class SimplePagingBean implements PagingBean, MapParameterBean {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** SQL clause instance. */
+    protected final SqlClause _sqlClause;
+    {
+        _sqlClause = ConditionBeanContext.createSqlClause("Dummy");
+    }
+
+    /** The map of parameter. (Nullable) */
+    protected Map<String, Object> _parameterMap;
+
+    /** Safety max result size. */
+    protected int _safetyMaxResultSize;
+
+    /** Is the execution for paging(NOT count)? */
+    protected boolean _paging = true;
+
+    /** Is fetch narrowing valid? */
+    protected boolean _fetchNarrowing = true;
+
+    /** The map for parameter. */
+    protected Map<String, Object> _map;
+
+    // ===================================================================================
+    //                                                        Implementation of PagingBean
+    //                                                        ============================
+    // -----------------------------------------------------
+    //                                  Paging Determination
+    //                                  --------------------
+    // * * * * * * * *
+    // For SQL Comment
+    // * * * * * * * *
+    /**
+     * The implementation.
+     * 
+     * @return Determination.
+     */
+    public boolean isPaging() {
+        return _paging;
+    }
+
+    /**
+     * The implementation. {INTERNAL METHOD: Don't Invoke This!}
+     * 
+     * @param paging Determination.
+     */
+    public void xsetPaging(boolean paging) {
+        if (paging) {
+            getSqlClause().makeFetchScopeEffective();
+        } else {
+            getSqlClause().ignoreFetchScope();
+        }
+        this._paging = paging;
+    }
+
+    // -----------------------------------------------------
+    //                                         Fetch Setting
+    //                                         -------------
+    /**
+     * Fetch first.
+     * <pre>
+     * If you invoke this, your SQL returns [fetch-size] records from first.
+     * </pre>
+     * @param fetchSize Fetch-size. (NotMinus & NotZero)
+     * @return this. (NotNull)
+     */
+    public PagingBean fetchFirst(int fetchSize) {
+        getSqlClause().fetchFirst(fetchSize);
+        return this;
+    }
+
+    /**
+     * Fetch scope.
+     * <pre>
+     * If you invoke this, your SQL returns [fetch-size] records from [fetch-start-index].
+     * </pre>
+     * @param fetchStartIndex Fetch-start-index. 0 origin. (NotMinus)
+     * @param fetchSize Fetch-size. (NotMinus & NotZero)
+     * @return this. (NotNull)
+     */
+    public PagingBean fetchScope(int fetchStartIndex, int fetchSize) {
+        getSqlClause().fetchScope(fetchStartIndex, fetchSize);
+        return this;
+    }
+
+    /**
+     * Fetch page.
+     * <pre>
+     * When you invoke this, it is normally necessary to invoke 'fetchFirst()' or 'fetchScope()' ahead of that.
+     *  But you also can use default-fetch-size without invoking 'fetchFirst()' or 'fetchScope()'.
+     *  If you invoke this, your SQL returns [fetch-size] records from [fetch-start-index] calculated by [fetch-page-number].
+     * </pre>
+     * @param fetchPageNumber Fetch-page-number. 1 origin. (NotMinus & NotZero: If minus or zero, set one.)
+     * @return this. (NotNull)
+     */
+    public PagingBean fetchPage(int fetchPageNumber) {
+        getSqlClause().fetchPage(fetchPageNumber);
+        return this;
+    }
+
+    // -----------------------------------------------------
+    //                                        Fetch Property
+    //                                        --------------
+    /**
+     * The implementation.
+     * 
+     * @return Fetch-start-index.
+     */
+    public int getFetchStartIndex() {
+        return getSqlClause().getFetchStartIndex();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Fetch-size.
+     */
+    public int getFetchSize() {
+        return getSqlClause().getFetchSize();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Fetch-page-number.
+     */
+    public int getFetchPageNumber() {
+        return getSqlClause().getFetchPageNumber();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Page start index. 0 origin. (NotMinus)
+     */
+    public int getPageStartIndex() {
+        return getSqlClause().getPageStartIndex();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Page end index. 0 origin. (NotMinus)
+     */
+    public int getPageEndIndex() {
+        return getSqlClause().getPageEndIndex();
+    }
+
+    /**
+     * Is fetch scope effective?
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchScopeEffective() {
+        return getSqlClause().isFetchScopeEffective();
+    }
+
+    // -----------------------------------------------------
+    //                                         Hint Property
+    //                                         -------------
+    /**
+     * Get select-hint. {select [select-hint] * from table...}
+     * 
+     * @return Select-hint. (NotNull)
+     */
+    public String getSelectHint() {
+        return getSqlClause().getSelectHint();
+    }
+
+    /**
+     * Get from-base-table-hint. {select * from table [from-base-table-hint] where ...}
+     * 
+     * @return from-base-table-hint. (NotNull)
+     */
+    public String getFromBaseTableHint() {
+        return getSqlClause().getFromBaseTableHint();
+    }
+
+    /**
+     * Get from-hint. {select * from table [from-hint] where ...}
+     * 
+     * @return From-hint. (NotNull)
+     */
+    public String getFromHint() {
+        return getSqlClause().getFromHint();
+    }
+
+    /**
+     * Get sql-suffix. {select * from table where ... order by ... [sql-suffix]}
+     * 
+     * @return Sql-suffix. (NotNull)
+     */
+    public String getSqlSuffix() {
+        return getSqlClause().getSqlSuffix();
+    }
+
+    // ===================================================================================
+    //                                                Implementation of FetchNarrowingBean
+    //                                                ====================================
+    /**
+     * Get fetch-narrowing start-index.
+     * 
+     * @return Fetch-narrowing start-index.
+     */
+    public int getFetchNarrowingSkipStartIndex() {
+        return getSqlClause().getFetchNarrowingSkipStartIndex();
+    }
+
+    /**
+     * Get fetch-narrowing size.
+     * 
+     * @return Fetch-narrowing size.
+     */
+    public int getFetchNarrowingLoopCount() {
+        return getSqlClause().getFetchNarrowingLoopCount();
+    }
+
+    /**
+     * Is fetch start index supported?
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchNarrowingSkipStartIndexEffective() {
+        return !getSqlClause().isFetchStartIndexSupported();
+    }
+
+    /**
+     * Is fetch size supported?
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchNarrowingLoopCountEffective() {
+        return !getSqlClause().isFetchSizeSupported();
+    }
+
+    /**
+     * Is fetch-narrowing effective?
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchNarrowingEffective() {
+        return _fetchNarrowing && getSqlClause().isFetchNarrowingEffective();
+    }
+
+    /**
+     * Ignore fetch narrowing. Only checking safety result size is valid. {INTERNAL METHOD}
+     */
+    public void ignoreFetchNarrowing() {
+        _fetchNarrowing = false;
+    }
+
+    /**
+     * Restore ignored fetch narrowing. {INTERNAL METHOD}
+     */
+    public void restoreIgnoredFetchNarrowing() {
+        _fetchNarrowing = true;
+    }
+
+    /**
+     * Get safety max result size.
+     * 
+     * @return Safety max result size.
+     */
+    public int getSafetyMaxResultSize() {
+        return _safetyMaxResultSize;
+    }
+
+    // ===================================================================================
+    //                                                       Implementation of OrderByBean
+    //                                                       =============================
+    /**
+     * The implementation.
+     * 
+     * @return Sql component of order-by clause. (NotNull)
+     */
+    public OrderByClause getSqlComponentOfOrderByClause() {
+        return getSqlClause().getSqlComponentOfOrderByClause();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Order-by clause. (NotNull)
+     */
+    public String getOrderByClause() {
+        return getSqlClause().getOrderByClause();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public OrderByBean clearOrderBy() {
+        getSqlClause().clearOrderBy();
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public OrderByBean ignoreOrderBy() {
+        getSqlClause().ignoreOrderBy();
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public OrderByBean makeOrderByEffective() {
+        getSqlClause().makeOrderByEffective();
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                    Implementation of SelectResource
+    //                                                    ================================
+    /**
+     * Check safety result.
+     * 
+     * @param safetyMaxResultSize Safety max result size. (If zero or minus, ignore checking)
+     */
+    public void checkSafetyResult(int safetyMaxResultSize) {
+        this._safetyMaxResultSize = safetyMaxResultSize;
+    }
+
+    // ===================================================================================
+    //                                                  Implementation of MapParameterBean
+    //                                                  ==================================
+    /**
+     * Get the map of parameter.
+     * 
+     * @return The map of parameter. (Nullable)
+     */
+    public Map<String, Object> getParameterMap() {
+        return _parameterMap;
+    }
+
+    /**
+     * Add the parameter to the map.
+     * 
+     * @param key The key of parameter. (NotNull)
+     * @param value The value of parameter. (Nullable)
+     */
+    public void addParameter(String key, Object value) {
+        if (_parameterMap == null) {
+            _parameterMap = new LinkedHashMap<String, Object>();
+        }
+        _parameterMap.put(key, value);
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    // -----------------------------------------------------
+    //                                             SqlClause
+    //                                             ---------
+    /**
+     * Get sqlClause.
+     * 
+     * @return SqlClause. (NotNull)
+     */
+    protected SqlClause getSqlClause() {
+        return _sqlClause;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/SimplePagingBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKey.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKey.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKey.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,308 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import java.util.List;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+/**
+ * The abstract class of condition-key.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public abstract class ConditionKey {
+
+    /** Mark of replaced value. */
+    public static final String MARK_OF_REPLACED_VALUE = "ReplacedValue";
+
+    /** The condition key of equal. */
+    public static final ConditionKey CK_EQUAL = new ConditionKeyEqual();
+
+    /** The condition key of notEqual. */
+    public static final ConditionKey CK_NOT_EQUAL = new ConditionKeyNotEqual();
+
+    /** The condition key of greaterThan. */
+    public static final ConditionKey CK_GREATER_THAN = new ConditionKeyGreaterThan();
+
+    /** The condition key of lessrThan. */
+    public static final ConditionKey CK_LESS_THAN = new ConditionKeyLessThan();
+
+    /** The condition key of greaterEqual. */
+    public static final ConditionKey CK_GREATER_EQUAL = new ConditionKeyGreaterEqual();
+
+    /** The condition key of lessEqual. */
+    public static final ConditionKey CK_LESS_EQUAL = new ConditionKeyLessEqual();
+
+    /** The condition key of prefixSearch. */
+    public static final ConditionKey CK_PREFIX_SEARCH = new ConditionKeyPrefixSearch();
+
+    /** The condition key of likeSearch. */
+    public static final ConditionKey CK_LIKE_SEARCH = new ConditionKeyLikeSearch();
+
+    /** The condition key of inScope. */
+    public static final ConditionKey CK_IN_SCOPE = new ConditionKeyInScope();
+
+    /** The condition key of notInScope. */
+    public static final ConditionKey CK_NOT_IN_SCOPE = new ConditionKeyNotInScope();
+
+    /** The condition key of isNull. */
+    public static final ConditionKey CK_IS_NULL = new ConditionKeyIsNull();
+
+    /** The condition key of isNotNull. */
+    public static final ConditionKey CK_IS_NOT_NULL = new ConditionKeyIsNotNull();
+
+    /** Dummy-object for IsNull and IsNotNull and so on... */
+    protected static final Object DUMMY_OBJECT = new Object();
+
+    /** Condition-key. */
+    protected String _conditionKey;
+
+    /** Operand. */
+    protected String _operand;
+
+    /**
+     * Get condition-key.
+     * 
+     * @return Condition-key.
+     */
+    public String getConditionKey() {
+        return _conditionKey;
+    }
+
+    /**
+     * Get operand.
+     * 
+     * @return Operand.
+     */
+    public String getOperand() {
+        return _operand;
+    }
+
+    /**
+     * Is valid registration?
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    abstract public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName);
+
+    /**
+     * Add where clause.
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @return this.
+     */
+    public ConditionKey addWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value == null) {
+            String msg = "Argument[value] must not be null:";
+            throw new IllegalArgumentException(msg + " value=" + value
+                    + " this.toString()=" + toString());
+        }
+        doAddWhereClause(conditionList, columnName, value);
+        return this;
+    }
+
+    /**
+     * Add where clause.
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     * @return this.
+     */
+    public ConditionKey addWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        if (value == null) {
+            String msg = "Argument[value] must not be null:";
+            throw new IllegalArgumentException(msg + " value=" + value
+                    + " this.toString()=" + toString());
+        }
+        doAddWhereClause(conditionList, columnName, value, option);
+        return this;
+    }
+
+    /**
+     * Do add where clause.
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    abstract protected void doAddWhereClause(List<String> conditionList,
+            String columnName, ConditionValue value);
+
+    /**
+     * Do add where clause.
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    abstract protected void doAddWhereClause(List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option);
+
+    /**
+     * Setup condition value.
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (Nullable)
+     * @param location Location. (Nullable)
+     * @return Condition value. (The same as argument[conditionValue]) (NotNull)
+     */
+    public ConditionValue setupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        if (conditionValue == null) {
+            String msg = "Argument[conditionValue] must not be null:";
+            throw new IllegalArgumentException(msg + " value=" + value
+                    + " this.toString()=" + toString());
+        }
+        doSetupConditionValue(conditionValue, value, location);
+        return conditionValue;
+    }
+
+    /**
+     * Setup condition value.
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (Nullable)
+     * @param location Location. (Nullable)
+     * @param option Condition option. (NotNull)
+     * @return Condition value. (The same as argument[conditionValue]) (NotNull)
+     */
+    public ConditionValue setupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        if (conditionValue == null) {
+            String msg = "Argument[conditionValue] must not be null:";
+            throw new IllegalArgumentException(msg + " value=" + value
+                    + " this.toString()=" + toString());
+        }
+        doSetupConditionValue(conditionValue, value, location, option);
+        return conditionValue;
+    }
+
+    /**
+     * Do setup condition value.
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    abstract protected void doSetupConditionValue(
+            ConditionValue conditionValue, Object value, String location);
+
+    /**
+     * Do setup condition value.
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    abstract protected void doSetupConditionValue(
+            ConditionValue conditionValue, Object value, String location,
+            ConditionOption option);
+
+    /**
+     * Build bind clause. (for s2dao)
+     * 
+     * @param columnName Column name. (NotNull)
+     * @param location Location. (NotNull)
+     * @return Bind clause. (NotNull)
+     */
+    protected String buildBindClause(String columnName, String location) {
+        return columnName + " " + getOperand() + " " + "/*dto." + location
+                + "*/null";
+    }
+
+    /**
+     * Build bind clause. (for s2dao)
+     * 
+     * @param columnName Column name. (NotNull)
+     * @param location Location. (NotNull)
+     * @param additionalOption Additional option. (NotNull)
+     * @return Bind clause. (NotNull)
+     */
+    protected String buildBindClauseWithRearOption(String columnName,
+            String location, String rearOption) {
+        return columnName + " " + getOperand() + " " + "/*dto." + location
+                + "*/null" + rearOption;
+    }
+
+    /**
+     * Build bind clause. (for s2dao)
+     * 
+     * @param columnName Column name. (NotNull)
+     * @param location Location. (NotNull)
+     * @param dummyValue Dummy value. (NotNull)
+     * @return Bind clause. (NotNull)
+     */
+    protected String buildBindClause(String columnName, String location,
+            String dummyValue) {
+        return columnName + " " + getOperand() + " " + "/*dto." + location
+                + "*/" + dummyValue;
+    }
+
+    /**
+     * Build clause without value.
+     * 
+     * @param columnName Column name. (NotNull)
+     * @return Clause without value. (NotNull)
+     */
+    protected String buildClauseWithoutValue(String columnName) {
+        return columnName + " " + getOperand();
+    }
+
+    /**
+     * Get wild-card.
+     * 
+     * @return Wild-card.
+     */
+    protected String getWildCard() {
+        return "%";
+    }
+
+    /**
+     * The override.
+     * Returns hash-code of this condition-key string.
+     * 
+     * @return HashCode.
+     */
+    public int hashCode() {
+        return getConditionKey().hashCode();
+    }
+
+    /**
+     * The override.
+     * If the condition-key of the other is same as this one, returns true.
+     * 
+     * @param other Other entity. (Nullable)
+     * @return Comparing result. If other is null, returns false.
+     */
+    public boolean equals(Object other) {
+        if (other instanceof ConditionKey) {
+            if (this.getConditionKey().equals(
+                    ((ConditionKey) other).getConditionKey())) {
+                return true;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * The override.
+     * 
+     * @return View-string of condition key information.
+     */
+    public String toString() {
+        return "ConditionKey: " + getConditionKey() + " " + getOperand()
+                + " wild-card=[" + getWildCard() + "]";
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKey.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyEqual.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyEqual.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyEqual.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,108 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * The condition-key of equal.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyEqual extends ConditionKey {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory.getLog(ConditionKeyEqual.class);
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyEqual() {
+        _conditionKey = "equal";
+        _operand = "=";
+    }
+
+    /**
+     * Is valid registration?
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (value == null) {
+            return false;
+        }
+        if (conditionValue.hasEqual()) {
+            if (conditionValue.equalEqual(value)) {
+                _log.warn("The value has already registered at " + callerName
+                        + ": value=" + value);
+                return false;
+            } else {
+                conditionValue.overrideEqual(value);
+                return false;
+            }
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value.getEqual() == null) {
+            return;
+        }
+        conditionList
+                .add(buildBindClause(columnName, value.getEqualLocation()));
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doAddWhereClause with condition-option is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        conditionValue.setEqual(value).setEqualLocation(location);
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doSetupConditionValue with condition-option is unsupported!!!");
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyEqual.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyGreaterEqual.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyGreaterEqual.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyGreaterEqual.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,109 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * The condition-key of greaterEqual.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyGreaterEqual extends ConditionKey {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory
+            .getLog(ConditionKeyGreaterEqual.class);
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyGreaterEqual() {
+        _conditionKey = "greaterEqual";
+        _operand = ">=";
+    }
+
+    /**
+     * Is valid registration?
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (value == null) {
+            return false;
+        }
+        if (conditionValue.hasGreaterEqual()) {
+            if (conditionValue.equalGreaterEqual(value)) {
+                _log.warn("The value has already registered at " + callerName
+                        + ": value=" + value);
+                return false;
+            } else {
+                conditionValue.overrideGreaterEqual(value);
+                return false;
+            }
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value.getGreaterEqual() == null) {
+            return;
+        }
+        conditionList.add(buildBindClause(columnName, value
+                .getGreaterEqualLocation()));
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doAddWhereClause that has ConditionOption is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        conditionValue.setGreaterEqual(value).setGreaterEqualLocation(location);
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doSetupConditionValue with condition-option is unsupported!!!");
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyGreaterEqual.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyGreaterThan.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyGreaterThan.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyGreaterThan.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,109 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * The condition-key of greaterThan.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyGreaterThan extends ConditionKey {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory
+            .getLog(ConditionKeyGreaterThan.class);
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyGreaterThan() {
+        _conditionKey = "greaterThan";
+        _operand = ">";
+    }
+
+    /**
+     * Is valid registration?
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (value == null) {
+            return false;
+        }
+        if (conditionValue.hasGreaterThan()) {
+            if (conditionValue.equalGreaterThan(value)) {
+                _log.warn("The value has already registered at " + callerName
+                        + ": value=" + value);
+                return false;
+            } else {
+                conditionValue.overrideGreaterThan(value);
+                return false;
+            }
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value.getGreaterThan() == null) {
+            return;
+        }
+        conditionList.add(buildBindClause(columnName, value
+                .getGreaterThanLocation()));
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doAddWhereClause that has ConditionOption is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        conditionValue.setGreaterThan(value).setGreaterThanLocation(location);
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doSetupConditionValue with condition-option is unsupported!!!");
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyGreaterThan.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyInScope.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyInScope.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyInScope.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,121 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.InScopeOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * The condition-key of inScope.
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyInScope extends ConditionKey {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory
+            .getLog(ConditionKeyInScope.class);
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyInScope() {
+        _conditionKey = "inScope";
+        _operand = "in";
+    }
+
+    /**
+     * Is valid registration?
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (value == null) {
+            return false;
+        }
+        if (value instanceof java.util.List
+                && ((java.util.List) value).isEmpty()) {
+            return false;
+        }
+        if (value instanceof java.util.List) {
+            if (conditionValue.hasInScope()) {
+                if (conditionValue.equalInScope(((java.util.List) value))) {
+                    _log.warn("The value has already registered at "
+                            + callerName + ": value=" + value);
+                    return false;
+                } else {
+                    conditionValue.overrideInScope(((java.util.List) value));
+                    return false;
+                }
+            }
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value.getInScope() == null) {
+            return;
+        }
+        conditionList.add(buildBindClause(columnName, value
+                .getInScopeLocation(), "('a1', 'a2')"));
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        if (option == null) {
+            String msg = "The argument[option] should not be null: columnName="
+                    + columnName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+        if (!(option instanceof InScopeOption)) {
+            String msg = "The argument[option] should be InScopeOption: columnName="
+                    + columnName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+        conditionList.add(buildBindClause(columnName, value
+                .getInScopeLocation(), "('a1', 'a2')"));
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        conditionValue.setInScope((java.util.List) value).setInScopeLocation(
+                location);
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        conditionValue.setInScope((java.util.List) value,
+                (InScopeOption) option).setInScopeLocation(location);
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyInScope.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyIsNotNull.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyIsNotNull.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyIsNotNull.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,100 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * The condition-key of isNotNull.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyIsNotNull extends ConditionKey {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory
+            .getLog(ConditionKeyIsNotNull.class);
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyIsNotNull() {
+        _conditionKey = "isNotNull";
+        _operand = "is not null";
+    }
+
+    /**
+     * Is valid registration?
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (conditionValue.hasIsNotNull()) {
+            _log.warn("The value has already registered at " + callerName);
+            return false;
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value.getIsNotNull() == null) {
+            return;
+        }
+        conditionList.add(buildClauseWithoutValue(columnName));
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doAddWhereClause that has ConditionOption is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        conditionValue.setIsNotNull(DUMMY_OBJECT)
+                .setIsNotNullLocation(location);
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doSetupConditionValue with condition-option is unsupported!!!");
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyIsNotNull.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyIsNull.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyIsNull.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyIsNull.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,98 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * The condition-key of isNull.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyIsNull extends ConditionKey {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory.getLog(ConditionKeyIsNull.class);
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyIsNull() {
+        _conditionKey = "isNull";
+        _operand = "is null";
+    }
+
+    /**
+     * Is valid registration?
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (conditionValue.hasIsNull()) {
+            _log.warn("The value has already registered at " + callerName);
+            return false;
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value.getIsNull() == null) {
+            return;
+        }
+        conditionList.add(buildClauseWithoutValue(columnName));
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doAddWhereClause that has ConditionOption is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        conditionValue.setIsNull(DUMMY_OBJECT).setIsNullLocation(location);
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doSetupConditionValue with condition-option is unsupported!!!");
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyIsNull.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLessEqual.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLessEqual.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLessEqual.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,109 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * The condition-key of lessEqual.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyLessEqual extends ConditionKey {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory
+            .getLog(ConditionKeyLessEqual.class);
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyLessEqual() {
+        _conditionKey = "lessEqual";
+        _operand = "<=";
+    }
+
+    /**
+     * Is valid registration?
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (value == null) {
+            return false;
+        }
+        if (conditionValue.hasLessEqual()) {
+            if (conditionValue.equalLessEqual(value)) {
+                _log.warn("The value has already registered at " + callerName
+                        + ": value=" + value);
+                return false;
+            } else {
+                conditionValue.overrideLessEqual(value);
+                return false;
+            }
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value.getLessEqual() == null) {
+            return;
+        }
+        conditionList.add(buildBindClause(columnName, value
+                .getLessEqualLocation()));
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doAddWhereClause that has ConditionOption is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        conditionValue.setLessEqual(value).setLessEqualLocation(location);
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doSetupConditionValue with condition-option is unsupported!!!");
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLessEqual.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLessThan.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLessThan.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLessThan.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,109 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * The condition-key of lessThan.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyLessThan extends ConditionKey {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory
+            .getLog(ConditionKeyLessThan.class);
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyLessThan() {
+        _conditionKey = "lessThan";
+        _operand = "<";
+    }
+
+    /**
+     * Is valid registration?
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (value == null) {
+            return false;
+        }
+        if (conditionValue.hasLessThan()) {
+            if (conditionValue.equalLessThan(value)) {
+                _log.warn("The value has already registered at " + callerName
+                        + ": value=" + value);
+                return false;
+            } else {
+                conditionValue.overrideLessThan(value);
+                return false;
+            }
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value.getLessThan() == null) {
+            return;
+        }
+        conditionList.add(buildBindClause(columnName, value
+                .getLessThanLocation()));
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doAddWhereClause that has ConditionOption is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        conditionValue.setLessThan(value).setLessThanLocation(location);
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doSetupConditionValue with condition-option is unsupported!!!");
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLessThan.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLikeSearch.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLikeSearch.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLikeSearch.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,102 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.LikeSearchOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+/**
+ * The condition-key of likeSearch.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyLikeSearch extends ConditionKey {
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyLikeSearch() {
+        _conditionKey = "likeSearch";
+        _operand = "like";
+    }
+
+    /**
+     * Is valid registration?
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (value == null) {
+            return false;
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        throw new UnsupportedOperationException(
+                "doAddWhereClause without condition-option is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        if (option == null) {
+            String msg = "The argument[option] should not be null: columnName="
+                    + columnName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+        if (!(option instanceof LikeSearchOption)) {
+            String msg = "The argument[option] should be LikeSearchOption: columnName="
+                    + columnName + " value=" + value;
+            throw new IllegalArgumentException(msg);
+        }
+        final LikeSearchOption myOption = (LikeSearchOption) option;
+        conditionList.add(buildBindClauseWithRearOption(columnName, value
+                .getLikeSearchLocation(), myOption.getRearOption()));
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        throw new UnsupportedOperationException(
+                "doSetupConditionValue without condition-option is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        conditionValue.setLikeSearch((String) value, (LikeSearchOption) option)
+                .setLikeSearchLocation(location);
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyLikeSearch.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyNotEqual.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyNotEqual.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyNotEqual.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,109 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * The condition-key of notEqual.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyNotEqual extends ConditionKey {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory
+            .getLog(ConditionKeyNotEqual.class);
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyNotEqual() {
+        _conditionKey = "notEqual";
+        _operand = "!=";
+    }
+
+    /**
+     * Is valid registration?
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (value == null) {
+            return false;
+        }
+        if (conditionValue.hasNotEqual()) {
+            if (conditionValue.equalNotEqual(value)) {
+                _log.warn("The value has already registered at " + callerName
+                        + ": value=" + value);
+                return false;
+            } else {
+                conditionValue.overrideNotEqual(value);
+                return false;
+            }
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value.getNotEqual() == null) {
+            return;
+        }
+        conditionList.add(buildBindClause(columnName, value
+                .getNotEqualLocation()));
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doAddWhereClause with condition-option is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        conditionValue.setNotEqual(value).setNotEqualLocation(location);
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doSetupConditionValue with condition-option is unsupported!!!");
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyNotEqual.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyNotInScope.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyNotInScope.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyNotInScope.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,111 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * The condition-key of notInScope.
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyNotInScope extends ConditionKey {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory
+            .getLog(ConditionKeyNotInScope.class);
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyNotInScope() {
+        _conditionKey = "notInScope";
+        _operand = "not in";
+    }
+
+    /**
+     * Is valid registration?
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (value == null) {
+            return false;
+        }
+        if (value instanceof java.util.List
+                && ((java.util.List) value).isEmpty()) {
+            return false;
+        }
+        if (value instanceof java.util.List) {
+            if (conditionValue.hasNotInScope()) {
+                if (conditionValue.equalNotInScope(((java.util.List) value))) {
+                    _log.warn("The value has already registered at "
+                            + callerName + ": value=" + value);
+                    return false;
+                } else {
+                    conditionValue.overrideNotInScope(((java.util.List) value));
+                    return false;
+                }
+            }
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value.getNotInScope() == null) {
+            return;
+        }
+        conditionList.add(buildBindClause(columnName, value
+                .getNotInScopeLocation(), "('a1', 'a2')"));
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doAddWhereClause that has ConditionOption is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        conditionValue.setNotInScope((java.util.List) value)
+                .setNotInScopeLocation(location);
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doSetupConditionValue with condition-option is unsupported!!!");
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyNotInScope.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyPrefixSearch.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyPrefixSearch.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyPrefixSearch.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,111 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.ckey;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * The condition-key of prefixSearch.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionKeyPrefixSearch extends ConditionKey {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory
+            .getLog(ConditionKeyPrefixSearch.class);
+
+    /**
+     * Constructor.
+     */
+    protected ConditionKeyPrefixSearch() {
+        _conditionKey = "prefixSearch";
+        _operand = "like";
+    }
+
+    /**
+     * Is valid registration?
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param callerName Caller name. (NotNull)
+     * @return Determination.
+     */
+    public boolean isValidRegistration(ConditionValue conditionValue,
+            Object value, String callerName) {
+        if (value == null) {
+            return false;
+        }
+        if (conditionValue.hasPrefixSearch()) {
+            if (conditionValue.equalPrefixSearch(value + getWildCard())) {
+                _log.warn("The value has already registered at " + callerName
+                        + ": value=" + value);
+                return false;
+            } else {
+                conditionValue.overridePrefixSearch(value);
+                return false;
+            }
+        }
+        return true;
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value) {
+        if (value.getPrefixSearch() == null) {
+            return;
+        }
+        conditionList.add(buildBindClause(columnName, value
+                .getPrefixSearchLocation()));
+    }
+
+    /**
+     * This method implements super#doAddWhereClause().
+     * 
+     * @param conditionList Condition list. (NotNull)
+     * @param columnName Column name. (NotNull)
+     * @param value Condition value. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doAddWhereClause(java.util.List<String> conditionList,
+            String columnName, ConditionValue value, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doAddWhereClause that has ConditionOption is unsupported!!!");
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location) {
+        conditionValue.setPrefixSearch(
+                (value != null ? value + getWildCard() : null))
+                .setPrefixSearchLocation(location);
+    }
+
+    /**
+     * This method implements super#doSetupConditionValue().
+     * 
+     * @param conditionValue Condition value. (NotNull)
+     * @param value Value. (NotNull)
+     * @param location Location. (NotNull)
+     * @param option Condition option. (NotNull)
+     */
+    protected void doSetupConditionValue(ConditionValue conditionValue,
+            Object value, String location, ConditionOption option) {
+        throw new UnsupportedOperationException(
+                "doSetupConditionValue with condition-option is unsupported!!!");
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/ckey/ConditionKeyPrefixSearch.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/ConditionOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/ConditionOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/ConditionOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,10 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.coption;
+
+/**
+ * The interface of condition-option.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public interface ConditionOption {
+    public String getRearOption();
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/ConditionOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/DateFromToOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/DateFromToOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/DateFromToOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,24 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.coption;
+
+/**
+ * The option of date-from-to.
+ * <pre>
+ * ex) fromDate:{2007/04/10 08:24:53} toDate:{2007/04/16 14:36:29}
+ *
+ *   - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
+ *   new DateFromToOption(); 
+ *     --&gt; column &gt;= '2007/04/10 00:00:00' and column &lt; '2007/04/17 00:00:00'
+ *   - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
+ * 
+ * </pre>
+ * @author DBFlute(AutoGenerator)
+ */
+public class DateFromToOption extends FromToOption {
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    public DateFromToOption() {
+        compareAsDate();
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/DateFromToOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/FromToOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/FromToOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/FromToOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,147 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.coption;
+
+/**
+ * The option of from-to.
+ * <pre>
+ * ex) fromDate:{2007/04/10 08:24:53} toDate:{2007/04/16 14:36:29}
+ *
+ *   - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
+ *   new FromToOption().compareAsDate(); 
+ *     --&gt; column &gt;= '2007/04/10 00:00:00' and column &lt; '2007/04/17 00:00:00'
+ *   - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
+ *
+ *   new FromToOption(); 
+ *     --&gt; column &gt;= '2007/04/10 08:24:53' and column &lt;= '2007/04/16 14:36:29'
+ *
+ *   new FromToOption().greaterThan(); 
+ *     --&gt; column &gt; '2007/04/10 08:24:53' and column &lt;= '2007/04/16 14:36:29'
+ *
+ *   new FromToOption().lessThan(); 
+ *     --&gt; column &gt;= '2007/04/10 08:24:53' and column &lt; '2007/04/16 14:36:29'
+ *
+ *   new FromToOption().greaterThan().lessThan(); 
+ *     --&gt; column &gt; '2007/04/10 08:24:53' and column &lt; '2007/04/16 14:36:29'
+ * 
+ * </pre>
+ * @author DBFlute(AutoGenerator)
+ */
+public class FromToOption implements ConditionOption {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected boolean _fromDateGreaterThan;
+
+    protected boolean _toDateLessThan;
+
+    protected boolean _compareAsDate;
+
+    // ===================================================================================
+    //                                                            Interface Implementation
+    //                                                            ========================
+    public String getRearOption() {
+        String msg = "Thie option does not use getRearOption()!";
+        throw new UnsupportedOperationException(msg);
+    }
+
+    // ===================================================================================
+    //                                                                                Main
+    //                                                                                ====
+    public FromToOption greaterThan() {
+        _fromDateGreaterThan = true;
+        return this;
+    }
+
+    public FromToOption lessThan() {
+        _toDateLessThan = true;
+        return this;
+    }
+
+    /**
+     * Compare as date.
+     * <pre>
+     * ex) fromDate:{2007/04/10 08:24:53} toDate:{2007/04/16 14:36:29}
+     *
+     *   new FromToOption().compareAsDate();
+     *     --&gt; column &gt;= '2007/04/10 00:00:00' and column &lt; '2007/04/17 00:00:00'
+     * 
+     * This method ignore greaterThan() and lessThan().
+     * </pre>
+     * @return this. (NotNull)
+     */
+    public FromToOption compareAsDate() {
+        _compareAsDate = true;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                       Internal Main
+    //                                                                       =============
+    public java.util.Date filterFromDate(java.util.Date fromDate) {
+        if (fromDate == null) {
+            return null;
+        }
+        if (_compareAsDate) {
+            final java.util.Calendar cal = java.util.Calendar.getInstance();
+            cal.setTimeInMillis(fromDate.getTime());
+            clearCalendarHourMinuteSecondMilli(cal);
+            final java.util.Date cloneDate = (java.util.Date) fromDate.clone();
+            cloneDate.setTime(cal.getTimeInMillis());
+            return cloneDate;
+        }
+        return fromDate;
+    }
+
+    public java.util.Date filterToDate(java.util.Date toDate) {
+        if (toDate == null) {
+            return null;
+        }
+        if (_compareAsDate) {
+            final java.util.Calendar cal = java.util.Calendar.getInstance();
+            cal.setTimeInMillis(toDate.getTime());
+            clearCalendarHourMinuteSecondMilli(cal);
+            addCalendarNextDay(cal);// Key Point!
+            final java.util.Date cloneDate = (java.util.Date) toDate.clone();
+            cloneDate.setTime(cal.getTimeInMillis());
+            return cloneDate;
+        }
+        return toDate;
+    }
+
+    public jp.sf.pal.announcement.db.allcommon.cbean.ckey.ConditionKey getFromDateConditionKey() {
+        if (_compareAsDate) {
+            return jp.sf.pal.announcement.db.allcommon.cbean.ckey.ConditionKey.CK_GREATER_EQUAL;
+        }
+        if (_fromDateGreaterThan) {
+            return jp.sf.pal.announcement.db.allcommon.cbean.ckey.ConditionKey.CK_GREATER_THAN;// Default!
+        } else {
+            return jp.sf.pal.announcement.db.allcommon.cbean.ckey.ConditionKey.CK_GREATER_EQUAL;// Default!
+        }
+    }
+
+    public jp.sf.pal.announcement.db.allcommon.cbean.ckey.ConditionKey getToDateConditionKey() {
+        if (_compareAsDate) {
+            return jp.sf.pal.announcement.db.allcommon.cbean.ckey.ConditionKey.CK_LESS_THAN;
+        }
+        if (_toDateLessThan) {
+            return jp.sf.pal.announcement.db.allcommon.cbean.ckey.ConditionKey.CK_LESS_THAN;// Default!
+        } else {
+            return jp.sf.pal.announcement.db.allcommon.cbean.ckey.ConditionKey.CK_LESS_EQUAL;// Default!
+        }
+    }
+
+    // ===================================================================================
+    //                                                                     Calendar Helper
+    //                                                                     ===============
+    protected void addCalendarNextDay(java.util.Calendar cal) {
+        cal.add(java.util.Calendar.DAY_OF_MONTH, 1);
+    }
+
+    protected void clearCalendarHourMinuteSecondMilli(java.util.Calendar cal) {
+        cal.clear(java.util.Calendar.MILLISECOND);
+        cal.clear(java.util.Calendar.SECOND);
+        cal.clear(java.util.Calendar.MINUTE);
+        cal.set(java.util.Calendar.HOUR_OF_DAY, cal
+                .getActualMinimum(java.util.Calendar.HOUR_OF_DAY));
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/FromToOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/InScopeOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/InScopeOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/InScopeOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,87 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.coption;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.parts.local.JapaneseOptionPartsAgent;
+
+/**
+ * The class of in-scope-option.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class InScopeOption extends SimpleStringOption {
+
+    // =====================================================================================
+    //                                                                                 Split
+    //                                                                                 =====
+    public InScopeOption splitBySpace() {
+        return (InScopeOption) doSplitBySpace();
+    }
+
+    public InScopeOption splitBySpace(int splitLimitCount) {
+        return (InScopeOption) doSplitBySpace(splitLimitCount);
+    }
+
+    public InScopeOption splitBySpaceContainsDoubleByte() {
+        return (InScopeOption) doSplitBySpaceContainsDoubleByte();
+    }
+
+    public InScopeOption splitBySpaceContainsDoubleByte(int splitLimitCount) {
+        return (InScopeOption) doSplitBySpaceContainsDoubleByte(splitLimitCount);
+    }
+
+    public InScopeOption splitByPipeLine() {
+        return (InScopeOption) doSplitByPipeLine();
+    }
+
+    public InScopeOption splitByPipeLine(int splitLimitCount) {
+        return (InScopeOption) doSplitByPipeLine(splitLimitCount);
+    }
+
+    // =====================================================================================
+    //                                                                   To Upper/Lower Case
+    //                                                                   ===================
+    public InScopeOption toUpperCase() {
+        return (InScopeOption) doToUpperCase();
+    }
+
+    public InScopeOption toLowerCase() {
+        return (InScopeOption) doToLowerCase();
+    }
+
+    // =====================================================================================
+    //                                                                        To Single Byte
+    //                                                                        ==============
+    public InScopeOption toSingleByteSpace() {
+        return (InScopeOption) doToSingleByteSpace();
+    }
+
+    public InScopeOption toSingleByteAlphabetNumber() {
+        return (InScopeOption) doToSingleByteAlphabetNumber();
+    }
+
+    public InScopeOption toSingleByteAlphabetNumberMark() {
+        return (InScopeOption) doToSingleByteAlphabetNumberMark();
+    }
+
+    // =====================================================================================
+    //                                                                        To Double Byte
+    //                                                                        ==============
+
+    // =====================================================================================
+    //                                                                              Japanese
+    //                                                                              ========
+    public JapaneseOptionPartsAgent localJapanese() {
+        return doLocalJapanese();
+    }
+
+    // =====================================================================================
+    //                                                                            Real Value
+    //                                                                            ==========
+    public java.util.List generateRealValueList(java.util.List valueList) {
+        final java.util.List<String> resultList = new java.util.ArrayList<String>();
+        for (final java.util.Iterator ite = valueList.iterator(); ite.hasNext();) {
+            final String value = (String) ite.next();
+            resultList.add(generateRealValue(value));
+        }
+        return resultList;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/InScopeOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/LikeSearchOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/LikeSearchOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/LikeSearchOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,250 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.coption;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.parts.local.JapaneseOptionPartsAgent;
+
+/**
+ * The class of like-search-option.
+ * @author DBFlute(AutoGenerator)
+ */
+public class LikeSearchOption extends SimpleStringOption {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    protected static final String LIKE_PREFIX = "prefix";
+
+    protected static final String LIKE_SUFFIX = "suffix";
+
+    protected static final String LIKE_CONTAIN = "contain";
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected String _like;
+
+    protected String _escape;
+
+    protected boolean _asOrSplit;
+
+    protected List<LikeAsOrCallback> _likeAsOrCallbackList;
+
+    // ===================================================================================
+    //                                                                         Rear Option
+    //                                                                         ===========
+    public String getRearOption() {
+        if (_escape == null || _escape.trim().length() == 0) {
+            return "";
+        }
+        return " escape '" + _escape + "'";
+    }
+
+    // ===================================================================================
+    //                                                                                AsOr
+    //                                                                                ====
+    public static interface LikeAsOrCallback {
+        public String getAdditionalTargetPropertyName();
+
+        public String filterValue(String currentValue);
+
+        public LikeSearchOption filterOption(
+                LikeSearchOption optionDeepCopyWithoutCallback);
+    }
+
+    public static abstract class DefaultLikeAsOrCallback implements
+            LikeAsOrCallback {
+        public String filterValue(String currentValue) {
+            return currentValue;
+        }
+
+        public LikeSearchOption filterOption(
+                LikeSearchOption optionDeepCopyWithoutCallback) {
+            return optionDeepCopyWithoutCallback;
+        }
+    }
+
+    public boolean hasLikeAsOrCallback() {
+        return _likeAsOrCallbackList != null
+                && !_likeAsOrCallbackList.isEmpty();
+    }
+
+    public List<LikeAsOrCallback> getLikeAsOrCallbackList() {
+        if (_likeAsOrCallbackList == null) {
+            _likeAsOrCallbackList = new ArrayList<LikeAsOrCallback>();
+        }
+        return _likeAsOrCallbackList;
+    }
+
+    public void addLikeAsOrCallback(LikeAsOrCallback likeAsOrCallback) {
+        getLikeAsOrCallbackList().add(likeAsOrCallback);
+    }
+
+    public void clearLikeAsOrCallback() {
+        getLikeAsOrCallbackList().clear();
+    }
+
+    // ===================================================================================
+    //                                                                                Like
+    //                                                                                ====
+    public LikeSearchOption likePrefix() {
+        _like = LIKE_PREFIX;
+        return this;
+    }
+
+    public LikeSearchOption likeSuffix() {
+        _like = LIKE_SUFFIX;
+        return this;
+    }
+
+    public LikeSearchOption likeContain() {
+        _like = LIKE_CONTAIN;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                              Escape
+    //                                                                              ======
+    public LikeSearchOption escapeByPipeLine() {
+        _escape = "|";
+        return this;
+    }
+
+    public LikeSearchOption escapeByAtMark() {
+        _escape = "@";
+        return this;
+    }
+
+    public LikeSearchOption escapeBySlash() {
+        _escape = "/";
+        return this;
+    }
+
+    public LikeSearchOption escapeByBackSlash() {
+        _escape = "\\";
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                               Split
+    //                                                                               =====
+    public LikeSearchOption splitBySpace() {
+        return (LikeSearchOption) doSplitBySpace();
+    }
+
+    public LikeSearchOption splitBySpace(int splitLimitCount) {
+        return (LikeSearchOption) doSplitBySpace(splitLimitCount);
+    }
+
+    public LikeSearchOption splitBySpaceContainsDoubleByte() {
+        return (LikeSearchOption) doSplitBySpaceContainsDoubleByte();
+    }
+
+    public LikeSearchOption splitBySpaceContainsDoubleByte(int splitLimitCount) {
+        return (LikeSearchOption) doSplitBySpaceContainsDoubleByte(splitLimitCount);
+    }
+
+    public LikeSearchOption splitByPipeLine() {
+        return (LikeSearchOption) doSplitByPipeLine();
+    }
+
+    public LikeSearchOption splitByPipeLine(int splitLimitCount) {
+        return (LikeSearchOption) doSplitByPipeLine(splitLimitCount);
+    }
+
+    public LikeSearchOption asOrSplit() {
+        _asOrSplit = true;
+        return this;
+    }
+
+    public boolean isAsOrSplit() {
+        return _asOrSplit;
+    }
+
+    // ===================================================================================
+    //                                                                 To Upper/Lower Case
+    //                                                                 ===================
+    public LikeSearchOption toUpperCase() {
+        return (LikeSearchOption) doToUpperCase();
+    }
+
+    public LikeSearchOption toLowerCase() {
+        return (LikeSearchOption) doToLowerCase();
+    }
+
+    // ===================================================================================
+    //                                                                      To Single Byte
+    //                                                                      ==============
+    public LikeSearchOption toSingleByteSpace() {
+        return (LikeSearchOption) doToSingleByteSpace();
+    }
+
+    public LikeSearchOption toSingleByteAlphabetNumber() {
+        return (LikeSearchOption) doToSingleByteAlphabetNumber();
+    }
+
+    public LikeSearchOption toSingleByteAlphabetNumberMark() {
+        return (LikeSearchOption) doToSingleByteAlphabetNumberMark();
+    }
+
+    // ===================================================================================
+    //                                                                      To Double Byte
+    //                                                                      ==============
+
+    // ===================================================================================
+    //                                                                            Japanese
+    //                                                                            ========
+    public JapaneseOptionPartsAgent localJapanese() {
+        return doLocalJapanese();
+    }
+
+    // ===================================================================================
+    //                                                                          Real Value
+    //                                                                          ==========
+    public String generateRealValue(String value) {
+        value = super.generateRealValue(value);
+
+        // Escape
+        if (_escape != null && _escape.trim().length() != 0) {
+            String tmp = replace(value, _escape, _escape + _escape);
+            tmp = replace(tmp, "%", _escape + "%");
+            tmp = replace(tmp, "_", _escape + "_");
+            value = tmp;
+        }
+        final String wildCard = "%";
+        if (_like == null || _like.trim().length() == 0) {
+            return value;
+        } else if (_like.equals(LIKE_PREFIX)) {
+            return value + wildCard;
+        } else if (_like.equals(LIKE_SUFFIX)) {
+            return wildCard + value;
+        } else if (_like.equals(LIKE_CONTAIN)) {
+            return wildCard + value + wildCard;
+        } else {
+            String msg = "The like was wrong string: " + _like;
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                            DeepCopy
+    //                                                                            ========
+    public Object createDeepCopy() {
+        final LikeSearchOption deepCopy = (LikeSearchOption) super
+                .createDeepCopy();
+        deepCopy._like = _like;
+        deepCopy._escape = _escape;
+        if (hasLikeAsOrCallback()) {
+            for (Iterator ite = _likeAsOrCallbackList.iterator(); ite.hasNext();) {
+                deepCopy.addLikeAsOrCallback((LikeAsOrCallback) ite.next());
+            }
+        }
+        return deepCopy;
+    }
+
+    protected SimpleStringOption newDeepCopyInstance() {
+        return new LikeSearchOption();
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/LikeSearchOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/SimpleStringOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/SimpleStringOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/SimpleStringOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,183 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.coption;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.parts.SplitOptionParts;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.parts.ToSingleByteOptionParts;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.parts.ToUpperLowerCaseOptionParts;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.parts.local.JapaneseOptionPartsAgent;
+import jp.sf.pal.announcement.db.allcommon.util.SimpleStringUtil;
+
+/**
+ * The class of simple-string-option.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class SimpleStringOption implements ConditionOption {
+
+    protected SplitOptionParts _splitOptionParts;
+
+    protected ToUpperLowerCaseOptionParts _toUpperLowerCaseOptionParts;
+
+    protected ToSingleByteOptionParts _toSingleByteCaseOptionParts;
+
+    protected JapaneseOptionPartsAgent _japaneseOptionPartsAgent;
+
+    // =====================================================================================
+    //                                                                           Rear Option
+    //                                                                           ===========
+    public String getRearOption() {
+        return "";
+    }
+
+    // =====================================================================================
+    //                                                                                 Split
+    //                                                                                 =====
+    protected SimpleStringOption doSplitBySpace() {
+        getSplitOptionParts().splitBySpace();
+        return this;
+    }
+
+    protected SimpleStringOption doSplitBySpace(int splitLimitCount) {
+        getSplitOptionParts().splitBySpace(splitLimitCount);
+        return this;
+    }
+
+    protected SimpleStringOption doSplitBySpaceContainsDoubleByte() {
+        getSplitOptionParts().splitBySpaceContainsDoubleByte();
+        return this;
+    }
+
+    protected SimpleStringOption doSplitBySpaceContainsDoubleByte(
+            int splitLimitCount) {
+        getSplitOptionParts().splitBySpaceContainsDoubleByte(splitLimitCount);
+        return this;
+    }
+
+    protected SimpleStringOption doSplitByPipeLine() {
+        getSplitOptionParts().splitByPipeLine();
+        return this;
+    }
+
+    protected SimpleStringOption doSplitByPipeLine(int splitLimitCount) {
+        getSplitOptionParts().splitByPipeLine(splitLimitCount);
+        return this;
+    }
+
+    protected SplitOptionParts getSplitOptionParts() {
+        if (_splitOptionParts == null) {
+            _splitOptionParts = new SplitOptionParts();
+        }
+        return _splitOptionParts;
+    }
+
+    public boolean isSplit() {
+        return getSplitOptionParts().isSplit();
+    }
+
+    public String[] generateSplitValueArray(String value) {
+        return getSplitOptionParts().generateSplitValueArray(value);
+    }
+
+    // =====================================================================================
+    //                                                                   To Upper/Lower Case
+    //                                                                   ===================
+    protected SimpleStringOption doToUpperCase() {
+        getToUpperLowerCaseOptionParts().toUpperCase();
+        return this;
+    }
+
+    protected SimpleStringOption doToLowerCase() {
+        getToUpperLowerCaseOptionParts().toLowerCase();
+        return this;
+    }
+
+    protected ToUpperLowerCaseOptionParts getToUpperLowerCaseOptionParts() {
+        if (_toUpperLowerCaseOptionParts == null) {
+            _toUpperLowerCaseOptionParts = new ToUpperLowerCaseOptionParts();
+        }
+        return _toUpperLowerCaseOptionParts;
+    }
+
+    // =====================================================================================
+    //                                                                        To Single Byte
+    //                                                                        ==============
+    protected SimpleStringOption doToSingleByteSpace() {
+        getToSingleByteOptionParts().toSingleByteSpace();
+        return this;
+    }
+
+    protected SimpleStringOption doToSingleByteAlphabetNumber() {
+        getToSingleByteOptionParts().toSingleByteAlphabetNumber();
+        return this;
+    }
+
+    protected SimpleStringOption doToSingleByteAlphabetNumberMark() {
+        getToSingleByteOptionParts().toSingleByteAlphabetNumberMark();
+        return this;
+    }
+
+    protected ToSingleByteOptionParts getToSingleByteOptionParts() {
+        if (_toSingleByteCaseOptionParts == null) {
+            _toSingleByteCaseOptionParts = new ToSingleByteOptionParts();
+        }
+        return _toSingleByteCaseOptionParts;
+    }
+
+    // =====================================================================================
+    //                                                                        To Double Byte
+    //                                                                        ==============
+
+    // =====================================================================================
+    //                                                                              Japanese
+    //                                                                              ========
+    protected JapaneseOptionPartsAgent doLocalJapanese() {
+        return getJapaneseOptionPartsAgent();
+    }
+
+    protected JapaneseOptionPartsAgent getJapaneseOptionPartsAgent() {
+        if (_japaneseOptionPartsAgent == null) {
+            _japaneseOptionPartsAgent = new JapaneseOptionPartsAgent();
+        }
+        return _japaneseOptionPartsAgent;
+    }
+
+    // =====================================================================================
+    //                                                                            Real Value
+    //                                                                            ==========
+    public String generateRealValue(String value) {
+        value = getToUpperLowerCaseOptionParts().generateRealValue(value);
+        value = getToSingleByteOptionParts().generateRealValue(value);
+        value = getJapaneseOptionPartsAgent().generateRealValue(value);
+        return value;
+    }
+
+    // =====================================================================================
+    //                                                                        General Helper
+    //                                                                        ==============
+    protected String replace(String text, String fromText, String toText) {
+        return SimpleStringUtil.replace(text, fromText, toText);
+    }
+
+    // =====================================================================================
+    //                                                                              DeepCopy
+    //                                                                              ========
+    public Object createDeepCopy() {
+        final SimpleStringOption deepCopy = newDeepCopyInstance();
+        deepCopy._splitOptionParts = _splitOptionParts != null ? (SplitOptionParts) _splitOptionParts
+                .createDeepCopy()
+                : null;
+        deepCopy._toUpperLowerCaseOptionParts = _toUpperLowerCaseOptionParts != null ? (ToUpperLowerCaseOptionParts) _toUpperLowerCaseOptionParts
+                .createDeepCopy()
+                : null;
+        deepCopy._toSingleByteCaseOptionParts = _toSingleByteCaseOptionParts != null ? (ToSingleByteOptionParts) _toSingleByteCaseOptionParts
+                .createDeepCopy()
+                : null;
+        deepCopy._japaneseOptionPartsAgent = _japaneseOptionPartsAgent != null ? (JapaneseOptionPartsAgent) _japaneseOptionPartsAgent
+                .createDeepCopy()
+                : null;
+        return deepCopy;
+    }
+
+    protected SimpleStringOption newDeepCopyInstance() {
+        return new SimpleStringOption();
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/SimpleStringOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/SplitOptionParts.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/SplitOptionParts.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/SplitOptionParts.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,156 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.coption.parts;
+
+/**
+ * The interface of condition-option.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class SplitOptionParts {
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected String _split;
+
+    protected String _splitContainedDelimiter;
+
+    protected int _splitLimitCount;
+
+    // =====================================================================================
+    //                                                                                  Main
+    //                                                                                  ====
+    public boolean isSplit() {
+        return _split != null;
+    }
+
+    public void splitBySpace() {
+        _split = " ";
+    }
+
+    public void splitBySpace(int splitLimitCount) {
+        _split = " ";
+        _splitLimitCount = splitLimitCount;
+    }
+
+    public void splitBySpaceContainsDoubleByte() {
+        _split = " ";
+        _splitContainedDelimiter = "\u3000";
+    }
+
+    public void splitBySpaceContainsDoubleByte(int splitLimitCount) {
+        _split = " ";
+        _splitContainedDelimiter = "\u3000";
+        _splitLimitCount = splitLimitCount;
+    }
+
+    public void splitByPipeLine() {
+        _split = "|";
+    }
+
+    public void splitByPipeLine(int splitLimitCount) {
+        _split = "|";
+        _splitLimitCount = splitLimitCount;
+    }
+
+    // =====================================================================================
+    //                                                                            Real Value
+    //                                                                            ==========
+    public String[] generateSplitValueArray(String value) {
+        if (value == null || value.trim().length() == 0) {
+            String msg = "The argument[value] should not be null of empty: "
+                    + value;
+            throw new IllegalArgumentException(msg);
+        }
+        value = repalceContainedDelimiterToRealDelimiter(value);
+        final java.util.StringTokenizer st = new java.util.StringTokenizer(
+                value, _split);
+        final String[] tokenizedValues = new String[st.countTokens()];
+        int count = 0;
+        while (st.hasMoreTokens()) {
+            tokenizedValues[count] = st.nextToken();
+            count++;
+        }
+        final String[] values = removeInvalidValue(tokenizedValues);
+        if (_splitLimitCount > 0 && values.length > _splitLimitCount) {
+            final String[] realValues = new String[_splitLimitCount];
+            for (int i = 0; i < values.length; i++) {
+                if (i == _splitLimitCount) {
+                    break;
+                }
+                realValues[i] = values[i];
+            }
+            return realValues;
+        } else {
+            return values;
+        }
+
+    }
+
+    protected String repalceContainedDelimiterToRealDelimiter(String value) {
+        if (value == null || value.trim().length() == 0) {
+            return value;
+        }
+        if (_splitContainedDelimiter == null) {
+            return value;
+        }
+        if (_split == null) {
+            return value;
+        }
+        return replace(value, _splitContainedDelimiter, _split);
+    }
+
+    protected String[] removeInvalidValue(String[] values) {
+        final java.util.List<String> ls = new java.util.ArrayList<String>();
+        for (int i = 0; i < values.length; i++) {
+            final String value = values[i];
+            if (value == null || value.equals("")) {// Don't trim!!!
+                continue;
+            }
+            ls.add(value);
+        }
+        final String[] resultArray = new String[ls.size()];
+        for (int i = 0; i < ls.size(); i++) {
+            resultArray[i] = (String) ls.get(i);
+        }
+        return resultArray;
+    }
+
+    // =====================================================================================
+    //                                                                                Helper
+    //                                                                                ======
+    protected final String replace(String text, String fromText, String toText) {
+
+        if (text == null || fromText == null || toText == null) {
+            return null;
+        }
+        StringBuffer buf = new StringBuffer(100);
+        int pos = 0;
+        int pos2 = 0;
+        while (true) {
+            pos = text.indexOf(fromText, pos2);
+            if (pos == 0) {
+                buf.append(toText);
+                pos2 = fromText.length();
+            } else if (pos > 0) {
+                buf.append(text.substring(pos2, pos));
+                buf.append(toText);
+                pos2 = pos + fromText.length();
+            } else {
+                buf.append(text.substring(pos2));
+                break;
+            }
+        }
+        return buf.toString();
+    }
+
+    // =====================================================================================
+    //                                                                              DeepCopy
+    //                                                                              ========
+    public Object createDeepCopy() {
+        final SplitOptionParts deepCopy = new SplitOptionParts();
+        deepCopy._split = _split;
+        deepCopy._splitContainedDelimiter = _splitContainedDelimiter;
+        deepCopy._splitLimitCount = _splitLimitCount;
+        return deepCopy;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/SplitOptionParts.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/ToSingleByteOptionParts.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/ToSingleByteOptionParts.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/ToSingleByteOptionParts.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,84 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.coption.parts;
+
+import jp.sf.pal.announcement.db.allcommon.helper.character.GeneralCharacter;
+import jp.sf.pal.announcement.db.allcommon.helper.character.impl.GeneralCharacterImpl;
+
+/**
+ * The interface of condition-option.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ToSingleByteOptionParts {
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected boolean _toSingleByteSpace;
+
+    protected boolean _toSingleByteAlphabetNumber;
+
+    protected boolean _toSingleByteAlphabetNumberMark;
+
+    private GeneralCharacter _generalCharacter;
+
+    // =====================================================================================
+    //                                                                                  Main
+    //                                                                                  ====
+    public boolean isToSingleByteSpace() {
+        return _toSingleByteSpace;
+    }
+
+    public void toSingleByteSpace() {
+        _toSingleByteSpace = true;
+    }
+
+    public void toSingleByteAlphabetNumber() {
+        _toSingleByteAlphabetNumber = true;
+    }
+
+    public void toSingleByteAlphabetNumberMark() {
+        _toSingleByteAlphabetNumberMark = true;
+    }
+
+    // =====================================================================================
+    //                                                                            Real Value
+    //                                                                            ==========
+    public String generateRealValue(String value) {
+        if (value == null || value.trim().length() == 0) {
+            String msg = "The argument[value] should not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+
+        // To Single Byte
+        if (_toSingleByteSpace) {
+            value = (value != null ? value.replaceAll("\u3000", " ") : value);
+        }
+        if (_toSingleByteAlphabetNumberMark) {
+            value = getGeneralCharacter().toSingleByteAlphabetNumberMark(value);
+        } else if (_toSingleByteAlphabetNumber) {
+            value = getGeneralCharacter().toSingleByteAlphabetNumber(value);
+        }
+        return value;
+    }
+
+    // =====================================================================================
+    //                                                                                Helper
+    //                                                                                ======
+    protected GeneralCharacter getGeneralCharacter() {
+        if (_generalCharacter == null) {
+            _generalCharacter = new GeneralCharacterImpl();
+        }
+        return _generalCharacter;
+    }
+
+    // =====================================================================================
+    //                                                                              DeepCopy
+    //                                                                              ========
+    public Object createDeepCopy() {
+        final ToSingleByteOptionParts deepCopy = new ToSingleByteOptionParts();
+        deepCopy._toSingleByteSpace = _toSingleByteSpace;
+        deepCopy._toSingleByteAlphabetNumber = _toSingleByteAlphabetNumber;
+        deepCopy._toSingleByteAlphabetNumberMark = _toSingleByteAlphabetNumberMark;
+        return deepCopy;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/ToSingleByteOptionParts.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/ToUpperLowerCaseOptionParts.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/ToUpperLowerCaseOptionParts.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/ToUpperLowerCaseOptionParts.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,58 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.coption.parts;
+
+/**
+ * The class of condition-option-parts about toUpperCase/toLowerCase.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ToUpperLowerCaseOptionParts {
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected boolean _toUpperCase;
+
+    protected boolean _toLowerCase;
+
+    // =====================================================================================
+    //                                                                                  Main
+    //                                                                                  ====
+    public void toUpperCase() {
+        _toUpperCase = true;
+        _toLowerCase = false;
+    }
+
+    public void toLowerCase() {
+        _toUpperCase = false;
+        _toLowerCase = true;
+    }
+
+    // =====================================================================================
+    //                                                                            Real Value
+    //                                                                            ==========
+    public String generateRealValue(String value) {
+        if (value == null || value.trim().length() == 0) {
+            String msg = "The argument[value] should not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+
+        // To Upper/Lower Case
+        if (_toUpperCase) {
+            value = (value != null ? value.toUpperCase() : value);
+        }
+        if (_toLowerCase) {
+            value = (value != null ? value.toLowerCase() : value);
+        }
+        return value;
+    }
+
+    // =====================================================================================
+    //                                                                              DeepCopy
+    //                                                                              ========
+    public Object createDeepCopy() {
+        final ToUpperLowerCaseOptionParts deepCopy = new ToUpperLowerCaseOptionParts();
+        deepCopy._toUpperCase = _toUpperCase;
+        deepCopy._toLowerCase = _toLowerCase;
+        return deepCopy;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/ToUpperLowerCaseOptionParts.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/local/JapaneseOptionPartsAgent.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/local/JapaneseOptionPartsAgent.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/local/JapaneseOptionPartsAgent.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,83 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.coption.parts.local;
+
+import jp.sf.pal.announcement.db.allcommon.helper.character.JapaneseCharacter;
+import jp.sf.pal.announcement.db.allcommon.helper.character.impl.JapaneseCharacterImpl;
+
+/**
+ * The class of condition-option-parts-agent.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class JapaneseOptionPartsAgent {
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected boolean _toDoubleByteKatakana;
+
+    protected boolean _removeLastLongVowel;
+
+    private JapaneseCharacter _japaneseCharacter;
+
+    // =====================================================================================
+    //                                                                                  Main
+    //                                                                                  ====
+    public boolean isToDoubleByteKatakana() {
+        return _toDoubleByteKatakana;
+    }
+
+    public void toDoubleByteKatakana() {
+        _toDoubleByteKatakana = true;
+    }
+
+    public boolean isRemoveLastLongVowel() {
+        return _removeLastLongVowel;
+    }
+
+    public void removeLastLongVowel() {
+        _removeLastLongVowel = true;
+    }
+
+    // =====================================================================================
+    //                                                                            Real Value
+    //                                                                            ==========
+    public String generateRealValue(String value) {
+        if (value == null || value.trim().length() == 0) {
+            String msg = "The argument[value] should not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+
+        // To Double Byte
+        if (_toDoubleByteKatakana) {
+            value = getJapaneseCharacter().toDoubleByteKatakana(value);
+        }
+
+        // Remove
+        if (_removeLastLongVowel) {
+            if (value != null && value.endsWith("\u30fc")) {
+                value = value.substring(0, value.length() - "\u30fc".length());
+            }
+        }
+        return value;
+    }
+
+    // =====================================================================================
+    //                                                                                Helper
+    //                                                                                ======
+    protected JapaneseCharacter getJapaneseCharacter() {
+        if (_japaneseCharacter == null) {
+            _japaneseCharacter = new JapaneseCharacterImpl();
+        }
+        return _japaneseCharacter;
+    }
+
+    // =====================================================================================
+    //                                                                              DeepCopy
+    //                                                                              ========
+    public Object createDeepCopy() {
+        final JapaneseOptionPartsAgent deepCopy = new JapaneseOptionPartsAgent();
+        deepCopy._toDoubleByteKatakana = _toDoubleByteKatakana;
+        deepCopy._removeLastLongVowel = _removeLastLongVowel;
+        return deepCopy;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/coption/parts/local/JapaneseOptionPartsAgent.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/cvalue/ConditionValue.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/cvalue/ConditionValue.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/cvalue/ConditionValue.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,1201 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.cvalue;
+
+import java.util.List;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.InScopeOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.LikeSearchOption;
+
+/**
+ * Condition value.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class ConditionValue {
+
+    // ===================================================================================
+    //                                                                               Equal
+    //                                                                               =====
+    /** Value of equal. */
+    protected Object _equalValue;
+
+    /**
+     * Get the value of equal.
+     * 
+     * @return The value of equal. (Nullable)
+     */
+    public Object getEqual() {
+        return filterValue(_equalValue);
+    }
+
+    /**
+     * Set the value of equal.
+     * 
+     * @param value The value of equal. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setEqual(Object value) {
+        _equalValue = value;
+        return this;
+    }
+
+    /**
+     * Does it has the value of equal?
+     * 
+     * @return Determination. (NotNull)
+     */
+    public boolean hasEqual() {
+        return _equalValue != null;
+    }
+
+    /**
+     * Does the value equal the value of equal?
+     * 
+     * @param value The value of equal. (Nullable)
+     * @return Determination. (NotNull)
+     */
+    public boolean equalEqual(Object value) {
+        return hasEqual() ? _equalValue.equals(value) : value == null;
+    }
+
+    /**
+     * Override the value of equal.
+     * 
+     * @param value The value of equal. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue overrideEqual(Object value) {
+        _equalValue = value;
+        return this;
+    }
+
+    /** Location of equal. */
+    protected String _equalLocation;
+
+    /**
+     * Get the location of equal.
+     * 
+     * @return The location of equal. (Nullable)
+     */
+    public String getEqualLocation() {
+        return _equalLocation;
+    }
+
+    /**
+     * Set the location of equal.
+     * 
+     * @param location The location of equal. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setEqualLocation(String location) {
+        _equalLocation = location;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                           Not Equal
+    //                                                                           =========
+    /** Value of notEqual. */
+    protected Object _notEqualValue;
+
+    /**
+     * Get the value of notEqual.
+     * 
+     * @return The value of notEqual. (Nullable)
+     */
+    public Object getNotEqual() {
+        return filterValue(_notEqualValue);
+    }
+
+    /**
+     * Set the value of notEqual.
+     * 
+     * @param value The value of notEqual. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setNotEqual(Object value) {
+        _notEqualValue = value;
+        return this;
+    }
+
+    /**
+     * Does it has the value of notEqual?
+     * 
+     * @return Determination. (NotNull)
+     */
+    public boolean hasNotEqual() {
+        return _notEqualValue != null;
+    }
+
+    /**
+     * Does the value equal the value of notEqual?
+     * 
+     * @param value The value of notEqual. (Nullable)
+     * @return Determination. (NotNull)
+     */
+    public boolean equalNotEqual(Object value) {
+        return hasNotEqual() ? _notEqualValue.equals(value) : value == null;
+    }
+
+    /**
+     * Override the value of notEqual.
+     * 
+     * @param value The value of notEqual. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue overrideNotEqual(Object value) {
+        _notEqualValue = value;
+        return this;
+    }
+
+    /** Location of notEqual. */
+    protected String _notEqualLocation;
+
+    /**
+     * Get the location of notEqual.
+     * 
+     * @return The location of notEqual. (Nullable)
+     */
+    public String getNotEqualLocation() {
+        return _notEqualLocation;
+    }
+
+    /**
+     * Set the location of notEqual.
+     * 
+     * @param location The location of notEqual. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setNotEqualLocation(String location) {
+        _notEqualLocation = location;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                        Greater Than
+    //                                                                        ============
+    /** Value of greaterThan. */
+    protected Object _greaterThanValue;
+
+    /**
+     * Get the value of greaterThan.
+     * 
+     * @return The value of greaterThan. (Nullable)
+     */
+    public Object getGreaterThan() {
+        return filterValue(_greaterThanValue);
+    }
+
+    /**
+     * Set the value of greaterThan.
+     * 
+     * @param value The value of greaterThan. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setGreaterThan(Object value) {
+        _greaterThanValue = value;
+        return this;
+    }
+
+    /**
+     * Does it has the value of greaterThan?
+     * 
+     * @return Determination. (NotNull)
+     */
+    public boolean hasGreaterThan() {
+        return _greaterThanValue != null;
+    }
+
+    /**
+     * Does the value equal the value of greaterThan?
+     * 
+     * @param value The value of greaterThan. (Nullable)
+     * @return Determination. (NotNull)
+     */
+    public boolean equalGreaterThan(Object value) {
+        return hasGreaterThan() ? _greaterThanValue.equals(value)
+                : value == null;
+    }
+
+    /**
+     * Override the value of greaterThan.
+     * 
+     * @param value The value of greaterThan. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue overrideGreaterThan(Object value) {
+        _greaterThanValue = value;
+        return this;
+    }
+
+    /** Location of GreaterThan. */
+    protected String _greaterThanLocation;
+
+    /**
+     * Get the location of greaterThan.
+     * 
+     * @return The location of greaterThan. (Nullable)
+     */
+    public String getGreaterThanLocation() {
+        return _greaterThanLocation;
+    }
+
+    /**
+     * Set the location of greaterThan.
+     * 
+     * @param location The location of greaterThan. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setGreaterThanLocation(String location) {
+        _greaterThanLocation = location;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                           Less Than
+    //                                                                           =========
+    /** Value of lessThan. */
+    protected Object _lessThanValue;
+
+    /**
+     * Get the value of lessThan.
+     * 
+     * @return The value of lessThan. (Nullable)
+     */
+    public Object getLessThan() {
+        return filterValue(_lessThanValue);
+    }
+
+    /**
+     * Set the value of lessThan.
+     * 
+     * @param value The value of lessThan. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setLessThan(Object value) {
+        _lessThanValue = value;
+        return this;
+    }
+
+    /**
+     * Does it has the value of lessThan?
+     * 
+     * @return Determination. (NotNull)
+     */
+    public boolean hasLessThan() {
+        return _lessThanValue != null;
+    }
+
+    /**
+     * Does the value equal the value of lessThan?
+     * 
+     * @param value The value of lessThan. (Nullable)
+     * @return Determination. (NotNull)
+     */
+    public boolean equalLessThan(Object value) {
+        return hasLessThan() ? _lessThanValue.equals(value) : value == null;
+    }
+
+    /**
+     * Override the value of lessThan.
+     * 
+     * @param value The value of lessThan. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue overrideLessThan(Object value) {
+        _lessThanValue = value;
+        return this;
+    }
+
+    /** Location of lessThan. */
+    protected String _lessThanLocation;
+
+    /**
+     * Get the location of lessThan.
+     * 
+     * @return The location of lessThan. (Nullable)
+     */
+    public String getLessThanLocation() {
+        return _lessThanLocation;
+    }
+
+    /**
+     * Set the location of lessThan.
+     * 
+     * @param location The location of lessThan. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setLessThanLocation(String location) {
+        _lessThanLocation = location;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                       Greater Equal
+    //                                                                       =============
+    /** Value of greaterEqual. */
+    protected Object _greaterEqualValue;
+
+    /**
+     * Get the value of greaterEqual.
+     * 
+     * @return The value of greaterEqual. (Nullable)
+     */
+    public Object getGreaterEqual() {
+        return filterValue(_greaterEqualValue);
+    }
+
+    /**
+     * Set the value of greaterEqual.
+     * 
+     * @param value The value of greaterEqual. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setGreaterEqual(Object value) {
+        _greaterEqualValue = value;
+        return this;
+    }
+
+    /**
+     * Does it has the value of greaterEqual?
+     * 
+     * @return Determination. (NotNull)
+     */
+    public boolean hasGreaterEqual() {
+        return _greaterEqualValue != null;
+    }
+
+    /**
+     * Does the value equal the value of greaterEqual?
+     * 
+     * @param value The value of greaterEqual. (Nullable)
+     * @return Determination. (NotNull)
+     */
+    public boolean equalGreaterEqual(Object value) {
+        return hasGreaterEqual() ? _greaterEqualValue.equals(value)
+                : value == null;
+    }
+
+    /**
+     * Override the value of greaterEqual.
+     * 
+     * @param value The value of greaterEqual. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue overrideGreaterEqual(Object value) {
+        _greaterEqualValue = value;
+        return this;
+    }
+
+    /** Location of greaterEqual. */
+    protected String _greaterEqualLocation;
+
+    /**
+     * Get the location of greaterEqual.
+     * 
+     * @return The location of greaterEqual. (Nullable)
+     */
+    public String getGreaterEqualLocation() {
+        return _greaterEqualLocation;
+    }
+
+    /**
+     * Set the location of greaterEqual.
+     * 
+     * @param location The location of greaterEqual. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setGreaterEqualLocation(String location) {
+        _greaterEqualLocation = location;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                          Less Equal
+    //                                                                          ==========
+    /** Value of lessEqual. */
+    protected Object _lessEqualValue;
+
+    /**
+     * Get the value of lessEqual.
+     * 
+     * @return The value of lessEqual. (Nullable)
+     */
+    public Object getLessEqual() {
+        return filterValue(_lessEqualValue);
+    }
+
+    /**
+     * Set the value of lessEqual.
+     * 
+     * @param value The value of lessEqual. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setLessEqual(Object value) {
+        _lessEqualValue = value;
+        return this;
+    }
+
+    /**
+     * Does it has the value of lessEqual?
+     * 
+     * @return Determination. (NotNull)
+     */
+    public boolean hasLessEqual() {
+        return _lessEqualValue != null;
+    }
+
+    /**
+     * Does the value equal the value of lessEqual?
+     * 
+     * @param value The value of lessEqual. (Nullable)
+     * @return Determination. (NotNull)
+     */
+    public boolean equalLessEqual(Object value) {
+        return hasLessEqual() ? _lessEqualValue.equals(value) : value == null;
+    }
+
+    /**
+     * Override the value of lessEqual.
+     * 
+     * @param value The value of lessEqual. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue overrideLessEqual(Object value) {
+        _lessEqualValue = value;
+        return this;
+    }
+
+    /** Location of lessEqual. */
+    protected String _lessEqualLocation;
+
+    /**
+     * Get the location of lessEqual.
+     * 
+     * @return The location of lessEqual. (Nullable)
+     */
+    public String getLessEqualLocation() {
+        return _lessEqualLocation;
+    }
+
+    /**
+     * Set the location of lessEqual.
+     * 
+     * @param location The location of lessEqual. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setLessEqualLocation(String location) {
+        _lessEqualLocation = location;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                       Prefix Search
+    //                                                                       =============
+    /** Value of prefixSearch. */
+    protected Object _prefixSearch;
+
+    /**
+     * Get the value of prefixSearch.
+     * 
+     * @return The value of prefixSearch. (Nullable)
+     */
+    public Object getPrefixSearch() {
+        return filterValue(_prefixSearch);
+    }
+
+    /**
+     * Set the value of prefixSearch.
+     * 
+     * @param value The value of prefixSearch. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setPrefixSearch(Object value) {
+        _prefixSearch = value;
+        return this;
+    }
+
+    /**
+     * Does it has the value of prefixSearch?
+     * 
+     * @return Determination. (NotNull)
+     */
+    public boolean hasPrefixSearch() {
+        return _prefixSearch != null;
+    }
+
+    /**
+     * Does the value equal the value of prefixSearch?
+     * 
+     * @param value The value of prefixSearch. (Nullable)
+     * @return Determination. (NotNull)
+     */
+    public boolean equalPrefixSearch(Object value) {
+        return hasPrefixSearch() ? _prefixSearch.equals(value) : value == null;
+    }
+
+    /**
+     * Override the value of prefixSearch.
+     * 
+     * @param value The value of prefixSearch. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue overridePrefixSearch(Object value) {
+        _prefixSearch = value;
+        return this;
+    }
+
+    /** Location of prefixSearch. */
+    protected String _prefixSearchLocation;
+
+    /**
+     * Get the location of prefixSearch.
+     * 
+     * @return The location of prefixSearch. (Nullable)
+     */
+    public String getPrefixSearchLocation() {
+        return _prefixSearchLocation;
+    }
+
+    /**
+     * Set the location of prefixSearch.
+     * 
+     * @param location The location of prefixSearch. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setPrefixSearchLocation(String location) {
+        _prefixSearchLocation = location;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                         Like Search
+    //                                                                         ===========
+    /** Value of likeSearch. */
+    protected java.util.List<LikeSearchValue> _likeSearch;
+
+    /** Value of likeSearch for spare. */
+    protected java.util.List<LikeSearchValue> _likeSearch4Spare;
+
+    /**
+     * Get the value of likeSearch.
+     * 
+     * @return The value of likeSearch. (Nullable)
+     */
+    public String getLikeSearch() {
+        if (_likeSearch == null) {
+            return null;
+        }
+        if (_likeSearch.isEmpty() && !_likeSearch4Spare.isEmpty()) {
+            for (int index = 0; index < _likeSearch4Spare.size(); index++) {
+                _likeSearch.add(_likeSearch4Spare.get(index));
+            }
+        }
+        final LikeSearchValue likeSearchValue = (LikeSearchValue) _likeSearch
+                .remove(0);
+        return (String) filterValue(likeSearchValue.generateRealValue());
+    }
+
+    /**
+     * Set the value of likeSearch.
+     * 
+     * @param value The value of likeSearch. (Nullable)
+     * @param option The option of likeSearch. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setLikeSearch(String value, LikeSearchOption option) {
+        if (_likeSearch == null) {
+            _likeSearch = new java.util.ArrayList<LikeSearchValue>();
+            _likeSearch4Spare = new java.util.ArrayList<LikeSearchValue>();
+        }
+        if (_likeSearch.isEmpty() && !_likeSearch4Spare.isEmpty()) {
+            for (int index = 0; index < _likeSearch4Spare.size(); index++) {
+                _likeSearch.add(_likeSearch4Spare.get(index));
+            }
+        }
+        final LikeSearchValue likeSearchValue = new LikeSearchValue(value,
+                option);
+        _likeSearch.add(likeSearchValue);
+        _likeSearch4Spare.add(likeSearchValue);
+        return this;
+    }
+
+    /** Location of likeSearch. */
+    protected String _likeSearchLocation;
+
+    /**
+     * Get the location of likeSearch.
+     * 
+     * @return The location of likeSearch. (Nullable)
+     */
+    public String getLikeSearchLocation() {
+        return _likeSearchLocation;
+    }
+
+    /**
+     * Set the location of likeSearch.
+     * 
+     * @param location The location of likeSearch. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setLikeSearchLocation(String location) {
+        _likeSearchLocation = location;
+        return this;
+    }
+
+    protected static class LikeSearchValue {
+        protected String _value;
+
+        protected LikeSearchOption _option;
+
+        public LikeSearchValue(String value, LikeSearchOption option) {
+            _value = value;
+            _option = option;
+        }
+
+        public String getValue() {
+            return _value;
+        }
+
+        public LikeSearchOption getOption() {
+            return _option;
+        }
+
+        public String generateRealValue() {
+            if (_option == null) {
+                return _value;
+            }
+            return _option.generateRealValue(_value);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                            In Scope
+    //                                                                            ========
+    /** Value of inScope. */
+    protected List _inScope;
+
+    protected InScopeOption _inScopeOption;
+
+    /**
+     * Get the value of inScope.
+     * 
+     * @return The value of inScope. (Nullable)
+     */
+    public List getInScope() {
+        if (_inScopeOption != null) {
+            return filterValue(_inScopeOption.generateRealValueList(_inScope));
+        }
+        return filterValue(_inScope);
+    }
+
+    /**
+     * Set the value of inScope.
+     * 
+     * @param value The value of inScope. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setInScope(List value) {
+        _inScope = value;
+        return this;
+    }
+
+    public ConditionValue setInScope(List value, InScopeOption option) {
+        _inScope = value;
+        _inScopeOption = option;
+        return this;
+    }
+
+    /**
+     * Does it has the value of inScope?
+     * 
+     * @return Determination. (NotNull)
+     */
+    public boolean hasInScope() {
+        return _inScope != null;
+    }
+
+    /**
+     * Does the value equal the value of inScope?
+     * 
+     * @param value The value of inScope. (Nullable)
+     * @return Determination. (NotNull)
+     */
+    public boolean equalInScope(List value) {
+        return hasInScope() ? _inScope.equals(value) : value == null;
+    }
+
+    /**
+     * Override the value of inScope.
+     * 
+     * @param value The value of inScope. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue overrideInScope(List value) {
+        _inScope = value;
+        return this;
+    }
+
+    /** Location of InScope. */
+    protected String _inScopeLocation;
+
+    /**
+     * Get the location of inScope.
+     * 
+     * @return The location of inScope. (Nullable)
+     */
+    public String getInScopeLocation() {
+        return _inScopeLocation;
+    }
+
+    /**
+     * Set the location of inScope.
+     * 
+     * @param location The location of inScope. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setInScopeLocation(String location) {
+        _inScopeLocation = location;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                        Not In Scope
+    //                                                                        ============
+    /** Value of notInScope. */
+    protected List _notInScope;
+
+    /**
+     * Get the value of notInScope.
+     * 
+     * @return The value of notInScope. (Nullable)
+     */
+    public List getNotInScope() {
+        return filterValue(_notInScope);
+    }
+
+    /**
+     * Set the value of notInScope.
+     * 
+     * @param value The value of notInScope. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setNotInScope(List value) {
+        _notInScope = value;
+        return this;
+    }
+
+    /**
+     * Does it has the value of inNotScope?
+     * 
+     * @return Determination. (NotNull)
+     */
+    public boolean hasNotInScope() {
+        return _notInScope != null;
+    }
+
+    /**
+     * Does the value equal the value of inNotScope?
+     * 
+     * @param value The value of inNotScope. (Nullable)
+     * @return Determination. (NotNull)
+     */
+    public boolean equalNotInScope(List value) {
+        return hasNotInScope() ? _notInScope.equals(value) : value == null;
+    }
+
+    /**
+     * Override the value of inNotScope.
+     * 
+     * @param value The value of inNotScope. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue overrideNotInScope(List value) {
+        _notInScope = value;
+        return this;
+    }
+
+    /** Location of notInScope. */
+    protected String _notInScopeLocation;
+
+    /**
+     * Get the location of notInScope.
+     * 
+     * @return The location of notInScope. (Nullable)
+     */
+    public String getNotInScopeLocation() {
+        return _notInScopeLocation;
+    }
+
+    /**
+     * Set the location of notInScope.
+     * 
+     * @param location The location of notInScope. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setNotInScopeLocation(String location) {
+        _notInScopeLocation = location;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                             Is Null
+    //                                                                             =======
+    /** Value of isNull. */
+    protected Object _isNullValue;
+
+    /**
+     * Get the value of isNull.
+     * 
+     * @return The value of isNull. (Nullable)
+     */
+    public Object getIsNull() {
+        return _isNullValue;
+    }
+
+    /**
+     * Set the value of isNull.
+     * 
+     * @param value The value of isNull. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setIsNull(Object value) {
+        _isNullValue = value;
+        return this;
+    }
+
+    /**
+     * Does it has the value of isNull?
+     * 
+     * @return Determination. (NotNull)
+     */
+    public boolean hasIsNull() {
+        return _isNullValue != null;
+    }
+
+    /** Location of isNull. */
+    protected String _isNullLocation;
+
+    /**
+     * Get the location of isNull.
+     * 
+     * @return The location of isNull. (Nullable)
+     */
+    public String getIsNullLocation() {
+        return _isNullLocation;
+    }
+
+    /**
+     * Set the location of isNull.
+     * 
+     * @param location The location of isNull. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setIsNullLocation(String location) {
+        _isNullLocation = location;
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                         Is Not Null
+    //                                                                         ===========
+    /** Value of isNotNull. */
+    protected Object _isNotNullValue;
+
+    /**
+     * Get the value of isNotNull.
+     * 
+     * @return The value of isNotNull. (Nullable)
+     */
+    public Object getIsNotNull() {
+        return _isNotNullValue;
+    }
+
+    /**
+     * Set the value of isNotNull.
+     * 
+     * @param value The value of isNotNull. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setIsNotNull(Object value) {
+        _isNotNullValue = value;
+        return this;
+    }
+
+    /**
+     * Does it has the value of isNotNull?
+     * 
+     * @return Determination. (NotNull)
+     */
+    public boolean hasIsNotNull() {
+        return _isNotNullValue != null;
+    }
+
+    /** Location of isNotNull. */
+    protected String _isNotNullLocation;
+
+    /**
+     * Get the location of isNotNull.
+     * 
+     * @return The location of isNotNull. (Nullable)
+     */
+    public String getIsNotNullLocation() {
+        return _isNotNullLocation;
+    }
+
+    /**
+     * Set the location of isNotNull.
+     * 
+     * @param location The location of isNotNull. (Nullable)
+     * @return this. (NotNull)
+     */
+    public ConditionValue setIsNotNullLocation(String location) {
+        _isNotNullLocation = location;
+        return this;
+    }
+
+    // =====================================================================================
+    //                                                                                Filter
+    //                                                                                ======
+    /**
+     * Filter value.
+     * If the value is instance of java.util.Date or java.util.Calendar, returns value as java.sql.Date.
+     * 
+     * @param value Value. (Nullable)
+     * @return Filtered value. (Nullable)
+     */
+    protected Object filterValue(Object value) {
+        if (value == null) {
+            return value;
+        }
+        if (value instanceof java.sql.Timestamp) {
+            return value;
+        }
+        if (value instanceof java.util.Date
+                || value instanceof java.util.Calendar) {
+            return SqlDateConversionUtil.toDate(value);
+        } else {
+            return value;
+        }
+    }
+
+    /**
+     * Filter value.
+     * If the value is instance of java.util.Date or java.util.Calendar, returns value as java.sql.Date.
+     * 
+     * @param valueList Value-list. (Nullable)
+     * @return Filtered value-list. (Nullable)
+     */
+    protected java.util.List filterValue(java.util.List valueList) {
+        if (valueList == null || valueList.isEmpty()) {
+            return valueList;
+        }
+        final List<Object> resultList = new java.util.ArrayList<Object>();
+        for (final java.util.Iterator ite = valueList.iterator(); ite.hasNext();) {
+            Object value = ite.next();
+            resultList.add(filterValue(value));
+        }
+        return resultList;
+    }
+
+    protected static class SqlDateConversionUtil {
+
+        private SqlDateConversionUtil() {
+        }
+
+        public static java.sql.Date toDate(Object o) {
+            return toDate(o, null);
+        }
+
+        public static java.sql.Date toDate(Object o, String pattern) {
+            if (o instanceof java.sql.Date) {
+                return (java.sql.Date) o;
+            }
+            java.util.Date date = DateConversionUtil.toDate(o, pattern);
+            if (date != null) {
+                return new java.sql.Date(date.getTime());
+            }
+            return null;
+        }
+    }
+
+    protected static class DateConversionUtil {
+
+        private DateConversionUtil() {
+        }
+
+        public static java.util.Date toDate(Object o) {
+            return toDate(o, null);
+        }
+
+        public static java.util.Date toDate(Object o, String pattern) {
+            if (o == null) {
+                return null;
+            } else if (o instanceof String) {
+                return toDate((String) o, pattern);
+            } else if (o instanceof java.util.Date) {
+                return (java.util.Date) o;
+            } else if (o instanceof java.util.Calendar) {
+                return ((java.util.Calendar) o).getTime();
+            } else {
+                return toDate(o.toString(), pattern);
+            }
+        }
+
+        public static java.util.Date toDate(String s, String pattern) {
+            return toDate(s, pattern, java.util.Locale.getDefault());
+        }
+
+        public static java.util.Date toDate(String s, String pattern,
+                java.util.Locale locale) {
+            java.text.SimpleDateFormat sdf = getDateFormat(s, pattern, locale);
+            try {
+                return sdf.parse(s);
+            } catch (java.text.ParseException ex) {
+                throw new RuntimeException(ex);
+            }
+        }
+
+        public static java.text.SimpleDateFormat getDateFormat(String s,
+                String pattern, java.util.Locale locale) {
+            if (pattern != null) {
+                return new java.text.SimpleDateFormat(pattern);
+            }
+            return getDateFormat(s, locale);
+        }
+
+        public static java.text.SimpleDateFormat getDateFormat(String s,
+                java.util.Locale locale) {
+            String pattern = getPattern(locale);
+            String shortPattern = removeDelimiter(pattern);
+            String delimitor = findDelimiter(s);
+            if (delimitor == null) {
+                if (s.length() == shortPattern.length()) {
+                    return new java.text.SimpleDateFormat(shortPattern);
+                }
+                if (s.length() == shortPattern.length() + 2) {
+                    return new java.text.SimpleDateFormat(InternalStringUtil
+                            .replace(shortPattern, "yy", "yyyy"));
+                }
+            } else {
+                String[] array = InternalStringUtil.split(s, delimitor);
+                for (int i = 0; i < array.length; ++i) {
+                    if (array[i].length() == 4) {
+                        pattern = InternalStringUtil.replace(pattern, "yy",
+                                "yyyy");
+                        break;
+                    }
+                }
+                return new java.text.SimpleDateFormat(pattern);
+            }
+            return new java.text.SimpleDateFormat();
+        }
+
+        public static java.text.SimpleDateFormat getDateFormat(
+                java.util.Locale locale) {
+            return new java.text.SimpleDateFormat(getPattern(locale));
+        }
+
+        public static java.text.SimpleDateFormat getY4DateFormat(
+                java.util.Locale locale) {
+            return new java.text.SimpleDateFormat(getY4Pattern(locale));
+        }
+
+        public static String getY4Pattern(java.util.Locale locale) {
+            String pattern = getPattern(locale);
+            if (pattern.indexOf("yyyy") < 0) {
+                pattern = InternalStringUtil.replace(pattern, "yy", "yyyy");
+            }
+            return pattern;
+        }
+
+        public static String getPattern(java.util.Locale locale) {
+            java.text.SimpleDateFormat df = (java.text.SimpleDateFormat) java.text.DateFormat
+                    .getDateInstance(java.text.DateFormat.SHORT, locale);
+            String pattern = df.toPattern();
+            int index = pattern.indexOf(' ');
+            if (index > 0) {
+                pattern = pattern.substring(0, index);
+            }
+            if (pattern.indexOf("MM") < 0) {
+                pattern = InternalStringUtil.replace(pattern, "M", "MM");
+            }
+            if (pattern.indexOf("dd") < 0) {
+                pattern = InternalStringUtil.replace(pattern, "d", "dd");
+            }
+            return pattern;
+        }
+
+        public static String findDelimiter(String value) {
+            for (int i = 0; i < value.length(); ++i) {
+                char c = value.charAt(i);
+                if (Character.isDigit(c)) {
+                    continue;
+                }
+                return Character.toString(c);
+            }
+            return null;
+        }
+
+        public static String removeDelimiter(String pattern) {
+            StringBuffer buf = new StringBuffer();
+            for (int i = 0; i < pattern.length(); ++i) {
+                char c = pattern.charAt(i);
+                if (c == 'y' || c == 'M' || c == 'd') {
+                    buf.append(c);
+                }
+            }
+            return buf.toString();
+        }
+    }
+
+    protected static class InternalStringUtil {
+
+        public static final String[] EMPTY_STRINGS = new String[0];
+
+        private InternalStringUtil() {
+        }
+
+        public static final boolean isEmpty(String text) {
+            return text == null || text.length() == 0;
+        }
+
+        public static final String replace(String text, String fromText,
+                String toText) {
+
+            if (text == null || fromText == null || toText == null) {
+                return null;
+            }
+            StringBuffer buf = new StringBuffer(100);
+            int pos = 0;
+            int pos2 = 0;
+            while (true) {
+                pos = text.indexOf(fromText, pos2);
+                if (pos == 0) {
+                    buf.append(toText);
+                    pos2 = fromText.length();
+                } else if (pos > 0) {
+                    buf.append(text.substring(pos2, pos));
+                    buf.append(toText);
+                    pos2 = pos + fromText.length();
+                } else {
+                    buf.append(text.substring(pos2));
+                    break;
+                }
+            }
+            return buf.toString();
+        }
+
+        public static String[] split(String str, String delim) {
+            if (str == null) {
+                return EMPTY_STRINGS;
+            }
+            java.util.List<String> list = new java.util.ArrayList<String>();
+            java.util.StringTokenizer st = new java.util.StringTokenizer(str,
+                    delim);
+            while (st.hasMoreElements()) {
+                list.add(st.nextToken());
+            }
+            return (String[]) list.toArray(new String[list.size()]);
+        }
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/cvalue/ConditionValue.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,44 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.grouping;
+
+/**
+ * The class of option for grouping making.
+ * 
+ * @param <ENTITY> The type of entity.
+ * @author DBFlute(AutoGenerator)
+ */
+public class GroupingOption<ENTITY> {
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected int _columnCount;
+
+    protected GroupingRowEndDeterminer<ENTITY> _groupingRowEndDeterminer;
+
+    // =====================================================================================
+    //                                                                           Constructor
+    //                                                                           ===========
+    public GroupingOption(int columnCount) {
+        _columnCount = columnCount;
+    }
+
+    // =====================================================================================
+    //                                                                           Easy-to-Use
+    //                                                                           ===========
+
+    // =====================================================================================
+    //                                                                              Accessor
+    //                                                                              ========
+    public int getColumnCount() {
+        return this._columnCount;
+    }
+
+    public GroupingRowEndDeterminer<ENTITY> getGroupingRowEndDeterminer() {
+        return this._groupingRowEndDeterminer;
+    }
+
+    public void setGroupingRowEndDeterminer(
+            GroupingRowEndDeterminer<ENTITY> groupingRowEndDeterminer) {
+        this._groupingRowEndDeterminer = groupingRowEndDeterminer;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowEndDeterminer.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowEndDeterminer.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowEndDeterminer.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,13 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.grouping;
+
+/**
+ * The interface of grouping switch point determiner.
+ * 
+ * @param <ENTITY> The type of entity.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface GroupingRowEndDeterminer<ENTITY> {
+
+    public boolean determine(int columnIndex, int columnCount,
+            GroupingRowResource<ENTITY> rowResource, ENTITY nextEntity);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowEndDeterminer.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowResource.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowResource.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowResource.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,30 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.grouping;
+
+/**
+ * The class of row resource for grouping making.
+ * 
+ * @param <ENTITY> The type of entity.
+ * @author DBFlute(AutoGenerator)
+ */
+public class GroupingRowResource<ENTITY> {
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected java.util.List<ENTITY> _groupingRowList = new java.util.ArrayList<ENTITY>();
+
+    // =====================================================================================
+    //                                                                           Easy-to-Use
+    //                                                                           ===========
+
+    // =====================================================================================
+    //                                                                              Accessor
+    //                                                                              ========
+    public java.util.List<ENTITY> getGroupingRowList() {
+        return this._groupingRowList;
+    }
+
+    public void addGroupingRowList(ENTITY groupingRow) {
+        this._groupingRowList.add(groupingRow);
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowResource.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowSetupper.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowSetupper.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowSetupper.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,19 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.grouping;
+
+/**
+ * The interface of grouping row setupper.
+ * 
+ * @param <ROW> The type of row.
+ * @param <ENTITY> The type of entity.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface GroupingRowSetupper<ROW, ENTITY> {
+
+    /**
+     * Set up grouping row object.
+     * 
+     * @param groupingRowResource Grouping row resource. (NotNull)
+     * @return Grouping row object. (NotNull)
+     */
+    public ROW setup(GroupingRowResource<ENTITY> groupingRowResource);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/grouping/GroupingRowSetupper.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/mapping/EntityDtoMapper.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/mapping/EntityDtoMapper.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/mapping/EntityDtoMapper.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,17 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.mapping;
+
+/**
+ * The mapper of entity-to-dto.
+ * @param <ENTITY> The type of entity.
+ * @param <DTO> The type of dto.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface EntityDtoMapper<ENTITY, DTO> {
+
+    /**
+     * Map entity to data transfer object.
+     * @param entity Entity. (NotNull)
+     * @return Data transfer object. (NotNull)
+     */
+    public DTO map(ENTITY entity);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/mapping/EntityDtoMapper.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlContext.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlContext.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlContext.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,328 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.outsidesql;
+
+import jp.sf.pal.announcement.db.allcommon.jdbc.StatementConfig;
+import jp.sf.pal.announcement.db.allcommon.util.SimpleStringUtil;
+import jp.sf.pal.announcement.db.allcommon.util.SimpleSystemUtil;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.seasar.framework.util.InputStreamReaderUtil;
+import org.seasar.framework.util.ReaderUtil;
+import org.seasar.framework.util.ResourceUtil;
+
+/**
+ * The context of outside-sql.
+ * @author DBFlute(AutoGenerator)
+ */
+public class OutsideSqlContext {
+
+    /** Log-instance. */
+    private static final Log _log = LogFactory.getLog(OutsideSqlContext.class);
+
+    // ===================================================================================
+    //                                                                        Thread Local
+    //                                                                        ============
+    /** The thread-local for this. */
+    private static final ThreadLocal<OutsideSqlContext> _threadLocal = new ThreadLocal<OutsideSqlContext>();
+
+    /**
+     * Get outside-sql context on thread.
+     * 
+     * @return Outside-sql context. (Nullable)
+     */
+    public static OutsideSqlContext getOutsideSqlContextOnThread() {
+        return (OutsideSqlContext) _threadLocal.get();
+    }
+
+    /**
+     * Set outside-sql context on thread.
+     * 
+     * @param outsideSqlContext Outside-sql context. (NotNull)
+     */
+    public static void setOutsideSqlContextOnThread(
+            OutsideSqlContext outsideSqlContext) {
+        if (outsideSqlContext == null) {
+            String msg = "The argument[outsideSqlContext] must not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+        _threadLocal.set(outsideSqlContext);
+    }
+
+    /**
+     * Is existing outside-sql context on thread?
+     * 
+     * @return Determination.
+     */
+    public static boolean isExistOutsideSqlContextOnThread() {
+        return (_threadLocal.get() != null);
+    }
+
+    /**
+     * Clear outside-sql context on thread.
+     */
+    public static void clearOutsideSqlContextOnThread() {
+        _threadLocal.set(null);
+    }
+
+    // ===================================================================================
+    //                                                                          Unique Key
+    //                                                                          ==========
+    public static String generateSpecifiedOutsideSqlUniqueKey(
+            String methodName, String path, Object pmb,
+            OutsideSqlOption option, Object resultTypeSpecification) {
+        final String pmbKey = (pmb != null ? pmb.getClass().getName() : "null");
+        final String resultKey = (resultTypeSpecification != null ? ":"
+                + resultTypeSpecification : "null");
+        return methodName + "():" + path + ":" + pmbKey + ":"
+                + option.generateUniqueKey() + resultKey;
+    }
+
+    // ===================================================================================
+    //                                                                  Exception Handling
+    //                                                                  ==================
+    public static void throwOutsideSqlNotFoundException(String path) {
+        String msg = "Look! Read the message below." + getLineSeparator();
+        msg = msg
+                + "/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *"
+                + getLineSeparator();
+        msg = msg + "The outsideSql was Not Found!" + getLineSeparator();
+        msg = msg + getLineSeparator();
+        msg = msg + "[Advice]" + getLineSeparator();
+        msg = msg
+                + "Please confirm the existence of your target file of outsideSql on your classpath."
+                + getLineSeparator();
+        msg = msg
+                + "And please confirm the file name and the file path STRICTLY!"
+                + getLineSeparator();
+        msg = msg + getLineSeparator();
+        msg = msg + "[Specified OutsideSql Path]" + getLineSeparator() + path
+                + getLineSeparator();
+        msg = msg + "* * * * * * * * * */" + getLineSeparator();
+        throw new jp.sf.pal.announcement.db.allcommon.exception.OutsideSqlNotFoundException(
+                msg);
+    }
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    // -----------------------------------------------------
+    //                                  Common of OutsideSql
+    //                                  --------------------
+    protected boolean _dynamicBinding;
+
+    protected boolean _offsetByCursorForcedly;
+
+    protected boolean _limitByCursorForcedly;
+
+    // -----------------------------------------------------
+    //                                  Specified OutsideSql
+    //                                  --------------------
+    /** The path of outside-sql. (The mark of Specified-OutsideSql) */
+    protected String _outsideSqlPath;
+
+    protected Object _parameterBean;
+
+    protected Object _resultTypeSpecification;
+
+    protected String _methodName;
+
+    /** The config of statement. (Nullable) */
+    protected StatementConfig _statementConfig;
+
+    // ===================================================================================
+    //                                                                            Read SQL
+    //                                                                            ========
+    public String readFilteredOutsideSql(String sqlFileEncoding,
+            String dbmsSuffix) {
+        final String sql = readOutsideSql(sqlFileEncoding, dbmsSuffix);
+        return replaceOutsideSqlBindCharacterOnLineComment(sql);
+    }
+
+    protected String replaceOutsideSqlBindCharacterOnLineComment(String sql) {
+        final String bindCharacter = "?";
+        if (sql.indexOf(bindCharacter) < 0) {
+            return sql;
+        }
+        final String lineSeparator = "\n";
+        if (sql.indexOf(lineSeparator) < 0) {
+            return sql;
+        }
+        final String lineCommentMark = "--";
+        if (sql.indexOf(lineCommentMark) < 0) {
+            return sql;
+        }
+        final StringBuilder sb = new StringBuilder();
+        final String[] lines = sql.split(lineSeparator);
+        for (String line : lines) {
+            final int lineCommentIndex = line.indexOf("--");
+            if (lineCommentIndex < 0) {
+                sb.append(line).append(lineSeparator);
+                continue;
+            }
+            final String lineComment = line.substring(lineCommentIndex);
+            if (lineComment.contains("ELSE")
+                    || !lineComment.contains(bindCharacter)) {
+                sb.append(line).append(lineSeparator);
+                continue;
+            }
+
+            if (_log.isDebugEnabled()) {
+                _log.debug("...Replacing bind character on line comment: "
+                        + lineComment);
+            }
+            final String filteredLineComment = replaceString(lineComment,
+                    bindCharacter, "Q");
+            sb.append(line.substring(0, lineCommentIndex)).append(
+                    filteredLineComment).append(lineSeparator);
+        }
+        return sb.toString();
+    }
+
+    /**
+     * Read outside-sql path. Required attribute is 'outsideSqlPath'.
+     * @param sqlFileEncoding The encoding of SQL file. (NotNull)
+     * @param dbmsSuffix The suffix of DBMS. (NotNull)
+     * @return The text of SQL. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.OutsideSqlNotFoundException When the SQL is not found.
+     */
+    public String readOutsideSql(String sqlFileEncoding, String dbmsSuffix) {
+        final String standardPath = _outsideSqlPath;
+        final String dbmsPath = buildDbmsPath(standardPath, dbmsSuffix);
+        String sql;
+        if (isExistResource(dbmsPath)) {
+            sql = readText(dbmsPath, sqlFileEncoding);
+        } else if (isExistResource(standardPath)) {
+            sql = readText(standardPath, sqlFileEncoding);
+        } else {
+            throwOutsideSqlNotFoundException(standardPath);
+            return null; // Non Reachable.
+        }
+        return removeInitialUnicodeBomIfNeeds(sqlFileEncoding, sql);
+    }
+
+    protected String buildDbmsPath(String standardPath, String dbmsSuffix) {
+        final String dbmsPath;
+        final int lastIndexOfDot = standardPath.lastIndexOf(".");
+        if (lastIndexOfDot >= 0
+                && !standardPath.substring(lastIndexOfDot).contains("/")) {
+            final String base = standardPath.substring(0, lastIndexOfDot);
+            dbmsPath = base + dbmsSuffix
+                    + standardPath.substring(lastIndexOfDot);
+        } else {
+            dbmsPath = standardPath + dbmsSuffix;
+        }
+        return dbmsPath;
+    }
+
+    protected String removeInitialUnicodeBomIfNeeds(String sqlFileEncoding,
+            String sql) {
+        if ("UTF-8".equalsIgnoreCase(sqlFileEncoding) && sql.length() > 0
+                && sql.charAt(0) == '\uFEFF') {
+            sql = sql.substring(1);
+        }
+        return sql;
+    }
+
+    // ===================================================================================
+    //                                                                       Determination
+    //                                                                       =============
+    public boolean isSpecifiedOutsideSql() {
+        return _outsideSqlPath != null;
+    }
+
+    // ===================================================================================
+    //                                                                      General Helper
+    //                                                                      ==============
+    protected boolean isExistResource(String path) {
+        return ResourceUtil.isExist(path);
+    }
+
+    protected String readText(final String path, String sqlFileEncoding) {
+        final java.io.InputStream is = ResourceUtil.getResourceAsStream(path);
+        final java.io.Reader reader = InputStreamReaderUtil.create(is,
+                sqlFileEncoding);
+        return ReaderUtil.readText(reader);
+    }
+
+    protected static String replaceString(String text, String fromText,
+            String toText) {
+        return SimpleStringUtil.replace(text, fromText, toText);
+    }
+
+    protected static String getLineSeparator() {
+        return SimpleSystemUtil.getLineSeparator();
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    // -----------------------------------------------------
+    //                                  Common of OutsideSql
+    //                                  --------------------
+    public boolean isDynamicBinding() {
+        return _dynamicBinding;
+    }
+
+    public void setDynamicBinding(boolean dynamicBinding) {
+        this._dynamicBinding = dynamicBinding;
+    }
+
+    public boolean isOffsetByCursorForcedly() {
+        return _offsetByCursorForcedly;
+    }
+
+    public void setOffsetByCursorForcedly(boolean offsetByCursorForcedly) {
+        this._offsetByCursorForcedly = offsetByCursorForcedly;
+    }
+
+    public boolean isLimitByCursorForcedly() {
+        return _limitByCursorForcedly;
+    }
+
+    public void setLimitByCursorForcedly(boolean limitByCursorForcedly) {
+        this._limitByCursorForcedly = limitByCursorForcedly;
+    }
+
+    // -----------------------------------------------------
+    //                                  Specified OutsideSql
+    //                                  --------------------
+    public String getOutsideSqlPath() {
+        return _outsideSqlPath;
+    }
+
+    public void setOutsideSqlPath(String outsideSqlPath) {
+        this._outsideSqlPath = outsideSqlPath;
+    }
+
+    public Object getParameterBean() {
+        return _parameterBean;
+    }
+
+    public void setParameterBean(Object parameterBean) {
+        this._parameterBean = parameterBean;
+    }
+
+    public Object getResultTypeSpecification() {
+        return _resultTypeSpecification;
+    }
+
+    public void setResultTypeSpecification(Object resultTypeSpecification) {
+        this._resultTypeSpecification = resultTypeSpecification;
+    }
+
+    public String getMethodName() {
+        return _methodName;
+    }
+
+    public void setMethodName(String methodName) {
+        this._methodName = methodName;
+    }
+
+    public StatementConfig getStatementConfig() {
+        return _statementConfig;
+    }
+
+    public void setStatementConfig(StatementConfig statementConfig) {
+        this._statementConfig = statementConfig;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlContext.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlDao.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlDao.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlDao.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,29 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.outsidesql;
+
+import java.util.List;
+
+import jp.sf.pal.announcement.db.allcommon.DaoReadable;
+import jp.sf.pal.announcement.db.allcommon.jdbc.CursorHandler;
+
+/**
+ * The dao of outside-sql.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface OutsideSqlDao extends DaoReadable {
+
+    // ===================================================================================
+    //                                                                              Select
+    //                                                                              ======
+    <ENTITY> List<ENTITY> selectList(String path, Object pmb,
+            OutsideSqlOption option, Class<ENTITY> entityType);
+
+    <ENTITY> Object selectCursor(String path, Object pmb,
+            OutsideSqlOption option, CursorHandler handler);
+
+    // ===================================================================================
+    //                                                                             Execute
+    //                                                                             =======
+    int execute(String path, Object pmb, OutsideSqlOption option);
+
+    // int[] batchExecute(String path, List<Object> pmb, OutsideSqlOption option);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlDao.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,86 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.outsidesql;
+
+import jp.sf.pal.announcement.db.allcommon.jdbc.StatementConfig;
+
+/**
+ * The option of outside-sql.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class OutsideSqlOption {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected String _pagingRequestType = "non";
+
+    protected boolean _dynamicBinding;
+
+    /** The config of statement. (Nullable) */
+    protected StatementConfig _statementConfig;
+
+    // ===================================================================================
+    //                                                                         Easy-to-Use
+    //                                                                         ===========
+    public void autoPaging() {
+        _pagingRequestType = "auto";
+    }
+
+    public void manualPaging() {
+        _pagingRequestType = "manual";
+    }
+
+    public void dynamicBinding() {
+        _dynamicBinding = true;
+    }
+
+    // ===================================================================================
+    //                                                                          Unique Key
+    //                                                                          ==========
+    public String generateUniqueKey() {
+        return "{" + _pagingRequestType + "/" + _dynamicBinding + "}";
+    }
+
+    // ===================================================================================
+    //                                                                                Copy
+    //                                                                                ====
+    public OutsideSqlOption copyOptionWithoutPaging() {
+        final OutsideSqlOption copyOption = new OutsideSqlOption();
+        if (isDynamicBinding()) {
+            copyOption.dynamicBinding();
+        }
+        return copyOption;
+    }
+
+    // ===================================================================================
+    //                                                                      Basic Override
+    //                                                                      ==============
+    @Override
+    public String toString() {
+        return "{paging=" + _pagingRequestType + ", dynamic=" + _dynamicBinding
+                + "}";
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    public boolean isAutoPaging() {
+        return "auto".equals(_pagingRequestType);
+    }
+
+    public boolean isManualPaging() {
+        return "manual".equals(_pagingRequestType);
+    }
+
+    public boolean isDynamicBinding() {
+        return _dynamicBinding;
+    }
+
+    public StatementConfig getStatementConfig() {
+        return _statementConfig;
+    }
+
+    public void setStatementConfig(StatementConfig statementConfig) {
+        this._statementConfig = statementConfig;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/OutsideSqlOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlBasicExecutor.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlBasicExecutor.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlBasicExecutor.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,201 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.executor;
+
+import java.util.List;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.OutsideSqlDao;
+import jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.OutsideSqlOption;
+import jp.sf.pal.announcement.db.allcommon.jdbc.StatementConfig;
+
+/**
+ * The executor of outside-sql. <br />
+ * <pre>
+ * {Basic}
+ *   o selectList()
+ * 
+ * {Entity}
+ *   o entityHandling().selectEntity()
+ *   o entityHandling().selectEntityWithDeletedCheck()
+ * 
+ * {Cursor}
+ *   o cursorHandling().selectCursor()
+ * 
+ * {Paging}
+ *   o autoPaging().selectList()
+ *   o autoPaging().selectPage()
+ *   o manualPaging().selectList()
+ *   o manualPaging().selectPage()
+ * 
+ * {Option -- Dynamic}
+ *   o dynamicBinding().selectList()
+ * 
+ * </pre>
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class OutsideSqlBasicExecutor {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** The dao of outsideSql. (NotNull) */
+    protected final OutsideSqlDao _outsideSqlDao;
+
+    /** Table db name. (NotNull) */
+    protected final String _tableDbName;
+
+    /** Is it dynamic binding? */
+    protected boolean _dynamicBinding;
+
+    /** The config of statement. (Nullable) */
+    protected StatementConfig _statementConfig;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    public OutsideSqlBasicExecutor(OutsideSqlDao outsideSqlDao,
+            String tableDbName) {
+        this._outsideSqlDao = outsideSqlDao;
+        this._tableDbName = tableDbName;
+    }
+
+    // ===================================================================================
+    //                                                                              Select
+    //                                                                              ======
+    /**
+     * Select list.
+     * 
+     * @param <ENTITY> The type of entity for element.
+     * @param path The path of SQL file. (NotNull)
+     * @param pmb The parameter-bean. Allowed types are Bean object and Map object. (Nullable)
+     * @param entityType The element type of entity. (NotNull)
+     * @return The list of selected entity. (NotNull)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.OutsideSqlNotFoundException When the sql is not found.
+     */
+    public <ENTITY> List<ENTITY> selectList(String path, Object pmb,
+            Class<ENTITY> entityType) {
+        return _outsideSqlDao.selectList(path, pmb, createOutsideSqlOption(),
+                entityType);
+    }
+
+    // ===================================================================================
+    //                                                                             Execute
+    //                                                                             =======
+    /**
+     * Execute. {Insert/Update/Delete/Etc...}
+     * 
+     * @param path The path of SQL file. (NotNull)
+     * @param pmb The parameter-bean. Allowed types are Bean object and Map object. (Nullable)
+     * @return The count of execution.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.OutsideSqlNotFoundException When the sql is not found.
+     */
+    public int execute(String path, Object pmb) {
+        return _outsideSqlDao.execute(path, pmb, createOutsideSqlOption());
+    }
+
+    // Implements at the future!
+    //    public int batchExecute(String path, Object pmb) {
+    //        throw new UnsupportedOperationException("Sorry! The method of batchExecute() has not been implemented yet.");
+    //        // return _outsideSqlDao.batchExecute(path, pmb, createOutsideSqlOption());
+    //    }
+
+    // ===================================================================================
+    //                                                                              Option
+    //                                                                              ======
+    /**
+     * Specify cursor handling. <br />
+     * <pre>
+     * # ex) Your Program
+     * #
+     * # executor.cursorHandling().selectCursor(path, pmb, handler);
+     * #
+     * </pre>
+     * @return The cursor executor of outside-sql. (NotNull)
+     */
+    public OutsideSqlCursorExecutor<Object> cursorHandling() {
+        return new OutsideSqlCursorExecutor<Object>(_outsideSqlDao,
+                createOutsideSqlOption());
+    }
+
+    /**
+     * Specify entity handling. <br />
+     * <pre>
+     * # ex) Your Program
+     * #
+     * # executor.entityHandling().selectEntityWithDeletedCheck(path, pmb, Xxx.class);
+     * #
+     * </pre>
+     * @return The cursor executor of outside-sql. (NotNull)
+     */
+    public OutsideSqlEntityExecutor<Object> entityHandling() {
+        return new OutsideSqlEntityExecutor<Object>(_outsideSqlDao,
+                createOutsideSqlOption());
+    }
+
+    /**
+     * Option of autoPaging. <br />
+     * If you invoke this, you don't need to write paging condition on your SQL. <br />
+     * <pre>
+     * # ex) Your SQL {MySQL}
+     * #
+     * # select member.MEMBER_ID, member...
+     * #   from Member member
+     * #  where ...
+     * #  order by ...
+     * # -- limit 40, 20        *Here is unnecessary!
+     * #
+     * </pre>
+     * 
+     * @return The executor of paging that the paging mode is auto. (NotNull)
+     */
+    public OutsideSqlPagingExecutor autoPaging() {
+        final OutsideSqlOption option = createOutsideSqlOption();
+        option.autoPaging();
+        return new OutsideSqlPagingExecutor(_outsideSqlDao, option,
+                _tableDbName);
+    }
+
+    /**
+     * Option of manualPaging. <br />
+     * If you invoke this, you need to write paging condition on your SQL. <br />
+     * <pre>
+     * # ex) Your SQL {MySQL}
+     * #
+     * # select member.MEMBER_ID, member...
+     * #   from Member member
+     * #  where ...
+     * #  order by ...
+     * #  limit 40, 20        *Here is necessary!
+     * #
+     * </pre>
+     * 
+     * @return The executor of paging that the paging mode is manual. (NotNull)
+     */
+    public OutsideSqlPagingExecutor manualPaging() {
+        final OutsideSqlOption option = createOutsideSqlOption();
+        option.manualPaging();
+        return new OutsideSqlPagingExecutor(_outsideSqlDao, option,
+                _tableDbName);
+    }
+
+    public OutsideSqlBasicExecutor configure(StatementConfig statementConfig) {
+        _statementConfig = statementConfig;
+        return this;
+    }
+
+    public OutsideSqlBasicExecutor dynamicBinding() {
+        _dynamicBinding = true;
+        return this;
+    }
+
+    // -----------------------------------------------------
+    //                                                Helper
+    //                                                ------
+    protected OutsideSqlOption createOutsideSqlOption() {
+        final OutsideSqlOption option = new OutsideSqlOption();
+        option.setStatementConfig(_statementConfig);
+        if (_dynamicBinding) {
+            option.dynamicBinding();
+        }
+        return option;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlBasicExecutor.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlCursorExecutor.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlCursorExecutor.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlCursorExecutor.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,54 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.executor;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.OutsideSqlDao;
+import jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.OutsideSqlOption;
+import jp.sf.pal.announcement.db.allcommon.jdbc.CursorHandler;
+import jp.sf.pal.announcement.db.allcommon.jdbc.StatementConfig;
+
+/**
+ * The cursor executor of outside-sql.
+ * 
+ * @param <PARAMETER_BEAN> The type of parameter-bean.
+ * @author DBFlute(AutoGenerator)
+ */
+public class OutsideSqlCursorExecutor<PARAMETER_BEAN> {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected final OutsideSqlDao _outsideSqlDao;
+
+    protected final OutsideSqlOption _outsideSqlOption;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    public OutsideSqlCursorExecutor(OutsideSqlDao outsideSqlDao,
+            OutsideSqlOption outsideSqlOption) {
+        this._outsideSqlDao = outsideSqlDao;
+        this._outsideSqlOption = outsideSqlOption;
+    }
+
+    // ===================================================================================
+    //                                                                              Select
+    //                                                                              ======
+    public Object selectCursor(String path, PARAMETER_BEAN pmb,
+            CursorHandler handler) {
+        return _outsideSqlDao.selectCursor(path, pmb, _outsideSqlOption,
+                handler);
+    }
+
+    // ===================================================================================
+    //                                                                              Option
+    //                                                                              ======
+    public OutsideSqlCursorExecutor<PARAMETER_BEAN> configure(
+            StatementConfig statementConfig) {
+        _outsideSqlOption.setStatementConfig(statementConfig);
+        return this;
+    }
+
+    public OutsideSqlCursorExecutor<PARAMETER_BEAN> dynamicBinding() {
+        _outsideSqlOption.dynamicBinding();
+        return this;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlCursorExecutor.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlEntityExecutor.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlEntityExecutor.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlEntityExecutor.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,118 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.executor;
+
+import java.util.List;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.ConditionBeanContext;
+import jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.OutsideSqlDao;
+import jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.OutsideSqlOption;
+import jp.sf.pal.announcement.db.allcommon.jdbc.StatementConfig;
+
+/**
+ * The cursor executor of outside-sql.
+ * 
+ * @param <PARAMETER_BEAN> The type of parameter-bean.
+ * @author DBFlute(AutoGenerator)
+ */
+public class OutsideSqlEntityExecutor<PARAMETER_BEAN> {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected final OutsideSqlDao _outsideSqlDao;
+
+    protected final OutsideSqlOption _outsideSqlOption;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    public OutsideSqlEntityExecutor(OutsideSqlDao outsideSqlDao,
+            OutsideSqlOption outsideSqlOption) {
+        this._outsideSqlDao = outsideSqlDao;
+        this._outsideSqlOption = outsideSqlOption;
+    }
+
+    // ===================================================================================
+    //                                                                              Select
+    //                                                                              ======
+    /**
+     * Select entity.
+     * 
+     * @param <ENTITY> The type of entity.
+     * @param path The path of SQL file. (NotNull)
+     * @param pmb The parameter-bean. Allowed types are Bean object and Map object. (Nullable)
+     * @param entityType The type of entity. (NotNull)
+     * @return The selected entity. (Nullable)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.OutsideSqlNotFoundException When the sql is not found.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException
+     */
+    public <ENTITY> ENTITY selectEntity(String path, PARAMETER_BEAN pmb,
+            Class<ENTITY> entityType) {
+        final List<ENTITY> ls = _outsideSqlDao.selectList(path, pmb,
+                _outsideSqlOption, entityType);
+        if (ls.isEmpty()) {
+            return null;
+        }
+        if (ls.size() > 1) {
+            String searchKey4Log = "The path of outside-sql is " + path
+                    + ". And the parameter bean is " + pmb;
+            throwEntityDuplicatedException(ls.size() + "", searchKey4Log, null);
+        }
+        return ls.get(0);
+    }
+
+    /**
+     * Select entity with deleted check.
+     * 
+     * @param <ENTITY> The type of entity.
+     * @param path The path of SQL file. (NotNull)
+     * @param pmb The parameter-bean. Allowed types are Bean object and Map object. (Nullable)
+     * @param entityType The type of entity. (NotNull)
+     * @return The selected entity. (Nullable)
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.OutsideSqlNotFoundException When the sql is not found.
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityAlreadyDeletedException When the entity has already been deleted(not found).
+     * @exception jp.sf.pal.announcement.db.allcommon.exception.EntityDuplicatedException When the entity is duplicated.
+     */
+    public <ENTITY> ENTITY selectEntityWithDeletedCheck(String path,
+            PARAMETER_BEAN pmb, Class<ENTITY> entityType) {
+        final List<ENTITY> ls = _outsideSqlDao.selectList(path, pmb,
+                _outsideSqlOption, entityType);
+        if (ls == null || ls.isEmpty()) {
+            String searchKey4Log = "The path of outside-sql is " + path
+                    + ". And the parameter bean is " + pmb;
+            throwEntityAlreadyDeletedException(searchKey4Log);
+        }
+        if (ls.size() > 1) {
+            String searchKey4Log = "The path of outside-sql is " + path
+                    + ". And the parameter bean is " + pmb;
+            throwEntityDuplicatedException(ls.size() + "", searchKey4Log, null);
+        }
+        return ls.get(0);
+    }
+
+    // -----------------------------------------------------
+    //                                                Helper
+    //                                                ------
+    protected void throwEntityAlreadyDeletedException(Object searchKey4Log) {
+        ConditionBeanContext.throwEntityAlreadyDeletedException(searchKey4Log);
+    }
+
+    protected void throwEntityDuplicatedException(String resultCountString,
+            Object searchKey4Log, Throwable cause) {
+        ConditionBeanContext.throwEntityDuplicatedException(resultCountString,
+                searchKey4Log, cause);
+    }
+
+    // ===================================================================================
+    //                                                                              Option
+    //                                                                              ======
+    public OutsideSqlEntityExecutor<PARAMETER_BEAN> configure(
+            StatementConfig statementConfig) {
+        _outsideSqlOption.setStatementConfig(statementConfig);
+        return this;
+    }
+
+    public OutsideSqlEntityExecutor<PARAMETER_BEAN> dynamicBinding() {
+        _outsideSqlOption.dynamicBinding();
+        return this;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlEntityExecutor.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlPagingExecutor.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlPagingExecutor.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlPagingExecutor.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,152 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.executor;
+
+import java.util.List;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingBean;
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingHandler;
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingInvoker;
+import jp.sf.pal.announcement.db.allcommon.cbean.PagingResultBean;
+import jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.OutsideSqlDao;
+import jp.sf.pal.announcement.db.allcommon.cbean.outsidesql.OutsideSqlOption;
+import jp.sf.pal.announcement.db.allcommon.jdbc.StatementConfig;
+
+/**
+ * The paging executor of outsideSql.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class OutsideSqlPagingExecutor {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** The DAO of outsideSql. (NotNull) */
+    protected final OutsideSqlDao _outsideSqlDao;
+
+    /** The option of outsideSql. (NotNull) */
+    protected final OutsideSqlOption _outsideSqlOption;
+
+    /** The DB name of table. (NotNull) */
+    protected final String _tableDbName;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    public OutsideSqlPagingExecutor(OutsideSqlDao outsideSqlDao,
+            OutsideSqlOption outsideSqlOption, String tableDbName) {
+        this._outsideSqlDao = outsideSqlDao;
+        this._outsideSqlOption = outsideSqlOption;
+        this._tableDbName = tableDbName;
+    }
+
+    // ===================================================================================
+    //                                                                              Select
+    //                                                                              ======
+    public <ENTITY> List<ENTITY> selectList(String path, PagingBean pmb,
+            Class<ENTITY> entityType) {
+        return _outsideSqlDao.selectList(path, pmb, _outsideSqlOption,
+                entityType);
+    }
+
+    /**
+     * Select page.
+     * <p>
+     * The SQL should have Count and Paging. <br />
+     * You can realize by pagingBean's isPaging() method on your 'SQL Comment'. For example, 'IF Comment'. <br />
+     * It returns false when it executes Count. And it returns true when it executes Paging. <br />
+     * <pre>
+     * - - - - - - - - - - - - - - - - - - - - - - -
+     * ex) Your Correct SQL {MySQL and manualPaging}
+     * - - - - - - - - - - - - - - - - - - - - - - -
+     * # /[*]IF pmb.isPaging()[*]/
+     * # select member.MEMBER_ID
+     * #      , member.MEMBER_NAME
+     * #      , memberStatus.MEMBER_STATUS_NAME
+     * # -- ELSE select count(*)
+     * # /[*]END[*]/
+     * #   from MEMBER member
+     * #     /[*]IF pmb.isPaging()[*]/
+     * #     left outer join MEMBER_STATUS memberStatus
+     * #       on member.MEMBER_STATUS_CODE = memberStatus.MEMBER_STATUS_CODE
+     * #     /[*]END[*]/
+     * #  /[*]BEGIN[*]/where
+     * #    /[*]IF pmb.memberId != null[*]/member.MEMBER_ID = /[*]pmb.memberId[*]/'123'/[*]END[*]/
+     * #    /[*]IF pmb.memberName != null[*]/and member.MEMBER_NAME like /[*]pmb.memberName[*]/'Billy' || '%'/[*]END[*]/
+     * #  /[*]END[*]/
+     * #  /[*]IF pmb.isPaging()[*]/
+     * #  order by member.UPDATE_DATETIME desc
+     * #  /[*]END[*]/
+     * #  /[*]IF pmb.isPaging()[*]/
+     * #  limit /[*]$pmb.pageStartIndex[*]/80, /[*]$pmb.fetchSize[*]/20
+     * #  /[*]END[*]/
+     * # 
+     * o [*] is easy escape to Java Doc Comment.
+     * o If it's autoPaging, the line of 'limit 80, 20' is unnecessary!
+     * 
+     * - - - - - - - - - - - - - - - - - - - - - - - - -
+     * ex) Wrong SQL {part 1}
+     *     -- Line comment before ELSE comment --
+     * - - - - - - - - - - - - - - - - - - - - - - - - -
+     * # /[*]IF pmb.isPaging()[*]/
+     * # select member.MEMBER_ID
+     * #      , member.MEMBER_NAME -- The name of member...    *NG
+     * #      -- The status name of member...                  *NG
+     * #      , memberStatus.MEMBER_STATUS_NAME
+     * # -- ELSE select count(*)
+     * # /[*]END[*]/
+     * # ...
+     * o It's S2Dao's restriction...Sorry
+     * </pre>
+     * 
+     * @param <ENTITY> The type of entity.
+     * @param path The path of SQL that executes count and paging. (NotNull)
+     * @param pagingPath The path of paging SQL. (NotNull)
+     * @param pmb The bean of paging parameter. (NotNull)
+     * @param entityType The type of result entity. (NotNull)
+     * @return The result bean of paging. (NotNull)
+     */
+    public <ENTITY> PagingResultBean<ENTITY> selectPage(final String path,
+            final PagingBean pmb, final Class<ENTITY> entityType) {
+        final OutsideSqlOption countOption = _outsideSqlOption
+                .copyOptionWithoutPaging();
+        final OutsideSqlEntityExecutor<PagingBean> countExecutor = new OutsideSqlEntityExecutor<PagingBean>(
+                _outsideSqlDao, countOption);
+        final PagingHandler<ENTITY> handler = new PagingHandler<ENTITY>() {
+            public PagingBean getPagingBean() {
+                return pmb;
+            }
+
+            public int count() {
+                pmb.xsetPaging(false);
+                return countExecutor.selectEntityWithDeletedCheck(path, pmb,
+                        Integer.class);
+            }
+
+            public java.util.List<ENTITY> paging() {
+                pmb.xsetPaging(true);
+                return selectList(path, pmb, entityType);
+            }
+        };
+        final PagingInvoker<ENTITY> invoker = new PagingInvoker<ENTITY>(
+                _tableDbName);
+        return invoker.invokePaging(handler);
+    }
+
+    // ===================================================================================
+    //                                                                              Option
+    //                                                                              ======
+    public OutsideSqlCursorExecutor<PagingBean> cursorHandling() {
+        return new OutsideSqlCursorExecutor<PagingBean>(_outsideSqlDao,
+                _outsideSqlOption);
+    }
+
+    public OutsideSqlPagingExecutor configure(StatementConfig statementConfig) {
+        _outsideSqlOption.setStatementConfig(statementConfig);
+        return this;
+    }
+
+    public OutsideSqlPagingExecutor dynamicBinding() {
+        _outsideSqlOption.dynamicBinding();
+        return this;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/outsidesql/executor/OutsideSqlPagingExecutor.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/PageNumberLink.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/PageNumberLink.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/PageNumberLink.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,84 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.pagenavi;
+
+/**
+ * The class of page number link.
+ * @author DBFlute(AutoGenerator)
+ */
+public class PageNumberLink implements java.io.Serializable {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Serial version UID. (Default) */
+    private static final long serialVersionUID = 1L;
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected int _pageNumberElement;
+
+    protected boolean _current;
+
+    protected String _pageNumberLinkHref;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    public PageNumberLink() {
+    }
+
+    // ===================================================================================
+    //                                                                         Initializer
+    //                                                                         ===========
+    public PageNumberLink initialize(int pageNumberElement, boolean current,
+            String pageNumberLinkHref) {
+        setPageNumberElement(pageNumberElement);
+        setCurrent(current);
+        setPageNumberLinkHref(pageNumberLinkHref);
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                      Basic Override
+    //                                                                      ==============
+    /**
+     * @return The view string of all attribute values. (NotNull)
+     */
+    @Override
+    public String toString() {
+        final StringBuffer sb = new StringBuffer();
+
+        sb.append(" pageNumberElement=").append(_pageNumberElement);
+        sb.append(" pageNumberLinkHref=").append(_pageNumberLinkHref);
+        sb.append(" current=").append(_current);
+
+        return sb.toString();
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    public int getPageNumberElement() {
+        return _pageNumberElement;
+    }
+
+    public void setPageNumberElement(int pageNumberElement) {
+        this._pageNumberElement = pageNumberElement;
+    }
+
+    public boolean isCurrent() {
+        return _current;
+    }
+
+    public void setCurrent(boolean current) {
+        this._current = current;
+    }
+
+    public String getPageNumberLinkHref() {
+        return _pageNumberLinkHref;
+    }
+
+    public void setPageNumberLinkHref(String pageNumberLinkHref) {
+        this._pageNumberLinkHref = pageNumberLinkHref;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/PageNumberLink.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/PageNumberLinkSetupper.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/PageNumberLinkSetupper.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/PageNumberLinkSetupper.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,17 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.pagenavi;
+
+/**
+ * The setupper of page number link.
+ * @param <LINK> The type of link.
+ * @author DBFlute(AutoGenerator)
+ */
+public interface PageNumberLinkSetupper<LINK extends PageNumberLink> {
+
+    /**
+     * Set up page number link.
+     * @param pageNumberElement Page number element.
+     * @param current Is current page?
+     * @return Page number link. (NotNull)
+     */
+    public LINK setup(int pageNumberElement, boolean current);
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/PageNumberLinkSetupper.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/group/PageGroupBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/group/PageGroupBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/group/PageGroupBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,203 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.group;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.PageNumberLink;
+import jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.PageNumberLinkSetupper;
+
+/**
+ * The bean of page group.
+ * @author DBFlute(AutoGenerator)
+ */
+public class PageGroupBean implements java.io.Serializable {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Serial version UID. (Default) */
+    private static final long serialVersionUID = 1L;
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected int _currentPageNumber;
+
+    protected int _allPageCount;
+
+    protected PageGroupOption _pageGroupOption;
+
+    // ===================================================================================
+    //                                                                                Main
+    //                                                                                ====
+    /**
+     * Build the list of page number link.
+     * @param <LINK> The type of link.
+     * @param pageNumberLinkSetupper Page number link setupper. (NotNull and Required LINK)
+     * @return The list of Page number link. (NotNull)
+     */
+    public <LINK extends PageNumberLink> List<LINK> buildPageNumberLinkList(
+            PageNumberLinkSetupper<LINK> pageNumberLinkSetupper) {
+        final List<Integer> pageNumberList = createPageNumberList();
+        final List<LINK> pageNumberLinkList = new ArrayList<LINK>();
+        for (Integer pageNumber : pageNumberList) {
+            pageNumberLinkList.add(pageNumberLinkSetupper.setup(pageNumber,
+                    pageNumber.equals(_currentPageNumber)));
+        }
+        return pageNumberLinkList;
+    }
+
+    /**
+     * Calculate start page number.
+     * @return Start page number.
+     */
+    public int calculateStartPageNumber() {
+        assertPageGroupValid();
+        final int pageGroupSize = _pageGroupOption.getPageGroupSize();
+        final int currentPageNumber = _currentPageNumber;
+
+        int currentPageGroupNumber = (currentPageNumber / pageGroupSize);
+        if ((currentPageNumber % pageGroupSize) == 0) {
+            currentPageGroupNumber--;
+        }
+        final int currentPageGroupStartPageNumber = (pageGroupSize * currentPageGroupNumber) + 1;
+        if (!(currentPageNumber >= currentPageGroupStartPageNumber)) {
+            String msg = "currentPageNumber should be greater equal currentPageGroupStartPageNumber. But:";
+            msg = msg + " currentPageNumber=" + currentPageNumber;
+            msg = msg + " currentPageGroupStartPageNumber="
+                    + currentPageGroupStartPageNumber;
+            throw new IllegalStateException(msg);
+        }
+        return currentPageGroupStartPageNumber;
+    }
+
+    /**
+     * Create the list of page number.
+     * @return The list of page number. (NotNull)
+     */
+    public List<Integer> createPageNumberList() {
+        assertPageGroupValid();
+        final int pageGroupSize = _pageGroupOption.getPageGroupSize();
+        final int allPageCount = _allPageCount;
+        final int currentPageGroupStartPageNumber = calculateStartPageNumber();
+        if (!(currentPageGroupStartPageNumber > 0)) {
+            String msg = "currentPageGroupStartPageNumber should be greater than 0. {> 0} But:";
+            msg = msg + " currentPageGroupStartPageNumber="
+                    + currentPageGroupStartPageNumber;
+            throw new IllegalStateException(msg);
+        }
+        final int nextPageGroupStartPageNumber = currentPageGroupStartPageNumber
+                + pageGroupSize;
+
+        final List<Integer> resultList = new ArrayList<Integer>();
+        for (int i = currentPageGroupStartPageNumber; i < nextPageGroupStartPageNumber
+                && i <= allPageCount; i++) {
+            resultList.add(new Integer(i));
+        }
+        return resultList;
+    }
+
+    /**
+     * Create the array of page number.
+     * @return The array of page number. (NotNUll)
+     */
+    public int[] createPageNumberArray() {
+        assertPageGroupValid();
+        return convertListToIntArray(createPageNumberList());
+    }
+
+    /**
+     * Is existing previous page-group?
+     * Using values are currentPageNumber and pageGroupSize.
+     * 
+     * @return Determination.
+     */
+    public boolean isExistPrePageGroup() {
+        assertPageGroupValid();
+        return (_currentPageNumber > _pageGroupOption.getPageGroupSize());
+    }
+
+    /**
+     * Is existing next page-group?
+     * Using values are currentPageNumber and pageGroupSize and allPageCount.
+     * 
+     * @return Determination.
+     */
+    public boolean isExistNextPageGroup() {
+        assertPageGroupValid();
+        int currentPageGroupStartPageNumber = calculateStartPageNumber();
+        if (!(currentPageGroupStartPageNumber > 0)) {
+            String msg = "currentPageGroupStartPageNumber should be greater than 0. {> 0} But:";
+            msg = msg + " currentPageGroupStartPageNumber="
+                    + currentPageGroupStartPageNumber;
+            throw new IllegalStateException(msg);
+        }
+        int nextPageGroupStartPageNumber = currentPageGroupStartPageNumber
+                + _pageGroupOption.getPageGroupSize();
+        return (nextPageGroupStartPageNumber <= _allPageCount);
+    }
+
+    // ===================================================================================
+    //                                                                       Assist Helper
+    //                                                                       =============
+    protected int[] convertListToIntArray(List<Integer> ls) {
+        final int[] resultArray = new int[ls.size()];
+        int arrayIndex = 0;
+        for (Iterator ite = ls.iterator(); ite.hasNext();) {
+            final Integer tmpPageNumber = (Integer) ite.next();
+            resultArray[arrayIndex] = tmpPageNumber.intValue();
+            arrayIndex++;
+        }
+        return resultArray;
+    }
+
+    protected void assertPageGroupValid() {
+        if (_pageGroupOption == null) {
+            String msg = "The pageGroupOption should not be null. Please invoke setPageGroupOption().";
+            throw new IllegalStateException(msg);
+        }
+        if (_pageGroupOption.getPageGroupSize() == 0) {
+            String msg = "The pageGroupSize should be greater than 1. But the value is zero.";
+            msg = msg + " pageGroupSize=" + _pageGroupOption.getPageGroupSize();
+            throw new IllegalStateException(msg);
+        }
+        if (_pageGroupOption.getPageGroupSize() == 1) {
+            String msg = "The pageGroupSize should be greater than 1. But the value is one.";
+            msg = msg + " pageGroupSize=" + _pageGroupOption.getPageGroupSize();
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                      Basic Override
+    //                                                                      ==============
+    /**
+     * @return The view string of all attribute values. (NotNull)
+     */
+    @Override
+    public String toString() {
+        final StringBuilder sb = new StringBuilder();
+
+        sb.append(" currentPageNumber=").append(_currentPageNumber);
+        sb.append(" allPageCount=").append(_allPageCount);
+        sb.append(" pageGroupOption=").append(_pageGroupOption);
+
+        return sb.toString();
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    public void setCurrentPageNumber(int currentPageNumber) {
+        this._currentPageNumber = currentPageNumber;
+    }
+
+    public void setAllPageCount(int allPageCount) {
+        this._allPageCount = allPageCount;
+    }
+
+    public void setPageGroupOption(PageGroupOption pageGroupOption) {
+        this._pageGroupOption = pageGroupOption;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/group/PageGroupBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/group/PageGroupOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/group/PageGroupOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/group/PageGroupOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,45 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.group;
+
+/**
+ * The option of page group.
+ * @author DBFlute(AutoGenerator)
+ */
+public class PageGroupOption implements java.io.Serializable {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Serial version UID. (Default) */
+    private static final long serialVersionUID = 1L;
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected int _pageGroupSize;
+
+    // ===================================================================================
+    //                                                                      Basic Override
+    //                                                                      ==============
+    /**
+     * @return The view string of all attribute values. (NotNull)
+     */
+    @Override
+    public String toString() {
+        final StringBuilder sb = new StringBuilder();
+
+        sb.append(" pageGroupSize=").append(_pageGroupSize);
+
+        return sb.toString();
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    public int getPageGroupSize() {
+        return _pageGroupSize;
+    }
+
+    public void setPageGroupSize(int pageGroupSize) {
+        this._pageGroupSize = pageGroupSize;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/group/PageGroupOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/range/PageRangeBean.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/range/PageRangeBean.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/range/PageRangeBean.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,189 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.range;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.PageNumberLink;
+import jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.PageNumberLinkSetupper;
+
+/**
+ * The bean of page range.
+ * @author DBFlute(AutoGenerator)
+ */
+public class PageRangeBean implements java.io.Serializable {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Serial version UID. (Default) */
+    private static final long serialVersionUID = 1L;
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected int _currentPageNumber;
+
+    protected int _allPageCount;
+
+    protected PageRangeOption _pageRangeOption;
+
+    // ===================================================================================
+    //                                                                                Main
+    //                                                                                ====
+    /**
+     * Build the list of page number link.
+     * @param <LINK> The type of link.
+     * @param pageNumberLinkSetupper Page number link setupper. (NotNull and Required LINK)
+     * @return The list of Page number link. (NotNull)
+     */
+    public <LINK extends PageNumberLink> List<LINK> buildPageNumberLinkList(
+            PageNumberLinkSetupper<LINK> pageNumberLinkSetupper) {
+        final List<Integer> pageNumberList = createPageNumberList();
+        final List<LINK> pageNumberLinkList = new ArrayList<LINK>();
+        for (Integer pageNumber : pageNumberList) {
+            pageNumberLinkList.add(pageNumberLinkSetupper.setup(pageNumber,
+                    pageNumber.equals(_currentPageNumber)));
+        }
+        return pageNumberLinkList;
+    }
+
+    /**
+     * Create the list of page number.
+     * @return The list of page number. (NotNull)
+     */
+    public List<Integer> createPageNumberList() {
+        assertPageRangeValid();
+        final int pageRangeSize = _pageRangeOption.getPageRangeSize();
+        final int allPageCount = _allPageCount;
+        final int currentPageNumber = _currentPageNumber;
+
+        final List<Integer> resultList = new ArrayList<Integer>();
+        for (int i = currentPageNumber - pageRangeSize; i < currentPageNumber; i++) {
+            if (i < 1) {
+                continue;
+            }
+            resultList.add(new Integer(i));
+        }
+
+        resultList.add(new Integer(currentPageNumber));
+
+        final int endPageNumber = (currentPageNumber + pageRangeSize);
+        for (int i = currentPageNumber + 1; i <= endPageNumber
+                && i <= allPageCount; i++) {
+            resultList.add(new Integer(i));
+        }
+
+        final boolean fillLimit = _pageRangeOption.isFillLimit();
+        final int limitSize = (pageRangeSize * 2) + 1;
+        if (fillLimit && !resultList.isEmpty() && resultList.size() < limitSize) {
+            final Integer firstElements = (Integer) resultList.get(0);
+            final Integer lastElements = (Integer) resultList.get(resultList
+                    .size() - 1);
+            if (firstElements.intValue() > 1) {
+                for (int i = firstElements.intValue() - 1; resultList.size() < limitSize
+                        && i > 0; i--) {
+                    resultList.add(0, new Integer(i));
+                }
+            }
+            for (int i = lastElements.intValue() + 1; resultList.size() < limitSize
+                    && i <= allPageCount; i++) {
+                resultList.add(new Integer(i));
+            }
+        }
+        return resultList;
+    }
+
+    /**
+     * Get the array of page number.
+     * @return The array of page number. (NotNull)
+     */
+    public int[] createPageNumberArray() {
+        assertPageRangeValid();
+        return convertListToIntArray(createPageNumberList());
+    }
+
+    /**
+     * Is existing previous page range?
+     * @return Determination.
+     */
+    public boolean isExistPrePageRange() {
+        assertPageRangeValid();
+        final int[] array = createPageNumberArray();
+        if (array.length == 0) {
+            return false;
+        }
+        return array[0] > 1;
+    }
+
+    /**
+     * Is existing next page range?
+     * @return Determination.
+     */
+    public boolean isExistNextPageRange() {
+        assertPageRangeValid();
+        final int[] array = createPageNumberArray();
+        if (array.length == 0) {
+            return false;
+        }
+        return array[array.length - 1] < _allPageCount;
+    }
+
+    // ===================================================================================
+    //                                                                       Assist Helper
+    //                                                                       =============
+    protected int[] convertListToIntArray(List<Integer> ls) {
+        final int[] resultArray = new int[ls.size()];
+        int arrayIndex = 0;
+        for (Iterator ite = ls.iterator(); ite.hasNext();) {
+            final Integer tmpPageNumber = (Integer) ite.next();
+            resultArray[arrayIndex] = tmpPageNumber.intValue();
+            arrayIndex++;
+        }
+        return resultArray;
+    }
+
+    protected void assertPageRangeValid() {
+        if (_pageRangeOption == null) {
+            String msg = "The pageRangeOption should not be null. Please invoke setPageRangeOption().";
+            throw new IllegalStateException(msg);
+        }
+        final int pageRangeSize = _pageRangeOption.getPageRangeSize();
+        if (pageRangeSize == 0) {
+            String msg = "The pageRangeSize should be greater than 1. But the value is zero.";
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    public void setCurrentPageNumber(int currentPageNumber) {
+        this._currentPageNumber = currentPageNumber;
+    }
+
+    public void setAllPageCount(int allPageCount) {
+        this._allPageCount = allPageCount;
+    }
+
+    public void setPageRangeOption(PageRangeOption pageRangeOption) {
+        this._pageRangeOption = pageRangeOption;
+    }
+
+    // ===================================================================================
+    //                                                                      Basic Override
+    //                                                                      ==============
+    /**
+     * @return The view string of all attribute values. (NotNull)
+     */
+    @Override
+    public String toString() {
+        final StringBuilder sb = new StringBuilder();
+
+        sb.append(" currentPageNumber=").append(_currentPageNumber);
+        sb.append(" allPageCount=").append(_allPageCount);
+        sb.append(" pageRangeOption=").append(_pageRangeOption);
+
+        return sb.toString();
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/range/PageRangeBean.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/range/PageRangeOption.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/range/PageRangeOption.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/range/PageRangeOption.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,56 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.pagenavi.range;
+
+/**
+ * The option of page range.
+ * @author DBFlute(AutoGenerator)
+ */
+public class PageRangeOption implements java.io.Serializable {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Serial version UID. (Default) */
+    private static final long serialVersionUID = 1L;
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    protected int _pageRangeSize;
+
+    protected boolean _fillLimit;
+
+    // ===================================================================================
+    //                                                                      Basic Override
+    //                                                                      ==============
+    /**
+     * @return The view string of all attribute values. (NotNull)
+     */
+    @Override
+    public String toString() {
+        final StringBuilder sb = new StringBuilder();
+
+        sb.append(" pageRangeSize=").append(_pageRangeSize);
+        sb.append(" fillLimit=").append(_fillLimit);
+
+        return sb.toString();
+    }
+
+    // ===================================================================================
+    //                                                                            Accessor
+    //                                                                            ========
+    public int getPageRangeSize() {
+        return _pageRangeSize;
+    }
+
+    public void setPageRangeSize(int pageRangeSize) {
+        this._pageRangeSize = pageRangeSize;
+    }
+
+    public boolean isFillLimit() {
+        return _fillLimit;
+    }
+
+    public void setFillLimit(boolean fillLimit) {
+        this._fillLimit = fillLimit;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/pagenavi/range/PageRangeOption.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/AbstractSqlClause.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/AbstractSqlClause.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/AbstractSqlClause.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,1343 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import java.util.StringTokenizer;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.ckey.ConditionKey;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMeta;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMetaInstanceHandler;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.ColumnInfo;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.ForeignInfo;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.UniqueInfo;
+import jp.sf.pal.announcement.db.allcommon.util.SimpleAssertUtil;
+import jp.sf.pal.announcement.db.allcommon.util.SimpleStringUtil;
+import jp.sf.pal.announcement.db.allcommon.util.SimpleSystemUtil;
+
+/**
+ * The abstract class of SqlClause.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+ @ SuppressWarnings("unchecked")
+public abstract class AbstractSqlClause implements SqlClause {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    protected static final String SELECT_HINT = "/*$dto.selectHint*/";
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    // -----------------------------------------------------
+    //                                                 Basic
+    //                                                 -----
+    /** Target table name. */
+    protected final String _tableName;
+
+    // -----------------------------------------------------
+    //                                       Clause Resource
+    //                                       ---------------
+    /** Selected select column map. map:{tableAliasName : map:{columnName : selectColumnInfo}}*/
+    protected Map<String, Map<String, SelectedSelectColumnInfo>> _selectedSelectColumnMap = new LinkedHashMap<String, Map<String, SelectedSelectColumnInfo>>();
+
+    /** Included select column map. */
+    protected Map<String, String> _includedSelectColumnMap = new LinkedHashMap<String, String>();
+
+    /** The map of real column and alias of select clause. map:{realColumnName : aliasName} */
+    protected Map<String, String> _selectClauseRealColumnAliasMap = new HashMap<String, String>();// Without linked!
+
+    /** Outer join map. */
+    protected Map<String, LeftOuterJoinInfo> _outerJoinMap = new LinkedHashMap<String, LeftOuterJoinInfo>();
+
+    /** Where list. */
+    protected List<String> _whereList = new ArrayList<String>();
+
+    /** Inline where list for BaseTable. */
+    protected List<String> _baseTableInlineWhereList = new ArrayList<String>();
+
+    /** Order-by clause. */
+    protected final OrderByClause _orderByClause = new OrderByClause();
+
+    /** Union clause list. */
+    protected List<UnionQueryInfo> _unionQueryInfoList = new ArrayList<UnionQueryInfo>();
+
+    /** Is included-select-column effective? Default value is false. */
+    protected boolean _isIncludedSelectColumnEffective = false;
+
+    /** Is order-by effective? Default value is false. */
+    protected boolean _isOrderByEffective = false;
+
+    // -----------------------------------------------------
+    //                                        Fetch Property
+    //                                        --------------
+    /** Fetch start index. (for fetchXxx()) */
+    protected int _fetchStartIndex = 0;
+
+    /** Fetch size. (for fetchXxx()) */
+    protected int _fetchSize = 0;
+
+    /** Fetch page number. (for fetchXxx()) This value should be plus. */
+    protected int _fetchPageNumber = 1;
+
+    /** Is fetch-narrowing effective? Default value is false. */
+    protected boolean _isFetchScopeEffective = false;
+
+    // -----------------------------------------------------
+    //                               AdditionalConditionAsOr
+    //                               -----------------------
+    /** Is additional condition as or effective?*/
+    protected boolean _isAdditionalConditionAsOrEffective = false;
+
+    // -----------------------------------------------------
+    //                               WhereClauseSimpleFilter
+    //                               -----------------------
+    /** The filter for where clause. */
+    protected List<WhereClauseSimpleFilter> _whereClauseSimpleFilterList;
+
+    // -----------------------------------------------------
+    //                                 Selected Foreign Info
+    //                                 ---------------------
+    /** The information of selected foreign table. */
+    protected Map<String, String> _selectedForeignInfo;
+
+    // -----------------------------------------------------
+    //                                         Optional Info
+    //                                         -------------
+    protected boolean _formatClause;
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    public AbstractSqlClause(String tableName) {
+        if (tableName == null) {
+            String msg = "Argument[tableName] must not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+        _tableName = tableName;
+    }
+
+    // ===================================================================================
+    //                                                                              Clause
+    //                                                                              ======
+    public String getClause() {
+        final StringBuilder sb = new StringBuilder(512);
+        sb.append(getSelectClause());
+        sb.append(" ");
+        sb.append(buildClauseWithoutMainSelect(false));
+        return sb.toString();
+    }
+
+    public String getClausePKOnly() {
+        final StringBuilder sb = new StringBuilder(512);
+        sb.append(getSelectClausePKOnly());
+        sb.append(" ");
+        sb.append(buildClauseWithoutMainSelect(true));
+        return sb.toString();
+    }
+
+    protected String buildClauseWithoutMainSelect(boolean pkonly) {
+        final StringBuilder sb = new StringBuilder(512);
+        sb.append(getFromClause());
+        sb.append(getFromHint());
+        sb.append(" ");
+        sb.append(getWhereClause());
+        String unionClause = buildUnionClause(pkonly ? getSelectClausePKOnly()
+                : getSelectClause());
+
+        // Delete template mark! (At the future this will be unnecessary.)
+        unionClause = replaceString(unionClause, getUnionWhereClauseMark(), "");// Required!
+        unionClause = replaceString(unionClause,
+                getUnionWhereFirstConditionMark(), "");// Required!
+
+        sb.append(unionClause);
+        if (_isOrderByEffective && !_orderByClause.isEmpty()) {
+            sb.append(" ");
+            sb.append(getOrderByClause());
+        }
+        sb.append(" ");
+        sb.append(getSqlSuffix());
+        return sb.toString();
+    }
+
+    public String getClauseFromWhereWithUnionTemplate() {
+        return buildClauseFromWhereAsTemplate(false);
+    }
+
+    public String getClauseFromWhereWithWhereUnionTemplate() {
+        return buildClauseFromWhereAsTemplate(true);
+    }
+
+    protected String buildClauseFromWhereAsTemplate(boolean template) {
+        final StringBuilder sb = new StringBuilder(512);
+        sb.append(getFromClause());
+        sb.append(getFromHint());
+        sb.append(" ");
+        sb.append(buildWhereClause(template));
+        sb.append(buildUnionClause(getUnionSelectClauseMark()));
+        return sb.toString();
+    }
+
+    protected String buildUnionClause(String selectClause) {
+        final StringBuilder sb = new StringBuilder();
+        for (final Iterator<UnionQueryInfo> ite = _unionQueryInfoList
+                .iterator(); ite.hasNext();) {
+            final UnionQueryInfo unionQueryInfo = (UnionQueryInfo) ite.next();
+            final String unionQueryClause = unionQueryInfo
+                    .getUnionQueryClause();
+            final boolean unionAll = unionQueryInfo.isUnionAll();
+            if (isFormatClauseEffective()) {
+                sb.append(getLineSeparator());
+            }
+            sb.append(unionAll ? " union all " : " union ");
+            if (isFormatClauseEffective()) {
+                sb.append(getLineSeparator());
+            }
+            sb.append(selectClause).append(" ").append(unionQueryClause);
+        }
+        return sb.toString();
+    }
+
+    // ===================================================================================
+    //                                                                        Clause Parts
+    //                                                                        ============
+    public String getSelectClause() {
+        final StringBuilder sb = new StringBuilder();
+        final DBMeta dbmeta = DBMetaInstanceHandler.findDBMeta(_tableName);
+        final List<ColumnInfo> columnInfoList = dbmeta.getColumnInfoList();
+        for (ColumnInfo columnInfo : columnInfoList) {
+            final String columnName = columnInfo.getColumnDbName();
+            if (sb.length() > 0) {
+                sb.append(", ");
+            } else {
+                sb.append("select").append(SELECT_HINT).append(" ");
+            }
+            final String realColumnName = getLocalTableAliasName() + "."
+                    + columnName;
+            sb.append(realColumnName).append(" as ").append(columnName);
+            _selectClauseRealColumnAliasMap.put(realColumnName, columnName);
+        }
+        final Set<String> tableAliasNameSet = _selectedSelectColumnMap.keySet();
+        for (String tableAliasName : tableAliasNameSet) {
+            final Map<String, SelectedSelectColumnInfo> map = _selectedSelectColumnMap
+                    .get(tableAliasName);
+            final Collection<SelectedSelectColumnInfo> selectColumnInfoList = map
+                    .values();
+            for (SelectedSelectColumnInfo selectColumnInfo : selectColumnInfoList) {
+                final String realColumnName = selectColumnInfo
+                        .buildRealColumnName();
+                sb.append(", ").append(realColumnName).append(" as ").append(
+                        selectColumnInfo.getColumnAliasName());
+                _selectClauseRealColumnAliasMap.put(realColumnName,
+                        selectColumnInfo.getColumnAliasName());
+            }
+        }
+        if (_isIncludedSelectColumnEffective
+                && !_includedSelectColumnMap.isEmpty()) {
+            sb.append(getIncludedSelectColumnClause());
+        }
+        return sb.toString();
+    }
+
+    public String getSelectClausePKOnly() {
+        final StringBuilder sb = new StringBuilder();
+        final DBMeta dbmeta = DBMetaInstanceHandler.findDBMeta(_tableName);
+        final UniqueInfo uniqueInfo = dbmeta.getPrimaryUniqueInfo();
+        final List<ColumnInfo> columnInfoList = uniqueInfo
+                .getUniqueColumnList();
+        for (ColumnInfo columnInfo : columnInfoList) {
+            final String columnName = columnInfo.getColumnDbName();
+            if (sb.length() > 0) {
+                sb.append(", ");
+            } else {
+                sb.append("select").append(SELECT_HINT).append(" ");
+            }
+            final String realColumnName = getLocalTableAliasName() + "."
+                    + columnName;
+            sb.append(realColumnName).append(" as ").append(columnName);
+            _selectClauseRealColumnAliasMap.put(realColumnName, columnName);
+        }
+        if (_isIncludedSelectColumnEffective
+                && !_includedSelectColumnMap.isEmpty()) {
+            sb.append(getIncludedSelectColumnClause());
+        }
+        return sb.toString();
+    }
+
+    public String getSelectHint() {
+        return createSelectHint();
+    }
+
+    public String getIncludedSelectColumnClause() {
+        final StringBuilder sb = new StringBuilder();
+        int count = 0;
+        for (final Iterator<String> ite = _includedSelectColumnMap.keySet()
+                .iterator(); ite.hasNext(); count++) {
+            final String aliasName = ite.next();
+            final String realColumnName = (String) _includedSelectColumnMap
+                    .get(aliasName);
+            sb.append(", ").append(realColumnName).append(" as ").append(
+                    aliasName);
+            _selectClauseRealColumnAliasMap.put(realColumnName, aliasName);
+        }
+        return sb.toString();
+    }
+
+    public String getFromClause() {
+        final StringBuilder sb = new StringBuilder();
+        if (isFormatClauseEffective()) {
+            sb.append(getLineSeparator()).append("  ");
+        }
+        sb.append("from ");
+        if (_baseTableInlineWhereList.isEmpty()) {
+            sb.append(_tableName).append(" dflocal");
+        } else {
+            sb.append(
+                    getInlineViewClause(_tableName, _baseTableInlineWhereList))
+                    .append(" dflocal");
+        }
+        sb.append(getFromBaseTableHint());
+        sb.append(getLeftOuterJoinClause());
+        return sb.toString();
+    }
+
+    protected String getLeftOuterJoinClause() {
+        final StringBuilder sb = new StringBuilder();
+        for (final Iterator<String> ite = _outerJoinMap.keySet().iterator(); ite
+                .hasNext();) {
+            final String aliasName = ite.next();
+            final LeftOuterJoinInfo joinInfo = (LeftOuterJoinInfo) _outerJoinMap
+                    .get(aliasName);
+            final String joinTableName = joinInfo.getJoinTableName();
+            final List<String> inlineWhereClauseList = joinInfo
+                    .getInlineWhereClauseList();
+            final List<String> additionalOnClauseList = joinInfo
+                    .getAdditionalOnClauseList();
+            final Map<String, String> joinOnMap = joinInfo.getJoinOnMap();
+            assertJoinOnMapNotEmpty(joinOnMap, aliasName);
+
+            if (isFormatClauseEffective()) {
+                sb.append(getLineSeparator()).append("   ");
+            }
+            sb.append(" left outer join ");
+            if (inlineWhereClauseList.isEmpty()) {
+                sb.append(joinTableName);
+            } else {
+                sb.append(getInlineViewClause(joinTableName,
+                        inlineWhereClauseList));
+            }
+            sb.append(" ").append(aliasName).append(" on ");
+            int count = 0;
+            final Set<String> localColumnNameSet = joinOnMap.keySet();
+            for (String localColumnName : localColumnNameSet) {
+                final String foreignColumnName = (String) joinOnMap
+                        .get(localColumnName);
+                if (count > 0) {
+                    sb.append(" and ");
+                }
+                if (localColumnName.equals("$$fixedCondition$$")) {
+                    sb.append(foreignColumnName);
+                } else {
+                    sb.append(localColumnName).append(" = ").append(
+                            foreignColumnName);
+                }
+                ++count;
+            }
+            for (String additionalOnClause : additionalOnClauseList) {
+                sb.append(" and ").append(additionalOnClause);
+            }
+        }
+        return sb.toString();
+    }
+
+    protected String getInlineViewClause(String joinTableName,
+            List<String> inlineWhereClauseList) {
+        final StringBuilder sb = new StringBuilder();
+        sb.append("(select * from ").append(joinTableName).append(" where ");
+        int count = 0;
+        for (final Iterator<String> ite = inlineWhereClauseList.iterator(); ite
+                .hasNext();) {
+            String clauseElement = ite.next();
+            clauseElement = filterWhereClauseSimply(clauseElement);
+            if (count > 0) {
+                sb.append(" and ");
+            }
+            sb.append(clauseElement);
+            ++count;
+        }
+        sb.append(")");
+        return sb.toString();
+    }
+
+    public String getFromBaseTableHint() {
+        return createFromBaseTableHint();
+    }
+
+    public String getFromHint() {
+        return createFromHint();
+    }
+
+    public String getWhereClause() {
+        return buildWhereClause(false);
+    }
+
+    protected String buildWhereClause(boolean template) {
+        final StringBuilder sb = new StringBuilder();
+        int count = 0;
+        for (final Iterator<String> ite = _whereList.iterator(); ite.hasNext(); count++) {
+            String clauseElement = (String) ite.next();
+            clauseElement = filterWhereClauseSimply(clauseElement);
+            if (count == 0) {
+                if (isFormatClauseEffective()) {
+                    sb.append(getLineSeparator()).append(" ");
+                }
+                sb.append("where ").append(
+                        template ? getWhereFirstConditionMark() : "").append(
+                        clauseElement);
+            } else {
+                if (isFormatClauseEffective()) {
+                    sb.append(getLineSeparator()).append("  ");
+                }
+                sb.append(" and ").append(clauseElement);
+            }
+        }
+        if (template && sb.length() == 0) {
+            sb.append(getWhereClauseMark());
+        }
+        return sb.toString();
+    }
+
+    public String getOrderByClause() {
+        final String orderByClause;
+        if (!_unionQueryInfoList.isEmpty()) {
+            if (_selectClauseRealColumnAliasMap == null
+                    || _selectClauseRealColumnAliasMap.isEmpty()) {
+                String msg = "The selectClauseColumnAliasMap should not be null or empty when union query exists: "
+                        + toString();
+                throw new IllegalStateException(msg);
+            }
+            orderByClause = _orderByClause
+                    .getOrderByClause(_selectClauseRealColumnAliasMap);
+        } else {
+            orderByClause = _orderByClause.getOrderByClause();
+        }
+        if (isFormatClauseEffective() && orderByClause != null
+                && orderByClause.trim().length() > 0) {
+            return getLineSeparator() + " " + orderByClause;
+        } else {
+            return orderByClause;
+        }
+    }
+
+    public String getSqlSuffix() {
+        final String sqlSuffix = createSqlSuffix();
+        if (isFormatClauseEffective() && sqlSuffix != null
+                && sqlSuffix.trim().length() > 0) {
+            return getLineSeparator() + sqlSuffix;
+        } else {
+            return sqlSuffix;
+        }
+    }
+
+    // ===================================================================================
+    //                                                                          Copy Parts
+    //                                                                          ==========
+    public void copyIncludedSelectColumn(SqlClause sqlClause) {
+        final Set<String> keySet = _includedSelectColumnMap.keySet();
+        for (final Iterator<String> ite = keySet.iterator(); ite.hasNext();) {
+            final String aliasName = ite.next();
+            final String realColumnName = (String) _includedSelectColumnMap
+                    .get(aliasName);
+            sqlClause.registerIncludedSelectColumn(aliasName, realColumnName);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                SelectedSelectColumn
+    //                                                                ====================
+    /**
+     * Register selected select column.
+     * 
+     * @param foreignTableAliasName The alias name of foreign table. (NotNull)
+     * @param localTableName The table name of local. (NotNull)
+     * @param foreignPropertyName The property name of foreign table. (NotNull)
+     * @param localRelationPath The path of local relation. (Nullable)
+     */
+    public void registerSelectedSelectColumn(String foreignTableAliasName,
+            String localTableName, String foreignPropertyName,
+            String localRelationPath) {
+        _selectedSelectColumnMap
+                .put(foreignTableAliasName, createSelectedSelectColumnInfo(
+                        foreignTableAliasName, localTableName,
+                        foreignPropertyName, localRelationPath));
+    }
+
+    protected Map<String, SelectedSelectColumnInfo> createSelectedSelectColumnInfo(
+            String foreignTableAliasName, String localTableName,
+            String foreignPropertyName, String localRelationPath) {
+        final DBMeta dbmeta = DBMetaInstanceHandler.findDBMeta(localTableName);
+        final ForeignInfo foreignInfo = dbmeta
+                .findForeignInfo(foreignPropertyName);
+        final int relationNo = foreignInfo.getRelationNo();
+        String nextRelationPath = "_" + relationNo;
+        if (localRelationPath != null) {
+            nextRelationPath = localRelationPath + nextRelationPath;
+        }
+        final Map<String, SelectedSelectColumnInfo> resultMap = new LinkedHashMap<String, SelectedSelectColumnInfo>();
+        final DBMeta foreignDBMeta = foreignInfo.getForeignDBMeta();
+        final List<ColumnInfo> columnInfoList = foreignDBMeta
+                .getColumnInfoList();
+        for (ColumnInfo columnInfo : columnInfoList) {
+            final String columnDbName = columnInfo.getColumnDbName();
+            final SelectedSelectColumnInfo selectColumnInfo = new SelectedSelectColumnInfo();
+            selectColumnInfo.setTableAliasName(foreignTableAliasName);
+            selectColumnInfo.setColumnName(columnDbName);
+            selectColumnInfo
+                    .setColumnAliasName(columnDbName + nextRelationPath);
+            resultMap.put(columnDbName, selectColumnInfo);
+        }
+        return resultMap;
+    }
+
+    public static class SelectedSelectColumnInfo {
+        protected String tableAliasName;
+
+        protected String columnName;
+
+        protected String columnAliasName;
+
+        public String buildRealColumnName() {
+            if (tableAliasName != null) {
+                return tableAliasName + "." + columnName;
+            } else {
+                return columnName;
+            }
+        }
+
+        public String getTableAliasName() {
+            return tableAliasName;
+        }
+
+        public void setTableAliasName(String tableAliasName) {
+            this.tableAliasName = tableAliasName;
+        }
+
+        public String getColumnName() {
+            return columnName;
+        }
+
+        public void setColumnName(String columnName) {
+            this.columnName = columnName;
+        }
+
+        public String getColumnAliasName() {
+            return columnAliasName;
+        }
+
+        public void setColumnAliasName(String columnAliasName) {
+            this.columnAliasName = columnAliasName;
+        }
+    }
+
+    // ===================================================================================
+    //                                                                IncludedSelectColumn
+    //                                                                ====================
+    public void ignoreIncludedSelectColumn() {
+        _isIncludedSelectColumnEffective = false;
+    }
+
+    public void makeIncludedSelectColumnEffective() {
+        if (!_includedSelectColumnMap.isEmpty()) {
+            _isIncludedSelectColumnEffective = true;
+        }
+    }
+
+    public void registerIncludedSelectColumn(String aliasName,
+            String realColumnName) {
+        _isIncludedSelectColumnEffective = true;
+        _includedSelectColumnMap.put(aliasName, realColumnName);
+    }
+
+    // ===================================================================================
+    //                                                                           OuterJoin
+    //                                                                           =========
+    public void registerOuterJoin(String joinTableName, String aliasName,
+            Map<String, String> joinOnMap) {
+        assertAlreadyOuterJoin(aliasName);
+        assertJoinOnMapNotEmpty(joinOnMap, aliasName);
+        final LeftOuterJoinInfo joinInfo = new LeftOuterJoinInfo();
+        joinInfo.setAliasName(aliasName);
+        joinInfo.setJoinTableName(joinTableName);
+        joinInfo.setJoinOnMap(joinOnMap);
+        _outerJoinMap.put(aliasName, joinInfo);
+    }
+
+    protected static class LeftOuterJoinInfo {
+        protected String _aliasName;
+
+        protected String _joinTableName;
+
+        protected List<String> _inlineWhereClauseList = new ArrayList<String>();
+
+        protected List<String> _additionalOnClauseList = new ArrayList<String>();
+
+        protected Map<String, String> _joinOnMap;
+
+        protected boolean _onClauseInline;
+
+        public String getAliasName() {
+            return _aliasName;
+        }
+
+        public void setAliasName(String value) {
+            _aliasName = value;
+        }
+
+        public String getJoinTableName() {
+            return _joinTableName;
+        }
+
+        public void setJoinTableName(String value) {
+            _joinTableName = value;
+        }
+
+        public List<String> getInlineWhereClauseList() {
+            return _inlineWhereClauseList;
+        }
+
+        public void addInlineWhereClause(String value) {
+            _inlineWhereClauseList.add(value);
+        }
+
+        public List<String> getAdditionalOnClauseList() {
+            return _additionalOnClauseList;
+        }
+
+        public void addAdditionalOnClause(String value) {
+            _additionalOnClauseList.add(value);
+        }
+
+        public Map<String, String> getJoinOnMap() {
+            return _joinOnMap;
+        }
+
+        public void setJoinOnMap(Map<String, String> value) {
+            _joinOnMap = value;
+        }
+
+        public boolean isOnClauseInline() {
+            return _onClauseInline;
+        }
+
+        public void setOnClauseInline(boolean value) {
+            _onClauseInline = value;
+        }
+    }
+
+    protected void assertAlreadyOuterJoin(String aliasName) {
+        if (_outerJoinMap.containsKey(aliasName)) {
+            String msg = "The alias name have already registered in outer join: "
+                    + aliasName;
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    protected void assertJoinOnMapNotEmpty(Map<String, String> joinOnMap,
+            String aliasName) {
+        if (joinOnMap.isEmpty()) {
+            String msg = "The joinOnMap should not be empty: aliasName="
+                    + aliasName;
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                               Where
+    //                                                                               =====
+    public void registerWhereClause(String columnFullName, ConditionKey key,
+            ConditionValue value) {
+        assertStringNotNullAndNotTrimmedEmpty("columnFullName", columnFullName);
+        key.addWhereClause(_whereList, columnFullName, value);
+        arrangeWhereListAdditionalConditionAsOr(_whereList);
+    }
+
+    public void registerWhereClause(String columnFullName, ConditionKey key,
+            ConditionValue value, ConditionOption option) {
+        assertStringNotNullAndNotTrimmedEmpty("columnFullName", columnFullName);
+        assertObjectNotNull("option of " + columnFullName, option);
+        key.addWhereClause(_whereList, columnFullName, value, option);
+        arrangeWhereListAdditionalConditionAsOr(_whereList);
+    }
+
+    public void registerWhereClause(String clause) {
+        assertStringNotNullAndNotTrimmedEmpty("clause", clause);
+        _whereList.add(clause);
+        arrangeWhereListAdditionalConditionAsOr(_whereList);
+    }
+
+    public void exchangeFirstWhereClauseForLastOne() {
+        if (_whereList.size() > 1) {
+            final String first = (String) _whereList.get(0);
+            final String last = (String) _whereList.get(_whereList.size() - 1);
+            _whereList.set(0, last);
+            _whereList.set(_whereList.size() - 1, first);
+        }
+    }
+
+    // ===================================================================================
+    //                                                                         InlineWhere
+    //                                                                         ===========
+    public void registerBaseTableInlineWhereClause(String columnName,
+            ConditionKey key, ConditionValue value) {
+        assertStringNotNullAndNotTrimmedEmpty("columnName", columnName);
+        key.addWhereClause(_baseTableInlineWhereList, columnName, value);
+        arrangeWhereListAdditionalConditionAsOr(_baseTableInlineWhereList);
+    }
+
+    public void registerBaseTableInlineWhereClause(String columnName,
+            ConditionKey key, ConditionValue value, ConditionOption option) {
+        assertStringNotNullAndNotTrimmedEmpty("columnName", columnName);
+        assertObjectNotNull("option of " + columnName, option);
+        key
+                .addWhereClause(_baseTableInlineWhereList, columnName, value,
+                        option);
+        arrangeWhereListAdditionalConditionAsOr(_baseTableInlineWhereList);
+    }
+
+    public void registerBaseTableInlineWhereClause(String value) {
+        _baseTableInlineWhereList.add(value);
+    }
+
+    public void registerOuterJoinInlineWhereClause(String aliasName,
+            String columnName, ConditionKey key, ConditionValue value,
+            boolean onClauseInline) {
+        assertNotYetOuterJoin(aliasName);
+        assertStringNotNullAndNotTrimmedEmpty("columnName", columnName);
+        final LeftOuterJoinInfo joinInfo = (LeftOuterJoinInfo) _outerJoinMap
+                .get(aliasName);
+        if (onClauseInline) {
+            key.addWhereClause(joinInfo.getAdditionalOnClauseList(), aliasName
+                    + "." + columnName, value);
+        } else {
+            key.addWhereClause(joinInfo.getInlineWhereClauseList(), columnName,
+                    value);
+        }
+        arrangeWhereListAdditionalConditionAsOr(joinInfo
+                .getInlineWhereClauseList());
+    }
+
+    public void registerOuterJoinInlineWhereClause(String aliasName,
+            String columnName, ConditionKey key, ConditionValue value,
+            ConditionOption option, boolean onClauseInline) {
+        assertNotYetOuterJoin(aliasName);
+        assertStringNotNullAndNotTrimmedEmpty("columnName", columnName);
+        final LeftOuterJoinInfo joinInfo = (LeftOuterJoinInfo) _outerJoinMap
+                .get(aliasName);
+        if (onClauseInline) {
+            key.addWhereClause(joinInfo.getAdditionalOnClauseList(), aliasName
+                    + "." + columnName, value, option);
+            arrangeWhereListAdditionalConditionAsOr(joinInfo
+                    .getAdditionalOnClauseList());
+        } else {
+            key.addWhereClause(joinInfo.getInlineWhereClauseList(), columnName,
+                    value, option);
+            arrangeWhereListAdditionalConditionAsOr(joinInfo
+                    .getInlineWhereClauseList());
+        }
+    }
+
+    public void registerOuterJoinInlineWhereClause(String aliasName,
+            String value, boolean onClauseInline) {
+        assertNotYetOuterJoin(aliasName);
+        final LeftOuterJoinInfo joinInfo = (LeftOuterJoinInfo) _outerJoinMap
+                .get(aliasName);
+        if (onClauseInline) {
+            joinInfo.addAdditionalOnClause(value);
+            arrangeWhereListAdditionalConditionAsOr(joinInfo
+                    .getAdditionalOnClauseList());
+        } else {
+            joinInfo.addInlineWhereClause(value);
+            arrangeWhereListAdditionalConditionAsOr(joinInfo
+                    .getInlineWhereClauseList());
+        }
+    }
+
+    protected void assertNotYetOuterJoin(String aliasName) {
+        if (!_outerJoinMap.containsKey(aliasName)) {
+            String msg = "The alias name have not registered in outer join yet: "
+                    + aliasName;
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    // ===================================================================================
+    //                                                             AdditionalConditionAsOr
+    //                                                             =======================
+    public void makeAdditionalConditionAsOrEffective() {
+        _isAdditionalConditionAsOrEffective = true;
+    }
+
+    public void ignoreAdditionalConditionAsOr() {
+        _isAdditionalConditionAsOrEffective = false;
+    }
+
+    protected void arrangeWhereListAdditionalConditionAsOr(
+            List<String> whereList) {
+        if (_isAdditionalConditionAsOrEffective) {
+            if (whereList.size() < 2) {
+                String msg = "The whereList should have two more elements when the isAdditionalConditionAsOrEffective is true: "
+                        + toString();
+                throw new IllegalStateException(msg);
+            }
+            final String lastWhereClause = (String) whereList.remove(whereList
+                    .size() - 1);
+            final String preWhereClause = (String) whereList.remove(whereList
+                    .size() - 1);
+            if (preWhereClause.startsWith("(") && preWhereClause.endsWith(")")) {
+                final String plainClause = preWhereClause.substring("("
+                        .length(), preWhereClause.length() - ")".length());
+                whereList.add("(" + plainClause + " or " + lastWhereClause
+                        + ")");
+            } else {
+                whereList.add("(" + preWhereClause + " or " + lastWhereClause
+                        + ")");
+            }
+        }
+    }
+
+    // ===================================================================================
+    //                                                                             OrderBy
+    //                                                                             =======
+    public OrderByClause getSqlComponentOfOrderByClause() {
+        return _orderByClause;
+    }
+
+    public SqlClause clearOrderBy() {
+        _isOrderByEffective = false;
+        _orderByClause.clear();
+        return this;
+    }
+
+    public SqlClause ignoreOrderBy() {
+        _isOrderByEffective = false;
+        return this;
+    }
+
+    public SqlClause makeOrderByEffective() {
+        if (!_orderByClause.isEmpty()) {
+            _isOrderByEffective = true;
+        }
+        return this;
+    }
+
+    public void reverseOrderBy_Or_OverrideOrderBy(String orderByProperty,
+            String registeredOrderByProperty, boolean ascOrDesc) {
+        _isOrderByEffective = true;
+        if (!_orderByClause.isSameOrderByColumn(orderByProperty)) {
+            clearOrderBy();
+            registerOrderBy(orderByProperty, registeredOrderByProperty,
+                    ascOrDesc);
+        } else {
+            _orderByClause.reverseAll();
+        }
+    }
+
+    public void registerOrderBy(String orderByProperty,
+            String registeredOrderByProperty, boolean ascOrDesc) {
+        try {
+            _isOrderByEffective = true;
+            final List<String> orderByList = new ArrayList<String>();
+            {
+                final StringTokenizer st = new StringTokenizer(orderByProperty,
+                        "/");
+                while (st.hasMoreElements()) {
+                    orderByList.add(st.nextToken());
+                }
+            }
+
+            if (registeredOrderByProperty == null
+                    || registeredOrderByProperty.trim().length() == 0) {
+                registeredOrderByProperty = orderByProperty;
+            }
+
+            final List<String> registeredOrderByList = new ArrayList<String>();
+            {
+                final StringTokenizer st = new StringTokenizer(
+                        registeredOrderByProperty, "/");
+                while (st.hasMoreElements()) {
+                    registeredOrderByList.add(st.nextToken());
+                }
+            }
+
+            int count = 0;
+            for (final Iterator<String> ite = orderByList.iterator(); ite
+                    .hasNext();) {
+                String orderBy = ite.next();
+                String registeredOrderBy = (String) registeredOrderByList
+                        .get(count);
+
+                _isOrderByEffective = true;
+                String aliasName = null;
+                String columnName = null;
+                String registeredAliasName = null;
+                String registeredColumnName = null;
+
+                if (orderBy.indexOf(".") < 0) {
+                    columnName = orderBy;
+                } else {
+                    aliasName = orderBy.substring(0, orderBy.lastIndexOf("."));
+                    columnName = orderBy
+                            .substring(orderBy.lastIndexOf(".") + 1);
+                }
+
+                if (registeredOrderBy.indexOf(".") < 0) {
+                    registeredColumnName = registeredOrderBy;
+                } else {
+                    registeredAliasName = registeredOrderBy.substring(0,
+                            registeredOrderBy.lastIndexOf("."));
+                    registeredColumnName = registeredOrderBy
+                            .substring(registeredOrderBy.lastIndexOf(".") + 1);
+                }
+
+                OrderByElement element = new OrderByElement();
+                element.setAliasName(aliasName);
+                element.setColumnName(columnName);
+                element.setRegisteredAliasName(registeredAliasName);
+                element.setRegisteredColumnName(registeredColumnName);
+                if (ascOrDesc) {
+                    element.setupAsc();
+                } else {
+                    element.setupDesc();
+                }
+                _orderByClause.addOrderByElement(element);
+
+                count++;
+            }
+        } catch (RuntimeException e) {
+            String msg = "registerOrderBy() threw the exception: orderByProperty="
+                    + orderByProperty;
+            msg = msg + " registeredColumnFullName="
+                    + registeredOrderByProperty;
+            msg = msg + " ascOrDesc=" + ascOrDesc;
+            msg = msg + " sqlClause=" + this.toString();
+            throw new RuntimeException(msg, e);
+        }
+    }
+
+    public void addNullsFirstToPreviousOrderBy() {
+        _orderByClause
+                .addNullsFirstToPreviousOrderByElement(createOrderByNullsSetupper());
+    }
+
+    public void addNullsLastToPreviousOrderBy() {
+        _orderByClause
+                .addNullsLastToPreviousOrderByElement(createOrderByNullsSetupper());
+    }
+
+    protected OrderByClause.OrderByNullsSetupper createOrderByNullsSetupper() {// As Default
+        return new OrderByClause.OrderByNullsSetupper() {
+            public String setup(String columnName, String orderByElementClause,
+                    boolean nullsFirst) {
+                return orderByElementClause + " nulls "
+                        + (nullsFirst ? "first" : "last");
+            }
+        };
+    }
+
+    protected OrderByClause.OrderByNullsSetupper createOrderByNullsSetupperByCaseWhen() {// Helper For Nulls Unsupported Database
+        return new OrderByClause.OrderByNullsSetupper() {
+            public String setup(String columnName, String orderByElementClause,
+                    boolean nullsFirst) {
+                final String thenNumber = nullsFirst ? "1" : "0";
+                final String elseNumber = nullsFirst ? "0" : "1";
+                final String caseWhen = "case when " + columnName
+                        + " is not null then " + thenNumber + " else "
+                        + elseNumber + " end asc";
+                return caseWhen + ", " + orderByElementClause;
+            }
+        };
+    }
+
+    // ===================================================================================
+    //                                                                          UnionQuery
+    //                                                                          ==========
+    public void registerUnionQuery(String unionQueryClause, boolean unionAll) {
+        assertStringNotNullAndNotTrimmedEmpty("unionQueryClause",
+                unionQueryClause);
+        final UnionQueryInfo unionQueryInfo = new UnionQueryInfo();
+        unionQueryInfo.setUnionQueryClause(unionQueryClause);
+        unionQueryInfo.setUnionAll(unionAll);
+        _unionQueryInfoList.add(unionQueryInfo);
+    }
+
+    protected static class UnionQueryInfo {
+        protected String _unionQueryClause;
+
+        protected boolean _unionAll;
+
+        public String getUnionQueryClause() {
+            return _unionQueryClause;
+        }
+
+        public void setUnionQueryClause(String unionQueryClause) {
+            _unionQueryClause = unionQueryClause;
+        }
+
+        public boolean isUnionAll() {
+            return _unionAll;
+        }
+
+        public void setUnionAll(boolean unionAll) {
+            _unionAll = unionAll;
+        }
+    }
+
+    // ===================================================================================
+    //                                                                          FetchScope
+    //                                                                          ==========
+    /**
+     * @param fetchSize Fetch-size. (NotMinus & NotZero)
+     * @return this. (NotNull)
+     */
+    public SqlClause fetchFirst(int fetchSize) {
+        _isFetchScopeEffective = true;
+        if (fetchSize <= 0) {
+            String msg = "Argument[fetchSize] should be plus: " + fetchSize;
+            throw new IllegalArgumentException(msg);
+        }
+        _fetchStartIndex = 0;
+        _fetchSize = fetchSize;
+        _fetchPageNumber = 1;
+        doClearFetchPageClause();
+        doFetchFirst();
+        return this;
+    }
+
+    /**
+     * @param fetchStartIndex Fetch-start-index. 0 origin. (NotMinus)
+     * @param fetchSize Fetch size. (NotMinus)
+     * @return this. (NotNull)
+     */
+    public SqlClause fetchScope(int fetchStartIndex, int fetchSize) {
+        _isFetchScopeEffective = true;
+        if (fetchStartIndex < 0) {
+            String msg = "Argument[fetchStartIndex] must be plus or zero: "
+                    + fetchStartIndex;
+            throw new IllegalArgumentException(msg);
+        }
+        if (fetchSize <= 0) {
+            String msg = "Argument[fetchSize] should be plus: " + fetchSize;
+            throw new IllegalArgumentException(msg);
+        }
+        _fetchStartIndex = fetchStartIndex;
+        _fetchSize = fetchSize;
+        return fetchPage(1);
+    }
+
+    /**
+     * @param fetchPageNumber Page-number. 1 origin. (NotMinus & NotZero: If minus or zero, set one.)
+     * @return this. (NotNull)
+     */
+    public SqlClause fetchPage(int fetchPageNumber) {
+        _isFetchScopeEffective = true;
+        if (fetchPageNumber <= 0) {
+            fetchPageNumber = 1;
+        }
+        if (_fetchSize <= 0) {
+            String msg = "Look! Read the message below." + getLineSeparator();
+            msg = msg
+                    + "/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *"
+                    + getLineSeparator();
+            msg = msg + "Fetch size should not be minus or zero!"
+                    + getLineSeparator();
+            msg = msg + getLineSeparator();
+            msg = msg + "[Advice]" + getLineSeparator();
+            msg = msg
+                    + "When you invoke this method, it is necessary to invoke 'fetchFirst()' or 'fetchScope()' ahead of that. "
+                    + getLineSeparator();
+            msg = msg
+                    + "Please confirm your program. Does it really invoke 'fetchPage()' with 'fetchFirst()' or 'fetchScope()'?"
+                    + getLineSeparator();
+            msg = msg + "  For example:" + getLineSeparator();
+            msg = msg + "    before (x):" + getLineSeparator();
+            msg = msg + "      XxxCB cb = new XxxCB();" + getLineSeparator();
+            msg = msg + "      cb.fetchPage(3);" + getLineSeparator();
+            msg = msg + "    after  (o):" + getLineSeparator();
+            msg = msg + "      XxxCB cb = new XxxCB();" + getLineSeparator();
+            msg = msg + "      cb.fetchFirst(20); // The size of page"
+                    + getLineSeparator();
+            msg = msg + "      cb.fetchPage(3);   // The number of target page"
+                    + getLineSeparator();
+            msg = msg + getLineSeparator();
+            msg = msg + "[Actual Parameter Value]" + getLineSeparator();
+            msg = msg + "fetchSize=" + _fetchSize + getLineSeparator();
+            msg = msg + "fetchPageNumber=" + fetchPageNumber
+                    + getLineSeparator();
+            msg = msg + "* * * * * * * * * */" + getLineSeparator();
+            throw new IllegalStateException(msg);
+        }
+        _fetchPageNumber = fetchPageNumber;
+        if (_fetchPageNumber == 1 && _fetchStartIndex == 0) {
+            return fetchFirst(_fetchSize);
+        }
+        doClearFetchPageClause();
+        doFetchPage();
+        return this;
+    }
+
+    abstract protected void doFetchFirst();
+
+    abstract protected void doFetchPage();
+
+    abstract protected void doClearFetchPageClause();
+
+    public int getFetchStartIndex() {
+        return _fetchStartIndex;
+    }
+
+    public int getFetchSize() {
+        return _fetchSize;
+    }
+
+    public int getFetchPageNumber() {
+        return _fetchPageNumber;
+    }
+
+    /**
+     * @return Page start index. 0 origin. (NotMinus)
+     */
+    public int getPageStartIndex() {
+        if (_fetchPageNumber <= 0) {
+            String msg = "_fetchPageNumber must be plus: " + _fetchPageNumber;
+            throw new IllegalStateException(msg);
+        }
+        return _fetchStartIndex + (_fetchSize * (_fetchPageNumber - 1));
+    }
+
+    /**
+     * @return Page end index. 0 origin. (NotMinus)
+     */
+    public int getPageEndIndex() {
+        if (_fetchPageNumber <= 0) {
+            String msg = "_fetchPageNumber must be plus: " + _fetchPageNumber;
+            throw new IllegalStateException(msg);
+        }
+        return _fetchStartIndex + (_fetchSize * _fetchPageNumber);
+    }
+
+    public boolean isFetchScopeEffective() {
+        return _isFetchScopeEffective;
+    }
+
+    public SqlClause ignoreFetchScope() {
+        _isFetchScopeEffective = false;
+        doClearFetchPageClause();
+        return this;
+    }
+
+    public SqlClause makeFetchScopeEffective() {
+        if (getFetchSize() > 0 && getFetchPageNumber() > 0) {
+            fetchPage(getFetchPageNumber());
+        }
+        return this;
+    }
+
+    public boolean isFetchStartIndexSupported() {
+        return true; // Default
+    }
+
+    public boolean isFetchSizeSupported() {
+        return true; // Default
+    }
+
+    abstract protected String createSelectHint();
+
+    abstract protected String createFromBaseTableHint();
+
+    abstract protected String createFromHint();
+
+    abstract protected String createSqlSuffix();
+
+    // ===================================================================================
+    //                                                                     Fetch Narrowing
+    //                                                                     ===============
+    /**
+     * The implementation.
+     * 
+     * @return Fetch-narrowing start-index.
+     */
+    public int getFetchNarrowingSkipStartIndex() {
+        return getPageStartIndex();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Fetch-narrowing size.
+     */
+    public int getFetchNarrowingLoopCount() {
+        return getFetchSize();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Determiantion.
+     */
+    public boolean isFetchNarrowingEffective() {
+        return _isFetchScopeEffective;
+    }
+
+    // ===================================================================================
+    //                                                                            Resolver
+    //                                                                            ========
+    public String resolveJoinAliasName(String relationPath, int cqNestNo) {
+        return resolveNestLevelExpression("dfrelation" + relationPath, cqNestNo);
+    }
+
+    public String resolveNestLevelExpression(String name, int cqNestNo) {
+        // if (cqNestNo > 1) {
+        //     return name + "_n" + cqNestNo;
+        // } else {
+        //     return name;
+        // }
+        return name;
+    }
+
+    public int resolveRelationNo(String localTableName,
+            String foreignPropertyName) {
+        final DBMeta dbmeta = DBMetaInstanceHandler.findDBMeta(localTableName);
+        final ForeignInfo foreignInfo = dbmeta
+                .findForeignInfo(foreignPropertyName);
+        return foreignInfo.getRelationNo();
+    }
+
+    // ===================================================================================
+    //                                                                    Table Alias Info
+    //                                                                    ================
+    public String getLocalTableAliasName() {
+        return "dflocal";
+    }
+
+    public String getForeignTableAliasPrefix() {
+        return "dfrelation";
+    }
+
+    // ===================================================================================
+    //                                                                       Template Mark
+    //                                                                       =============
+    public String getWhereClauseMark() {
+        return "#df:whereClause#";
+    }
+
+    public String getWhereFirstConditionMark() {
+        return "#df:whereFirstCondition#";
+    }
+
+    public String getUnionSelectClauseMark() {
+        return "#df:unionSelectClause#";
+    }
+
+    public String getUnionWhereClauseMark() {
+        return "#df:unionWhereClause#";
+    }
+
+    public String getUnionWhereFirstConditionMark() {
+        return "#df:unionWhereFirstCondition#";
+    }
+
+    // =====================================================================================
+    //                                                            Where Clause Simple Filter
+    //                                                            ==========================
+    public void addWhereClauseSimpleFilter(
+            WhereClauseSimpleFilter whereClauseSimpleFilter) {
+        if (_whereClauseSimpleFilterList == null) {
+            _whereClauseSimpleFilterList = new ArrayList<WhereClauseSimpleFilter>();
+        }
+        _whereClauseSimpleFilterList.add(whereClauseSimpleFilter);
+    }
+
+    protected String filterWhereClauseSimply(String clauseElement) {
+        if (_whereClauseSimpleFilterList == null
+                || _whereClauseSimpleFilterList.isEmpty()) {
+            return clauseElement;
+        }
+        for (final Iterator<WhereClauseSimpleFilter> ite = _whereClauseSimpleFilterList
+                .iterator(); ite.hasNext();) {
+            final WhereClauseSimpleFilter filter = ite.next();
+            if (filter == null) {
+                String msg = "The list of filter should not have null: _whereClauseSimpleFilterList="
+                        + _whereClauseSimpleFilterList;
+                throw new IllegalStateException(msg);
+            }
+            clauseElement = filter.filterClauseElement(clauseElement);
+        }
+        return clauseElement;
+    }
+
+    // =====================================================================================
+    //                                                                 Selected Foreign Info
+    //                                                                 =====================
+    public boolean hasSelectedForeignInfo(String relationPath) {
+        if (_selectedForeignInfo == null) {
+            return false;
+        }
+        return _selectedForeignInfo.containsKey(relationPath);
+    }
+
+    public void registerSelectedForeignInfo(String relationPath,
+            String foreignPropertyName) {
+        if (_selectedForeignInfo == null) {
+            _selectedForeignInfo = new HashMap<String, String>();
+        }
+        _selectedForeignInfo.put(relationPath, foreignPropertyName);
+    }
+
+    // ===================================================================================
+    //                                                                       Format Clause
+    //                                                                       =============
+    public boolean isFormatClauseEffective() {
+        return _formatClause;
+    }
+
+    public void makeFormatClauseEffective() {
+        _formatClause = true;
+    }
+
+    // ===================================================================================
+    //                                                                              Helper
+    //                                                                              ======
+    protected final String replaceString(String text, String fromText,
+            String toText) {
+        return SimpleStringUtil.replace(text, fromText, toText);
+    }
+
+    protected String getLineSeparator() {
+        return SimpleSystemUtil.getLineSeparator();
+    }
+
+    // -----------------------------------------------------
+    //                                         Assert Object
+    //                                         -------------
+    protected void assertObjectNotNull(String variableName, Object value) {
+        SimpleAssertUtil.assertObjectNotNull(variableName, value);
+    }
+
+    // -----------------------------------------------------
+    //                                         Assert String
+    //                                         -------------
+    protected void assertStringNotNullAndNotTrimmedEmpty(String variableName,
+            String value) {
+        SimpleAssertUtil.assertStringNotNullAndNotTrimmedEmpty(variableName,
+                value);
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/AbstractSqlClause.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/OrderByClause.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/OrderByClause.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/OrderByClause.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,265 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.StringTokenizer;
+
+/**
+ * @author DBFlute(AutoGenerator)
+ */
+public class OrderByClause implements java.io.Serializable {
+
+    /** Serial version UID. (Default) */
+    private static final long serialVersionUID = 1L;
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    protected List<OrderByElement> _orderByList = new ArrayList<OrderByElement>();
+
+    // =====================================================================================
+    //                                                                           Constructor
+    //                                                                           ===========
+    /**
+     * Constructor.
+     */
+    public OrderByClause() {
+    }
+
+    // =====================================================================================
+    //                                                                              Behavior
+    //                                                                              ========
+    /**
+     * Add order-by element.
+     * @param orderByElement Order-by element. (NotNull)
+     */
+    public void addOrderByElement(OrderByElement orderByElement) {
+        _orderByList.add(orderByElement);
+    }
+
+    /**
+     * Insert first order-by element .
+     * @param orderByElement Order-by element. (NotNull)
+     */
+    public void insertFirstOrderByElement(OrderByElement orderByElement) {
+        _orderByList.add(0, orderByElement);
+    }
+
+    public void reverseAll() {
+        for (Iterator<OrderByElement> ite = _orderByList.iterator(); ite
+                .hasNext();) {
+            ite.next().reverse();
+        }
+    }
+
+    public void exchangeFirstOrderByElementForLastOne() {
+        if (_orderByList.size() > 1) {
+            final OrderByElement first = _orderByList.get(0);
+            final OrderByElement last = _orderByList
+                    .get(_orderByList.size() - 1);
+            _orderByList.set(0, last);
+            _orderByList.set(_orderByList.size() - 1, first);
+        }
+    }
+
+    public void addNullsFirstToPreviousOrderByElement(
+            OrderByNullsSetupper filter) {
+        if (_orderByList.isEmpty()) {
+            return;
+        }
+        final OrderByElement last = _orderByList.get(_orderByList.size() - 1);
+        last.setOrderByNullsSetupper(filter, true);
+    }
+
+    public void addNullsLastToPreviousOrderByElement(OrderByNullsSetupper filter) {
+        if (_orderByList.isEmpty()) {
+            return;
+        }
+        final OrderByElement last = _orderByList.get(_orderByList.size() - 1);
+        last.setOrderByNullsSetupper(filter, false);
+    }
+
+    public static interface OrderByNullsSetupper {
+        public String setup(String columnName, String orderByElementClause,
+                boolean nullsFirst);
+    }
+
+    public List<OrderByElement> getOrderByList() {
+        return _orderByList;
+    }
+
+    public String getOrderByClause() {
+        return getOrderByClause(null);
+    }
+
+    public String getOrderByClause(
+            Map<String, String> selectClauseRealColumnAliasMap) {
+        if (_orderByList.isEmpty()) {
+            return "";
+        }
+        final StringBuffer sb = new StringBuffer();
+        final String delimiter = ", ";
+        for (final Iterator<OrderByElement> ite = _orderByList.iterator(); ite
+                .hasNext();) {
+            final OrderByElement element = ite.next();
+            sb.append(delimiter);
+            if (selectClauseRealColumnAliasMap != null) {
+                sb.append(element
+                        .getElementClause(selectClauseRealColumnAliasMap));
+            } else {
+                sb.append(element.getElementClause());
+            }
+        }
+        sb.delete(0, delimiter.length()).insert(0, "order by ");
+        return sb.toString();
+    }
+
+    public boolean isSameOrderByColumn(String orderByProperty) {
+        final List<String> orderByList = new ArrayList<String>();
+        {
+            final StringTokenizer st = new StringTokenizer(orderByProperty, "/");
+            while (st.hasMoreElements()) {
+                orderByList.add(st.nextToken());
+            }
+        }
+        if (_orderByList.size() != orderByList.size()) {
+            return false;
+        }
+        int count = 0;
+        for (final Iterator<String> ite = orderByList.iterator(); ite.hasNext();) {
+            final String columnFullName = ite.next();
+            final OrderByElement element = (OrderByElement) _orderByList
+                    .get(count);
+            if (!element.getColumnFullName().equals(columnFullName)) {
+                return false;
+            }
+            count++;
+        }
+        return true;
+    }
+
+    // =====================================================================================
+    //                                                                         First Element
+    //                                                                         =============
+    public boolean isFirstElementAsc() {
+        if (isEmpty()) {
+            String msg = "This order-by clause is empty: " + toString();
+            throw new IllegalStateException(msg);
+        }
+        final OrderByElement element = (OrderByElement) _orderByList.get(0);
+        return element.isAsc();
+    }
+
+    public boolean isFirstElementDesc() {
+        return !isFirstElementAsc();
+    }
+
+    public boolean isSameAsFirstElementAliasName(String expectedAliasName) {
+        if (isEmpty()) {
+            String msg = "This order-by clause is empty: " + toString();
+            throw new RuntimeException(msg);
+        }
+        OrderByElement element = (OrderByElement) _orderByList.get(0);
+        String actualAliasName = element.getAliasName();
+        if (actualAliasName != null && expectedAliasName != null) {
+            return actualAliasName.equalsIgnoreCase(expectedAliasName);
+        } else {
+            return false;
+        }
+    }
+
+    /**
+     * @param expectedColumnName Expected column-name. (Nullable)
+     * @return Determination.
+     */
+    public boolean isSameAsFirstElementColumnName(String expectedColumnName) {
+        if (isEmpty()) {
+            String msg = "This order-by clause is empty: " + toString();
+            throw new RuntimeException(msg);
+        }
+        OrderByElement element = (OrderByElement) _orderByList.get(0);
+        String actualColumnName = element.getColumnName();
+        if (actualColumnName != null && expectedColumnName != null) {
+            return actualColumnName.equalsIgnoreCase(expectedColumnName);
+        } else {
+            return false;
+        }
+    }
+
+    /**
+     * @param expectedAliasName Expected alias-name. (Nullable)
+     * @return Determination.
+     */
+    public boolean isSameAsFirstElementRegisteredAliasName(
+            String expectedAliasName) {
+        if (isEmpty()) {
+            String msg = "This order-by clause is empty: " + toString();
+            throw new RuntimeException(msg);
+        }
+        OrderByElement element = (OrderByElement) _orderByList.get(0);
+        String actualAliasName = element.getRegisteredAliasName();
+        if (actualAliasName != null && expectedAliasName != null) {
+            return actualAliasName.equalsIgnoreCase(expectedAliasName);
+        } else {
+            return false;
+        }
+    }
+
+    /**
+     * @param expectedColumnName Expected column-name. (Nullable)
+     * @return Determination.
+     */
+    public boolean isSameAsFirstElementRegisteredColumnName(
+            String expectedColumnName) {
+        if (isEmpty()) {
+            String msg = "This order-by clause is empty: " + toString();
+            throw new RuntimeException(msg);
+        }
+        OrderByElement element = (OrderByElement) _orderByList.get(0);
+        String actualColumnName = element.getRegisteredColumnName();
+        if (actualColumnName != null && expectedColumnName != null) {
+            return actualColumnName.equalsIgnoreCase(expectedColumnName);
+        } else {
+            return false;
+        }
+    }
+
+    // =====================================================================================
+    //                                                                      Delegate of List
+    //                                                                      ================
+    /**
+     * Is empty?
+     * @return Determination.
+     */
+    public boolean isEmpty() {
+        return _orderByList.isEmpty();
+    }
+
+    /**
+     * Get iterator of order-by list.
+     * @return Determination.
+     */
+    public java.util.Iterator iterator() {
+        return _orderByList.iterator();
+    }
+
+    /**
+     * Clear order-by list.
+     */
+    public void clear() {
+        _orderByList.clear();
+    }
+
+    // =====================================================================================
+    //                                                                 Basic-Override Method
+    //                                                                 =====================
+    /**
+     * This method overrides the method that is declared at super.
+     * @return View-string of all-columns value.
+     */
+    public String toString() {
+        return _orderByList.toString();
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/OrderByClause.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/OrderByElement.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/OrderByElement.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/OrderByElement.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,263 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+import java.util.Map;
+
+import jp.sf.pal.announcement.db.allcommon.util.SimpleSystemUtil;
+
+/**
+ * @author DBFlute(AutoGenerator)
+ */
+public class OrderByElement implements java.io.Serializable {
+
+    /** Serial version UID. (Default) */
+    private static final long serialVersionUID = 1L;
+
+    // =====================================================================================
+    //                                                                             Attribute
+    //                                                                             =========
+    /** The value of alias name. */
+    protected String _aliasName;
+
+    /** The value of column name. */
+    protected String _columnName;
+
+    /** The value of registered alias name. */
+    protected String _registeredAliasName;
+
+    /** The value of registered column name. */
+    protected String _registeredColumnName;
+
+    /** The value of ascDesc. */
+    protected String _ascDesc = "asc";
+
+    /** The setupper of order-by nulls. */
+    protected OrderByClause.OrderByNullsSetupper _orderByNullsSetupper;
+
+    /** Is nulls ordered first? */
+    protected boolean _nullsFirst;
+
+    // =====================================================================================
+    //                                                                              Accessor
+    //                                                                              ========
+    public String getAliasName() {
+        return _aliasName;
+    }
+
+    public String getColumnName() {
+        return _columnName;
+    }
+
+    public String getRegisteredAliasName() {
+        return _registeredAliasName;
+    }
+
+    public String getRegisteredColumnName() {
+        return _registeredColumnName;
+    }
+
+    public String getAscDesc() {
+        return _ascDesc;
+    }
+
+    public void setAliasName(String value) {
+        _aliasName = value;
+    }
+
+    public void setColumnName(String value) {
+        _columnName = value;
+    }
+
+    public void setRegisteredAliasName(String value) {
+        _registeredAliasName = value;
+    }
+
+    public void setRegisteredColumnName(String value) {
+        _registeredColumnName = value;
+    }
+
+    public void setAscDesc(String value) {
+        _ascDesc = value;
+    }
+
+    public void setOrderByNullsSetupper(
+            OrderByClause.OrderByNullsSetupper value, boolean nullsFirst) {
+        _orderByNullsSetupper = value;
+        _nullsFirst = nullsFirst;
+    }
+
+    // =====================================================================================
+    //                                                                              Behavior
+    //                                                                              ========
+    public void setupAsc() {
+        _ascDesc = "asc";
+    }
+
+    public void setupDesc() {
+        _ascDesc = "desc";
+    }
+
+    public void reverse() {
+        if (_ascDesc == null) {
+            String msg = "The attribute[ascDesc] should not be null.";
+            throw new IllegalStateException(msg);
+        }
+        if (_ascDesc.equals("asc")) {
+            _ascDesc = "desc";
+        } else if (_ascDesc.equals("desc")) {
+            _ascDesc = "asc";
+        } else {
+            String msg = "The attribute[ascDesc] should be asc or desc: but ascDesc="
+                    + _ascDesc;
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    public boolean isAsc() {
+        if (_ascDesc == null) {
+            String msg = "The attribute[ascDesc] should not be null.";
+            throw new IllegalStateException(msg);
+        }
+        if (_ascDesc.equals("asc")) {
+            return true;
+        } else if (_ascDesc.equals("desc")) {
+            return false;
+        } else {
+            String msg = "The attribute[ascDesc] should be asc or desc: but ascDesc="
+                    + _ascDesc;
+            throw new IllegalStateException(msg);
+        }
+    }
+
+    public String getColumnFullName() {
+        final StringBuilder sb = new StringBuilder();
+        if (_aliasName != null) {
+            sb.append(_aliasName).append(".");
+        }
+        if (_columnName == null) {
+            String msg = "The attribute[columnName] should not be null.";
+            throw new IllegalStateException(msg);
+        }
+        sb.append(_columnName);
+        return sb.toString();
+    }
+
+    public String getElementClause() {
+        if (_ascDesc == null) {
+            String msg = "The attribute[ascDesc] should not be null.";
+            throw new IllegalStateException(msg);
+        }
+        final StringBuilder sb = new StringBuilder();
+        sb.append(getColumnFullName()).append(" ").append(_ascDesc);
+        if (_orderByNullsSetupper != null) {
+            return _orderByNullsSetupper.setup(getColumnFullName(), sb
+                    .toString(), _nullsFirst);
+        } else {
+            return sb.toString();
+        }
+    }
+
+    public String getElementClause(
+            Map<String, String> selectClauseRealColumnAliasMap) {
+        if (selectClauseRealColumnAliasMap == null) {
+            String msg = "The argument[selectClauseRealColumnAliasMap] should not be null.";
+            throw new IllegalArgumentException(msg);
+        }
+        if (_ascDesc == null) {
+            String msg = "The attribute[ascDesc] should not be null.";
+            throw new IllegalStateException(msg);
+        }
+        final StringBuilder sb = new StringBuilder();
+        final String columnAlias = selectClauseRealColumnAliasMap
+                .get(getColumnFullName());
+        if (columnAlias == null || columnAlias.trim().length() == 0) {
+            throwOrderByColumnNotFoundException(getColumnFullName(),
+                    selectClauseRealColumnAliasMap);
+        }
+        sb.append(columnAlias).append(" ").append(_ascDesc);
+        if (_orderByNullsSetupper != null) {
+            return _orderByNullsSetupper.setup(columnAlias, sb.toString(),
+                    _nullsFirst);
+        } else {
+            return sb.toString();
+        }
+    }
+
+    protected void throwOrderByColumnNotFoundException(String columnName,
+            Map<String, String> selectClauseRealColumnAliasMap) {
+        String msg = "Look! Read the message below." + getLineSeparator();
+        msg = msg
+                + "/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *"
+                + getLineSeparator();
+        msg = msg + "The column for order-by was Not Found in select-clause!"
+                + getLineSeparator();
+        msg = msg + getLineSeparator();
+        msg = msg + "[Advice]" + getLineSeparator();
+        msg = msg
+                + "If you use 'union()' or 'unionAll()', Check your condition-bean!"
+                + getLineSeparator();
+        msg = msg + "Order-by for union can use only columns on select-clause."
+                + getLineSeparator();
+        msg = msg
+                + "So the rule when using union is little difference from the one when NOT using."
+                + getLineSeparator();
+        msg = msg + "  For example:" + getLineSeparator();
+        msg = msg + "    [before (x)]" + getLineSeparator();
+        msg = msg + "    AaaCB cb = new AaaCB();" + getLineSeparator();
+        msg = msg + "    cb.query().setXxx...();" + getLineSeparator();
+        msg = msg + "    {" + getLineSeparator();
+        msg = msg + "        AaaCB unionCB = new AaaCB();" + getLineSeparator();
+        msg = msg + "        unionCB.query().setXxx...();" + getLineSeparator();
+        msg = msg + "        cb.union(unionCB.query());" + getLineSeparator();
+        msg = msg + "    }" + getLineSeparator();
+        msg = msg
+                + "    cb.query().queryBbb().addOrderBy_BbbName_Asc();// *NG!"
+                + getLineSeparator();
+        msg = msg + "    " + getLineSeparator();
+        msg = msg + "    [after (o)]" + getLineSeparator();
+        msg = msg + "    AaaCB cb = new AaaCB();" + getLineSeparator();
+        msg = msg + "    cb.setupSelect_Bbb();// *Point!" + getLineSeparator();
+        msg = msg + "    cb.query().setXxx...();" + getLineSeparator();
+        msg = msg + "    {" + getLineSeparator();
+        msg = msg + "        AaaCB unionCB = new AaaCB();" + getLineSeparator();
+        msg = msg + "        unionCB.query().setXxx...();" + getLineSeparator();
+        msg = msg + "        cb.union(unionCB.query());" + getLineSeparator();
+        msg = msg + "    }" + getLineSeparator();
+        msg = msg
+                + "    cb.query().queryBbb().addOrderBy_BbbName_Asc();// *OK!"
+                + getLineSeparator();
+        msg = msg + "    " + getLineSeparator();
+        msg = msg
+                + "Or else if you DON'T use 'union()' or 'unionAll()', This is the Framework Exception!"
+                + getLineSeparator();
+        msg = msg + getLineSeparator();
+        msg = msg + "[Target Column]" + getLineSeparator();
+        msg = msg + columnName + getLineSeparator();
+        msg = msg + getLineSeparator();
+        msg = msg + "[Internal Object]" + getLineSeparator();
+        msg = msg + "selectClauseRealColumnAliasMap="
+                + selectClauseRealColumnAliasMap + getLineSeparator();
+        msg = msg + "* * * * * * * * * */" + getLineSeparator();
+        throw new IllegalStateException(msg);
+    }
+
+    protected String getLineSeparator() {
+        return SimpleSystemUtil.getLineSeparator();
+    }
+
+    // =====================================================================================
+    //                                                                        Basic Override
+    //                                                                        ==============
+    /**
+     * This method overrides the method that is declared at super.
+     * @return View-string of all-columns value.
+     */
+    public String toString() {
+        final StringBuilder sb = new StringBuilder();
+        sb.append("[OrderByElement] aliasName=").append(_aliasName);
+        sb.append(" columnName=").append(_columnName);
+        sb.append(" registeredAliasName=").append(_registeredAliasName);
+        sb.append(" registeredColumnName=").append(_registeredColumnName);
+        sb.append(" ascDesc=").append(_ascDesc);
+        return sb.toString();
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/OrderByElement.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClause.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClause.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClause.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,475 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+import java.util.Map;
+
+import jp.sf.pal.announcement.db.allcommon.cbean.ckey.ConditionKey;
+import jp.sf.pal.announcement.db.allcommon.cbean.coption.ConditionOption;
+import jp.sf.pal.announcement.db.allcommon.cbean.cvalue.ConditionValue;
+
+/**
+ * The interface of SQL-clause.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public interface SqlClause {
+
+    // =====================================================================================
+    //                                                                                Clause
+    //                                                                                ======
+    /**
+     * Get the clause of all parts.
+     * <pre>
+     * # select [base-table-columns], [join-table-columns]
+     * #   from [base-table] left outer join [join-table] [join-alias] on [join-condition]
+     * #  where [base-table].[column] = [value] and [join-alias].[column] is null
+     * #  order by [base-table].[column] asc, [join-alias].[column] desc
+     * #  for update
+     * </pre>
+     * @return The clause of all parts. (NotNull)
+     */
+    public String getClause();
+
+    /**
+     * Get clause of all parts as PK-only.
+     * <pre>
+     * # select [base-table-columns], [join-table-columns]
+     * #   from [base-table] left outer join [join-table] [join-alias] on [join-condition]
+     * #  where [base-table].[column] = [value] and [join-alias].[column] is null
+     * #  order by [base-table].[column] asc, [join-alias].[column] desc
+     * #  for update
+     * </pre>
+     * @return The clause of all parts as PK-Only. (NotNull)
+     */
+    public String getClausePKOnly();
+
+    /**
+     * Get from-where clause without select and orderBy and sqlSuffix. 
+     * For subQuery and selectCount.
+     * <p>
+     * You should handle UnionSelectClauseMark and UnionWhereClauseMark and UnionWhereFirstConditionMark in clause.
+     * </p>
+     * @return The 'from-where' clause(contains union) without 'select' and 'orderBy' and 'sqlSuffix'. (NotNull)
+     */
+    public String getClauseFromWhereWithUnionTemplate();
+
+    /**
+     * Get from-where clause without select and orderBy and sqlSuffix as template. 
+     * For subQuery and selectCount.
+     * <p>
+     * You should handle UnionSelectClauseMark and UnionWhereClauseMark and UnionWhereFirstConditionMark
+     * and WhereClauseMark and WhereFirstConditionMark in clause.
+     * </p>
+     * @return The 'from-where' clause(contains union) without 'select' and 'orderBy' and 'sqlSuffix'. (NotNull)
+     */
+    public String getClauseFromWhereWithWhereUnionTemplate();
+
+    // =====================================================================================
+    //                                                                          Clause Parts
+    //                                                                          ============
+    /**
+     * Get the clause of 'select'. This is an internal method.
+     * @return The clause of select. {[select ...] from table...} (NotNull)
+     */
+    public String getSelectClause();
+
+    /**
+     * Get The clause of 'select' as PK-only. This is an internal method.
+     * @return The clause of select PK-only. {[select ...] from table...} (NotNull)
+     */
+    public String getSelectClausePKOnly();
+
+    /**
+     * Get the hint of 'select'. This is an internal method.
+     * @return The hint of 'select'. {select [select-hint] * from table...} (NotNull)
+     */
+    public String getSelectHint();
+
+    /**
+     * Get the clause of included-select-column. This is an internal method.
+     * @return The clause of included-select-column. {select ... , [included-select-column clause] from table...} (NotNull)
+     */
+    public String getIncludedSelectColumnClause();
+
+    /**
+     * Get the clause of 'from'. This is an internal method.
+     * @return The clause of 'from'. (NotNull)
+     */
+    public String getFromClause();
+
+    /**
+     * Get the clause of from-base-table. This is an internal method.
+     * @return The hint of from-base-table. {select * from table [from-base-table-hint] where ...} (NotNull)
+     */
+    public String getFromBaseTableHint();
+
+    /**
+     * Get the hint of 'from'. This is an internal method.
+     * @return The hint of 'from'. {select * from table left outer join ... on ... [from-hint] where ...} (NotNull)
+     */
+    public String getFromHint();
+
+    /**
+     * Get the clause of 'where'. This is an internal method.
+     * @return The clause of 'where'. (NotNull)
+     */
+    public String getWhereClause();
+
+    /**
+     * Get the clause of 'order-by'. This is an internal method.
+     * @return The clause of 'order-by'. (NotNull)
+     */
+    public String getOrderByClause();
+
+    /**
+     * Get the suffix of SQL. This is an internal method.
+     * @return The suffix of SQL. {select * from table where ... order by ... [sql-suffix]} (NotNull)
+     */
+    public String getSqlSuffix();
+
+    // ===================================================================================
+    //                                                                          Copy Parts
+    //                                                                          ==========
+    /**
+     * Copy included-select-column.
+     * @param sqlClause SQL-clause. (NotNull)
+     */
+    public void copyIncludedSelectColumn(SqlClause sqlClause);
+
+    // ===================================================================================
+    //                                                                SelectedSelectColumn
+    //                                                                ====================
+    /**
+     * Register selected-select-column.
+     * @param foreignTableAliasName The alias name of foreign table. (NotNull)
+     * @param localTableName The table name of local. (NotNull)
+     * @param foreignPropertyName The property name of foreign table. (NotNull)
+     * @param localRelationPath The path of local relation. (Nullable)
+     */
+    public void registerSelectedSelectColumn(String foreignTableAliasName,
+            String localTableName, String foreignPropertyName,
+            String localRelationPath);
+
+    // ===================================================================================
+    //                                                                IncludedSelectColumn
+    //                                                                ====================
+    /**
+     * Ignore included-select-column.
+     */
+    public void ignoreIncludedSelectColumn();
+
+    /**
+     * Make included-select-column effective.
+     */
+    public void makeIncludedSelectColumnEffective();
+
+    /**
+     * Register included-select-column.
+     * @param aliasName The alias name of the included-select-column. (NotNull)
+     * @param realColumnName The real column name of the included-select-column. (NotNull)
+     */
+    public void registerIncludedSelectColumn(String aliasName,
+            String realColumnName);
+
+    // ===================================================================================
+    //                                                                           OuterJoin
+    //                                                                           =========
+    /**
+     * Register outer-join.
+     * @param joinTableName The name of join table. {left outer join [joinTableName]} (NotNull)
+     * @param aliasName The alias name of join table. {left outer join joinTableName [aliasName]} (NotNull and Unique per invoking method)
+     * @param joinOnMap Map that has conditions of on-clause. (NotNull)
+     */
+    public void registerOuterJoin(String joinTableName, String aliasName,
+            Map<String, String> joinOnMap);
+
+    // ===================================================================================
+    //                                                                               Where
+    //                                                                               =====
+    /**
+     * Register 'where' clause.
+     * @param columnFullName The full name of column. {[table-name].[column-name]}. (NotNull)
+     * @param key Condition-key. (NotNull)
+     * @param value Condition-value. (NotNull)
+     */
+    public void registerWhereClause(String columnFullName, ConditionKey key,
+            ConditionValue value);
+
+    /**
+     * Register 'where' clause.
+     * @param columnFullName The full name of column. {[table-name].[column-name]}. (NotNull)
+     * @param key Condition-key. (NotNull)
+     * @param value Condition-value. (NotNull)
+     * @param option Condition-option. (NotNull)
+     */
+    public void registerWhereClause(String columnFullName, ConditionKey key,
+            ConditionValue value, ConditionOption option);
+
+    /**
+     * Register 'where' clause.
+     * @param clause The clause of 'where'. (NotNull)
+     */
+    public void registerWhereClause(String clause);
+
+    /**
+     * Exchange first The clause of 'where' for last one.
+     */
+    public void exchangeFirstWhereClauseForLastOne();
+
+    // ===================================================================================
+    //                                                                         InlineWhere
+    //                                                                         ===========
+    public void registerBaseTableInlineWhereClause(String columnName,
+            ConditionKey key, ConditionValue value);
+
+    public void registerBaseTableInlineWhereClause(String columnName,
+            ConditionKey key, ConditionValue value, ConditionOption option);
+
+    public void registerBaseTableInlineWhereClause(String value);
+
+    public void registerOuterJoinInlineWhereClause(String aliasName,
+            String columnName, ConditionKey key, ConditionValue value,
+            boolean onClauseInline);
+
+    public void registerOuterJoinInlineWhereClause(String aliasName,
+            String columnName, ConditionKey key, ConditionValue value,
+            ConditionOption option, boolean onClauseInline);
+
+    public void registerOuterJoinInlineWhereClause(String aliasName,
+            String value, boolean onClauseInline);
+
+    // ===================================================================================
+    //                                                             AdditionalConditionAsOr
+    //                                                             =======================
+    public void makeAdditionalConditionAsOrEffective();
+
+    public void ignoreAdditionalConditionAsOr();
+
+    // ===================================================================================
+    //                                                                             OrderBy
+    //                                                                             =======
+    public OrderByClause getSqlComponentOfOrderByClause();
+
+    public SqlClause clearOrderBy();
+
+    public SqlClause ignoreOrderBy();
+
+    public SqlClause makeOrderByEffective();
+
+    /**
+     * @param orderByProperty Order-by-property. 'aliasName.columnName/aliasName.columnName/...' (NotNull)
+     * @param registeredOrderByProperty Registered-order-by-property. ([table-name].[column-name]) (Nullable)
+     * @param ascOrDesc Is it ascend or descend?
+     */
+    public void registerOrderBy(String orderByProperty,
+            String registeredOrderByProperty, boolean ascOrDesc);
+
+    /**
+     * @param orderByProperty Order-by-property. 'aliasName.columnName/aliasName.columnName/...' (NotNull)
+     * @param registeredOrderByProperty Registered-order-by-property. ([table-name].[column-name]) (Nullable)
+     * @param ascOrDesc Is it ascend or descend?
+     */
+    public void reverseOrderBy_Or_OverrideOrderBy(String orderByProperty,
+            String registeredOrderByProperty, boolean ascOrDesc);
+
+    public void addNullsFirstToPreviousOrderBy();
+
+    public void addNullsLastToPreviousOrderBy();
+
+    // ===================================================================================
+    //                                                                               Union
+    //                                                                               =====
+    public void registerUnionQuery(String unionClause, boolean unionAll);
+
+    // ===================================================================================
+    //                                                                          FetchScope
+    //                                                                          ==========
+    /**
+     * Fetch first.
+     * @param fetchSize Fetch-size. (NotMinus)
+     * @return this. (NotNull)
+     */
+    public SqlClause fetchFirst(int fetchSize);
+
+    /**
+     * Fetch scope.
+     * @param fetchStartIndex Fetch-start-index. 0 origin. (NotMinus)
+     * @param fetchSize Fetch-size. (NotMinus)
+     * @return this. (NotNull)
+     */
+    public SqlClause fetchScope(int fetchStartIndex, int fetchSize);
+
+    /**
+     * Fetch page.
+     * <p>
+     * When you invoke this, it is normally necessary to invoke 'fetchFirst()' or 'fetchScope()' ahead of that.
+     * But you also can use default-fetch-size without invoking 'fetchFirst()' or 'fetchScope()'.
+     * If you invoke this, your SQL returns [fetch-size] records from [fetch-start-index] calculated by [fetch-page-number].
+     * </p>
+     * @param fetchPageNumber Fetch-page-number. 1 origin. (NotMinus & NotZero: If minus or zero, set one.)
+     * @return this. (NotNull)
+     */
+    public SqlClause fetchPage(int fetchPageNumber);
+
+    /**
+     * Get fetch start index.
+     * @return Fetch start index.
+     */
+    public int getFetchStartIndex();
+
+    /**
+     * Get fetch size.
+     * @return Fetch size.
+     */
+    public int getFetchSize();
+
+    /**
+     * Get fetch page number.
+     * @return Fetch page number.
+     */
+    public int getFetchPageNumber();
+
+    /**
+     * Get page start index.
+     * @return Page start index. 0 origin. (NotMinus)
+     */
+    public int getPageStartIndex();
+
+    /**
+     * Get page end index.
+     * @return Page end index. 0 origin. (NotMinus)
+     */
+    public int getPageEndIndex();
+
+    /**
+     * Is fetch scope effective?
+     * @return Determiantion.
+     */
+    public boolean isFetchScopeEffective();
+
+    /**
+     * Ignore fetch-scope.
+     * @return this. (NotNull)
+     */
+    public SqlClause ignoreFetchScope();
+
+    /**
+     * Make fetch-scope effective.
+     * @return this. (NotNull)
+     */
+    public SqlClause makeFetchScopeEffective();
+
+    /**
+     * Is fetch start index supported?
+     * @return Determination.
+     */
+    public boolean isFetchStartIndexSupported();
+
+    /**
+     * Is fetch size supported?
+     * @return Determination.
+     */
+    public boolean isFetchSizeSupported();
+
+    // ===================================================================================
+    //                                                                     Fetch Narrowing
+    //                                                                     ===============
+    /**
+     * Is fetch-narrowing effective?
+     * @return Determiantion.
+     */
+    public boolean isFetchNarrowingEffective();
+
+    /**
+     * Get fetch-narrowing skip-start-index.
+     * @return Skip-start-index.
+     */
+    public int getFetchNarrowingSkipStartIndex();
+
+    /**
+     * Get fetch-narrowing loop-count.
+     * @return Loop-count.
+     */
+    public int getFetchNarrowingLoopCount();
+
+    // ===================================================================================
+    //                                                                                Lock
+    //                                                                                ====
+    /**
+     * Lock for update.
+     * <p>
+     * If you invoke this, your SQL lock target records for update.
+     * It depends whether this method supports this on the database type.
+     * </p>
+     * @return this. (NotNull)
+     */
+    public SqlClause lockForUpdate();
+
+    // ===================================================================================
+    //                                                                            Resolver
+    //                                                                            ========
+    /**
+     * Resolve join alias name.
+     * @param relationPath Relation path. (NotNull)
+     * @param cqNestNo The nest no of condition query.
+     * @return Resolved join alias name. (NotNull)
+     */
+    public String resolveJoinAliasName(String relationPath, int cqNestNo);
+
+    /**
+     * Resolve nest level expression.
+     * @param name Name. (NotNull)
+     * @param cqNestNo The nest no of condition query.
+     * @return Resolved name about nest level. (NotNull)
+     */
+    public String resolveNestLevelExpression(String name, int cqNestNo);
+
+    /**
+     * Resolve relation no.
+     * @param baseTableName The table name of base. (NotNull)
+     * @param foreignPropertyName The property name of foreign. (NotNull)
+     * @return Resolved relation no.
+     */
+    public int resolveRelationNo(String baseTableName,
+            String foreignPropertyName);
+
+    // ===================================================================================
+    //                                                                    Table Alias Info
+    //                                                                    ================
+    public String getLocalTableAliasName();
+
+    public String getForeignTableAliasPrefix();
+
+    // ===================================================================================
+    //                                                                       Template Mark
+    //                                                                       =============
+    public String getWhereClauseMark();
+
+    public String getWhereFirstConditionMark();
+
+    public String getUnionSelectClauseMark();
+
+    public String getUnionWhereClauseMark();
+
+    public String getUnionWhereFirstConditionMark();
+
+    // =====================================================================================
+    //                                                            Where Clause Simple Filter
+    //                                                            ==========================
+    public void addWhereClauseSimpleFilter(
+            WhereClauseSimpleFilter whereClauseSimpleFilter);
+
+    // =====================================================================================
+    //                                                                 Selected Foreign Info
+    //                                                                 =====================
+    public boolean hasSelectedForeignInfo(String relationPath);
+
+    public void registerSelectedForeignInfo(String relationPath,
+            String foreignPropertyName);
+
+    // ===================================================================================
+    //                                                                       Format Clause
+    //                                                                       =============
+    public boolean isFormatClauseEffective();
+
+    public void makeFormatClauseEffective();
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClause.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDb2.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDb2.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDb2.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,126 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+/**
+ * SqlClause for DB2.
+ * @author DBFlute(AutoGenerator)
+ */
+public class SqlClauseDb2 extends AbstractSqlClause {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** String of fetch-first as sql-suffix. */
+    protected String _fetchFirstSqlSuffix = "";
+
+    /** String of lock as from-hint. */
+    protected String _lockSqlSuffix = "";
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * Constructor.
+     * @param tableName Table name. (NotNull)
+     **/
+    public SqlClauseDb2(String tableName) {
+        super(tableName);
+    }
+
+    // ===================================================================================
+    //                                                                    OrderBy Override
+    //                                                                    ================
+    @Override
+    protected OrderByClause.OrderByNullsSetupper createOrderByNullsSetupper() {
+        return createOrderByNullsSetupperByCaseWhen();
+    }
+
+    // ===================================================================================
+    //                                                                 FetchScope Override
+    //                                                                 ===================
+    /**
+     * The implementation.
+     */
+    protected void doFetchFirst() {
+        if (isFetchSizeSupported()) {
+            _fetchFirstSqlSuffix = " fetch first " + getFetchSize()
+                    + " rows only";
+        }
+    }
+
+    /**
+     * The implementation. {Unsupported!}
+     */
+    protected void doFetchPage() {
+        if (isFetchSizeSupported()) {
+            if (isFetchStartIndexSupported()) {
+                _fetchFirstSqlSuffix = " fetch first " + getFetchSize()
+                        + " rows only";
+            } else {
+                _fetchFirstSqlSuffix = " fetch first " + getPageEndIndex()
+                        + " rows only";
+            }
+        }
+    }
+
+    /**
+     * The implementation. {Unsupported!}
+     */
+    protected void doClearFetchPageClause() {
+        _fetchFirstSqlSuffix = "";
+    }
+
+    /**
+     * The override.
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchStartIndexSupported() {
+        return false;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public SqlClause lockForUpdate() {
+        _lockSqlSuffix = " for update with RS";
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Select-hint. (NotNull)
+     */
+    protected String createSelectHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-base-table-hint. {select * from table [from-base-table-hint] where ...} (NotNull)
+     */
+    protected String createFromBaseTableHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-hint. (NotNull)
+     */
+    protected String createFromHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Sql-suffix. (NotNull)
+     */
+    protected String createSqlSuffix() {
+        return _fetchFirstSqlSuffix + _lockSqlSuffix;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDb2.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDefault.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDefault.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDefault.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,109 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+/**
+ * SqlClause for Default.
+ * @author DBFlute(AutoGenerator)
+ */
+public class SqlClauseDefault extends AbstractSqlClause {
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * @param tableName Table name. (NotNull)
+     **/
+    public SqlClauseDefault(String tableName) {
+        super(tableName);
+    }
+
+    // ===================================================================================
+    //                                                                    OrderBy Override
+    //                                                                    ================
+    @Override
+    protected OrderByClause.OrderByNullsSetupper createOrderByNullsSetupper() {
+        return createOrderByNullsSetupperByCaseWhen();
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchFirst() {
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchPage() {
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doClearFetchPageClause() {
+    }
+
+    /**
+     * The override.
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchStartIndexSupported() {
+        return false; // Default
+    }
+
+    /**
+     * The override.
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchSizeSupported() {
+        return false; // Default
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public SqlClause lockForUpdate() {
+        String msg = "LockForUpdate-SQL is unsupported in the database. Sorry...: "
+                + toString();
+        throw new UnsupportedOperationException(msg);
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Select-hint. (NotNull)
+     */
+    protected String createSelectHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-base-table-hint. {select * from table [from-base-table-hint] where ...} (NotNull)
+     */
+    protected String createFromBaseTableHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-hint. (NotNull)
+     */
+    protected String createFromHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Sql-suffix. (NotNull)
+     */
+    protected String createSqlSuffix() {
+        return "";
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDefault.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDerby.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDerby.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDerby.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,119 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+/**
+ * SqlClause for Default.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class SqlClauseDerby extends AbstractSqlClause {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** String of lock as sql-suffix. */
+    protected String _lockSqlSuffix = "";
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * Constructor.
+     * @param tableName Table name. (NotNull)
+     **/
+    public SqlClauseDerby(String tableName) {
+        super(tableName);
+    }
+
+    // ===================================================================================
+    //                                                                    OrderBy Override
+    //                                                                    ================
+    @Override
+    protected OrderByClause.OrderByNullsSetupper createOrderByNullsSetupper() {
+        return createOrderByNullsSetupperByCaseWhen();
+    }
+
+    // ===================================================================================
+    //                                                                 FetchScope Override
+    //                                                                 ===================
+    /**
+     * The implementation.
+     */
+    protected void doFetchFirst() {
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchPage() {
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doClearFetchPageClause() {
+    }
+
+    /**
+     * The override.
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchStartIndexSupported() {
+        return false; // Default
+    }
+
+    /**
+     * The override.
+     * 
+     * @return Determination.
+     */
+    public boolean isFetchSizeSupported() {
+        return false; // Default
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public SqlClause lockForUpdate() {
+        _lockSqlSuffix = " for update";
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Select-hint. (NotNull)
+     */
+    protected String createSelectHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-base-table-hint. {select * from table [from-base-table-hint] where ...} (NotNull)
+     */
+    protected String createFromBaseTableHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-hint. (NotNull)
+     */
+    protected String createFromHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Sql-suffix. (NotNull)
+     */
+    protected String createSqlSuffix() {
+        return _lockSqlSuffix;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseDerby.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseFirebird.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseFirebird.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseFirebird.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,102 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+/**
+ * SqlClause for Firebird.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class SqlClauseFirebird extends AbstractSqlClause {
+
+    /** String of fetch-scope as select-hint. */
+    protected String _fetchScopeSelectHint = "";
+
+    /** String of lock as sql-suffix. */
+    protected String _lockSqlSuffix = "";
+
+    /**
+     * Constructor.
+     * 
+     * @param tableName Table name. (NotNull)
+     **/
+    public SqlClauseFirebird(String tableName) {
+        super(tableName);
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchFirst() {
+        if (isFetchSizeSupported()) {
+            _fetchScopeSelectHint = " first " + getFetchSize();
+        }
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchPage() {
+        if (isFetchStartIndexSupported() && isFetchSizeSupported()) {
+            _fetchScopeSelectHint = " first " + getFetchSize() + " skip "
+                    + getPageStartIndex();
+        }
+        if (isFetchStartIndexSupported() && !isFetchSizeSupported()) {
+            _fetchScopeSelectHint = " skip " + getPageStartIndex();
+        }
+        if (!isFetchStartIndexSupported() && isFetchSizeSupported()) {
+            _fetchScopeSelectHint = " first " + getPageEndIndex();
+        }
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doClearFetchPageClause() {
+        _fetchScopeSelectHint = "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public SqlClause lockForUpdate() {
+        _lockSqlSuffix = " for update with lock";
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Select-hint. (NotNull)
+     */
+    protected String createSelectHint() {
+        return _fetchScopeSelectHint;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-base-table-hint. {select * from table [from-base-table-hint] where ...} (NotNull)
+     */
+    protected String createFromBaseTableHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-hint. (NotNull)
+     */
+    protected String createFromHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Sql-suffix. (NotNull)
+     */
+    protected String createSqlSuffix() {
+        return _lockSqlSuffix;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseFirebird.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseH2.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseH2.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseH2.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,92 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+/**
+ * SqlClause for H2.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class SqlClauseH2 extends AbstractSqlClause {
+
+    /** String of fetch-scope as sql-suffix. */
+    protected String _fetchScopeSqlSuffix = "";
+
+    /** String of lock as sql-suffix. */
+    protected String _lockSqlSuffix = "";
+
+    /**
+     * Constructor.
+     * <p>
+     * @param tableName Table name. (NotNull)
+     **/
+    public SqlClauseH2(String tableName) {
+        super(tableName);
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchFirst() {
+        doFetchPage();
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchPage() {
+        _fetchScopeSqlSuffix = " limit " + getFetchSize() + " offset "
+                + getPageStartIndex();
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doClearFetchPageClause() {
+        _fetchScopeSqlSuffix = "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public SqlClause lockForUpdate() {
+        _lockSqlSuffix = " for update";
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Select-hint. (NotNull)
+     */
+    protected String createSelectHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-base-table-hint. {select * from table [from-base-table-hint] where ...} (NotNull)
+     */
+    protected String createFromBaseTableHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-hint. (NotNull)
+     */
+    protected String createFromHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Sql-suffix. (NotNull)
+     */
+    protected String createSqlSuffix() {
+        return _fetchScopeSqlSuffix + _lockSqlSuffix;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseH2.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseInterbase.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseInterbase.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseInterbase.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,107 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+/**
+ * SqlClause for Interbase.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class SqlClauseInterbase extends AbstractSqlClause {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** String of fetch-scope as select-hint. */
+    protected String _fetchScopeSelectHint = "";
+
+    /** String of lock as sql-suffix. */
+    protected String _lockSqlSuffix = "";
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * Constructor.
+     * @param tableName Table name. (NotNull)
+     **/
+    public SqlClauseInterbase(String tableName) {
+        super(tableName);
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchFirst() {
+        if (isFetchSizeSupported()) {
+            _fetchScopeSelectHint = " first " + getFetchSize();
+        }
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchPage() {
+        if (isFetchStartIndexSupported() && isFetchSizeSupported()) {
+            _fetchScopeSelectHint = " first " + getFetchSize() + " skip "
+                    + getPageStartIndex();
+        }
+        if (isFetchStartIndexSupported() && !isFetchSizeSupported()) {
+            _fetchScopeSelectHint = " skip " + getPageStartIndex();
+        }
+        if (!isFetchStartIndexSupported() && isFetchSizeSupported()) {
+            _fetchScopeSelectHint = " first " + getPageEndIndex();
+        }
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doClearFetchPageClause() {
+        _fetchScopeSelectHint = "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public SqlClause lockForUpdate() {
+        _lockSqlSuffix = " for update with lock";
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Select-hint. (NotNull)
+     */
+    protected String createSelectHint() {
+        return _fetchScopeSelectHint;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-base-table-hint. {select * from table [from-base-table-hint] where ...} (NotNull)
+     */
+    protected String createFromBaseTableHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-hint. (NotNull)
+     */
+    protected String createFromHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Sql-suffix. (NotNull)
+     */
+    protected String createSqlSuffix() {
+        return _lockSqlSuffix;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseInterbase.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseMySql.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseMySql.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseMySql.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,107 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+/**
+ * SqlClause for MySQL.
+ * @author DBFlute(AutoGenerator)
+ */
+public class SqlClauseMySql extends AbstractSqlClause {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** String of fetch-scope as sql-suffix. */
+    protected String _fetchScopeSqlSuffix = "";
+
+    /** String of lock as sql-suffix. */
+    protected String _lockSqlSuffix = "";
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * Constructor.
+     * @param tableName Table name. (NotNull)
+     **/
+    public SqlClauseMySql(String tableName) {
+        super(tableName);
+    }
+
+    // ===================================================================================
+    //                                                                    OrderBy Override
+    //                                                                    ================
+    @Override
+    protected OrderByClause.OrderByNullsSetupper createOrderByNullsSetupper() {
+        return createOrderByNullsSetupperByCaseWhen();
+    }
+
+    // ===================================================================================
+    //                                                                 FetchScope Override
+    //                                                                 ===================
+    /**
+     * The implementation.
+     */
+    protected void doFetchFirst() {
+        doFetchPage();
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchPage() {
+        _fetchScopeSqlSuffix = " limit " + getPageStartIndex() + ", "
+                + getFetchSize();
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doClearFetchPageClause() {
+        _fetchScopeSqlSuffix = "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public SqlClause lockForUpdate() {
+        _lockSqlSuffix = " for update";
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Select-hint. (NotNull)
+     */
+    protected String createSelectHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-base-table-hint. {select * from table [from-base-table-hint] where ...} (NotNull)
+     */
+    protected String createFromBaseTableHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-hint. (NotNull)
+     */
+    protected String createFromHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Sql-suffix. (NotNull)
+     */
+    protected String createSqlSuffix() {
+        return _fetchScopeSqlSuffix + _lockSqlSuffix;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseMySql.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseOracle.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseOracle.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseOracle.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,157 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMeta;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.DBMetaInstanceHandler;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.ColumnInfo;
+
+/**
+ * SqlClause for Oracle.
+ * @author DBFlute(AutoGenerator)
+ */
+public class SqlClauseOracle extends AbstractSqlClause {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** String of fetch-scope as select-hint. */
+    protected String _fetchScopeSelectHint = "";
+
+    /** String of fetch-scope as sql-suffix. */
+    protected String _fetchScopeSqlSuffix = "";
+
+    /** String of lock as sql-suffix. */
+    protected String _lockSqlSuffix = "";
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * Constructor.
+     * @param tableName Table name. (NotNull)
+     **/
+    public SqlClauseOracle(String tableName) {
+        super(tableName);
+    }
+
+    // ===================================================================================
+    //                                                          Database Original Override
+    //                                                          ==========================
+    @Override
+    protected String buildUnionClause(String selectClause) {
+
+        // - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+        // Remove select-hint comment from select clause of union
+        // for fetch-scope with union().
+        // - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+
+        selectClause = replaceString(selectClause, SELECT_HINT, "");
+        return super.buildUnionClause(selectClause);
+    }
+
+    // ===================================================================================
+    //                                                                 FetchScope Override
+    //                                                                 ===================
+    /**
+     * The implementation.
+     */
+    protected void doFetchFirst() {
+        doFetchPage();
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchPage() {
+        if (!isFetchStartIndexSupported() && !isFetchSizeSupported()) {
+            return;
+        }
+        final String ln;
+        if (isFormatClauseEffective()) {
+            ln = getLineSeparator();
+        } else {
+            ln = "";
+        }
+        _fetchScopeSelectHint = " * from (select base.*, rownum as rn from ("
+                + ln + "select";
+        _fetchScopeSqlSuffix = "";
+        if (isFetchStartIndexSupported()) {
+            _fetchScopeSqlSuffix = ") base )" + ln + " where rn > "
+                    + getPageStartIndex();
+        }
+        if (isFetchSizeSupported()) {
+            if (isFetchStartIndexSupported()) {
+                _fetchScopeSqlSuffix = _fetchScopeSqlSuffix + " and rn <= "
+                        + getPageEndIndex();
+            } else {
+                _fetchScopeSqlSuffix = ") base )" + ln + " where rn <= "
+                        + getPageEndIndex();
+            }
+        }
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doClearFetchPageClause() {
+        _fetchScopeSelectHint = "";
+        _fetchScopeSqlSuffix = "";
+    }
+
+    // ===================================================================================
+    //                                                                       Lock Override
+    //                                                                       =============
+    /**
+     * The implementation.
+     * @return this. (NotNull)
+     */
+    public SqlClause lockForUpdate() {
+        final DBMeta dbmeta = DBMetaInstanceHandler.findDBMeta(_tableName);
+        if (dbmeta.hasPrimaryKey()) {
+            final String primaryKeyColumnName = dbmeta.getPrimaryUniqueInfo()
+                    .getFirstColumn().getColumnDbName();
+            _lockSqlSuffix = " for update of " + getLocalTableAliasName() + "."
+                    + primaryKeyColumnName;
+        } else {
+            final String randomColumnName = ((ColumnInfo) dbmeta
+                    .getColumnInfoList().get(0)).getColumnDbName();
+            _lockSqlSuffix = " for update of " + getLocalTableAliasName() + "."
+                    + randomColumnName;
+        }
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                       Hint Override
+    //                                                                       =============
+    /**
+     * The implementation.
+     * @return Select-hint. (NotNull)
+     */
+    protected String createSelectHint() {
+        return _fetchScopeSelectHint;
+    }
+
+    /**
+     * The implementation.
+     * @return From-base-table-hint. {select * from table [from-base-table-hint] where ...} (NotNull)
+     */
+    protected String createFromBaseTableHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * @return From-hint. (NotNull)
+     */
+    protected String createFromHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * @return Sql-suffix. (NotNull)
+     */
+    protected String createSqlSuffix() {
+        return _fetchScopeSqlSuffix + _lockSqlSuffix;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseOracle.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClausePostgreSql.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClausePostgreSql.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClausePostgreSql.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,92 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+/**
+ * SqlClause for PostreSQL.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public class SqlClausePostgreSql extends AbstractSqlClause {
+
+    /** String of fetch-scope as sql-suffix. */
+    protected String _fetchScopeSqlSuffix = "";
+
+    /** String of lock as sql-suffix. */
+    protected String _lockSqlSuffix = "";
+
+    /**
+     * Constructor.
+     * 
+     * @param tableName Table name. (NotNull)
+     **/
+    public SqlClausePostgreSql(String tableName) {
+        super(tableName);
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchFirst() {
+        doFetchPage();
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchPage() {
+        _fetchScopeSqlSuffix = " offset " + getPageStartIndex() + " limit "
+                + getFetchSize();
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doClearFetchPageClause() {
+        _fetchScopeSqlSuffix = "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return this. (NotNull)
+     */
+    public SqlClause lockForUpdate() {
+        _lockSqlSuffix = " for update";
+        return this;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Select-hint. (NotNull)
+     */
+    protected String createSelectHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-base-table-hint. {select * from table [from-base-table-hint] where ...} (NotNull)
+     */
+    protected String createFromBaseTableHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-hint. (NotNull)
+     */
+    protected String createFromHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Sql-suffix. (NotNull)
+     */
+    protected String createSqlSuffix() {
+        return _fetchScopeSqlSuffix + _lockSqlSuffix;
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClausePostgreSql.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseSqlServer.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseSqlServer.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseSqlServer.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,125 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+/**
+ * SqlClause for MSSQL.
+ * @author DBFlute(AutoGenerator)
+ */
+public class SqlClauseSqlServer extends AbstractSqlClause {
+
+    // ===================================================================================
+    //                                                                           Attribute
+    //                                                                           =========
+    /** String of fetch-first as select-hint. */
+    protected String _fetchFirstSelectHint = "";
+
+    /** String of lock as from-hint. */
+    protected String _lockFromHint = "";
+
+    // ===================================================================================
+    //                                                                         Constructor
+    //                                                                         ===========
+    /**
+     * Constructor.
+     * @param tableName Table name. (NotNull)
+     **/
+    public SqlClauseSqlServer(String tableName) {
+        super(tableName);
+    }
+
+    // ===================================================================================
+    //                                                                    OrderBy Override
+    //                                                                    ================
+    @Override
+    protected OrderByClause.OrderByNullsSetupper createOrderByNullsSetupper() {
+        return createOrderByNullsSetupperByCaseWhen();
+    }
+
+    // ===================================================================================
+    //                                                                 FetchScope Override
+    //                                                                 ===================
+    /**
+     * The implementation.
+     */
+    protected void doFetchFirst() {
+        if (isFetchSizeSupported()) {
+            _fetchFirstSelectHint = " top " + getFetchSize();
+        }
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doFetchPage() {
+        if (isFetchSizeSupported()) {
+            if (isFetchStartIndexSupported()) {
+                _fetchFirstSelectHint = " top " + getFetchSize();
+            } else {
+                _fetchFirstSelectHint = " top " + getPageEndIndex();
+            }
+        }
+    }
+
+    /**
+     * The implementation.
+     */
+    protected void doClearFetchPageClause() {
+        _fetchFirstSelectHint = "";
+    }
+
+    /**
+     * @return Determination.
+     */
+    public boolean isFetchStartIndexSupported() {
+        return false;
+    }
+
+    // ===================================================================================
+    //                                                                       Lock Override
+    //                                                                       =============
+    /**
+     * The implementation. {Implement}
+     * @return this. (NotNull)
+     */
+    public SqlClause lockForUpdate() {
+        _lockFromHint = " with (updlock)";
+        return this;
+    }
+
+    // ===================================================================================
+    //                                                                       Hint Override
+    //                                                                       =============
+    /**
+     * The implementation.
+     * @return Select-hint. (NotNull)
+     */
+    protected String createSelectHint() {
+        return _fetchFirstSelectHint;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-base-table-hint. {select * from table [from-base-table-hint] where ...} (NotNull)
+     */
+    protected String createFromBaseTableHint() {
+        return _lockFromHint;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return From-hint. (NotNull)
+     */
+    protected String createFromHint() {
+        return "";
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Sql-suffix. (NotNull)
+     */
+    protected String createSqlSuffix() {
+        return "";
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/SqlClauseSqlServer.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/WhereClauseSimpleFilter.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/WhereClauseSimpleFilter.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/WhereClauseSimpleFilter.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,144 @@
+package jp.sf.pal.announcement.db.allcommon.cbean.sqlclause;
+
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.ColumnInfo;
+
+/**
+ * The interface of simple filter for where clause.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+public interface WhereClauseSimpleFilter {
+
+    public static final String BIND_COMMENT_BEGIN_PART = "/*dto";
+
+    public static final String BIND_COMMENT_END_PART = "*/null";
+
+    public static final String EMBEDDED_COMMENT_BEGIN_PART = "/*$dto";
+
+    public static final String EMBEDDED_COMMENT_END_PART = "*/null";
+
+    public static final String EMBEDDED_COMMENT_QUOTED_BEGIN_PART = "'/*$dto";
+
+    public static final String EMBEDDED_COMMENT_QUOTED_END_PART = "*/'dummy''";
+
+    /**
+     * Filter clause element.
+     * 
+     * @param clauseElement Clause element of where. (NotNull and NotEmpty)
+     * @return Filtered where clause. (NotNull and NotEmpty)
+     */
+    public String filterClauseElement(String clauseElement);
+
+    /**
+     * The simple filter for where clause to embedded. <br />
+     * *Attension -- Target column is not perfect. This class determines by column name only!
+     * So when the column name of base table is same as the column name of join table, both are target!
+     * 
+     * @author DBFlute(AutoGenerator)
+     */
+    public static class WhereClauseToEmbeddedSimpleFilter implements
+            WhereClauseSimpleFilter {
+
+        protected java.util.Set<ColumnInfo> _filterTargetColumnInfoSet;
+
+        public WhereClauseToEmbeddedSimpleFilter(
+                ColumnInfo filterTargetColumnInfo) {
+            this._filterTargetColumnInfoSet = new java.util.HashSet<ColumnInfo>();
+            this._filterTargetColumnInfoSet.add(filterTargetColumnInfo);
+        }
+
+        public WhereClauseToEmbeddedSimpleFilter(
+                java.util.Set<ColumnInfo> filterTargetColumnInfoSet) {
+            this._filterTargetColumnInfoSet = filterTargetColumnInfoSet;
+        }
+
+        /**
+         * Filter clause element.
+         * 
+         * @param clauseElement Clause element of where. (NotNull and NotEmpty)
+         * @return Filtered where clause. (NotNull and NotEmpty)
+         */
+        public String filterClauseElement(String clauseElement) {
+            if (_filterTargetColumnInfoSet == null
+                    || _filterTargetColumnInfoSet.isEmpty()) {
+                return toEmbedded(clauseElement);
+            }
+            for (final java.util.Iterator ite = _filterTargetColumnInfoSet
+                    .iterator(); ite.hasNext();) {
+                final ColumnInfo columnInfo = (ColumnInfo) ite.next();
+                if (isTargetClause(clauseElement, columnInfo.getColumnDbName())) {
+                    return toEmbedded(clauseElement);
+                }
+            }
+            return clauseElement;
+        }
+
+        protected boolean isTargetClause(String clauseElement,
+                final String columnDbName) {
+            return clauseElement.indexOf("." + columnDbName + " ") >= 0;
+        }
+
+        protected String toEmbedded(String clauseElement) {
+            clauseElement = replace(clauseElement, BIND_COMMENT_BEGIN_PART,
+                    EMBEDDED_COMMENT_BEGIN_PART);
+            clauseElement = replace(clauseElement, BIND_COMMENT_END_PART,
+                    EMBEDDED_COMMENT_END_PART);
+            return clauseElement;
+        }
+
+        protected final String replace(String text, String fromText,
+                String toText) {
+
+            if (text == null || fromText == null || toText == null) {
+                return null;
+            }
+            StringBuffer buf = new StringBuffer(100);
+            int pos = 0;
+            int pos2 = 0;
+            while (true) {
+                pos = text.indexOf(fromText, pos2);
+                if (pos == 0) {
+                    buf.append(toText);
+                    pos2 = fromText.length();
+                } else if (pos > 0) {
+                    buf.append(text.substring(pos2, pos));
+                    buf.append(toText);
+                    pos2 = pos + fromText.length();
+                } else {
+                    buf.append(text.substring(pos2));
+                    break;
+                }
+            }
+            return buf.toString();
+        }
+    }
+
+    /**
+     * The simple filter for where clause to embedded and quoted. <br />
+     * *Attension -- Target column is not perfect. This class determines by column name only!
+     * So when the column name of base table is same as the column name of join table, both are target!
+     * 
+     * @author DBFlute(AutoGenerator)
+     */
+    public static class WhereClauseToEmbeddedQuotedSimpleFilter extends
+            WhereClauseToEmbeddedSimpleFilter {
+
+        public WhereClauseToEmbeddedQuotedSimpleFilter(
+                ColumnInfo filterTargetColumnInfo) {
+            super(filterTargetColumnInfo);
+        }
+
+        public WhereClauseToEmbeddedQuotedSimpleFilter(
+                java.util.Set<ColumnInfo> filterTargetColumnInfoSet) {
+            super(filterTargetColumnInfoSet);
+        }
+
+        protected String toEmbedded(String clauseElement) {
+            clauseElement = replace(clauseElement, BIND_COMMENT_BEGIN_PART,
+                    EMBEDDED_COMMENT_QUOTED_BEGIN_PART);
+            clauseElement = replace(clauseElement, BIND_COMMENT_END_PART,
+                    EMBEDDED_COMMENT_QUOTED_END_PART);
+            return clauseElement;
+        }
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/cbean/sqlclause/WhereClauseSimpleFilter.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/AbstractDBMeta.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/AbstractDBMeta.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/AbstractDBMeta.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,883 @@
+package jp.sf.pal.announcement.db.allcommon.dbmeta;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+
+import jp.sf.pal.announcement.db.allcommon.Entity;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.ColumnInfo;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.ForeignInfo;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.ReferrerInfo;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.RelationInfo;
+import jp.sf.pal.announcement.db.allcommon.helper.MapListString;
+import jp.sf.pal.announcement.db.allcommon.helper.MapListStringImpl;
+import jp.sf.pal.announcement.db.allcommon.helper.MapStringBuilder;
+import jp.sf.pal.announcement.db.allcommon.helper.MapStringBuilderImpl;
+import jp.sf.pal.announcement.db.allcommon.util.SimpleAssertUtil;
+import jp.sf.pal.announcement.db.allcommon.util.SimpleStringUtil;
+
+/**
+ * The abstract class of dbmeta.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+ @ SuppressWarnings("unchecked")
+public abstract class AbstractDBMeta implements DBMeta {
+
+    // =====================================================================================
+    //                                                                         Name Handling
+    //                                                                         =============
+    /**
+     * The implementation.
+     * 
+     * @param flexibleName Flexible-name(IgnoreCase). (NotNull and NotEmpty)
+     * @return Determination.
+     */
+    public boolean hasFlexibleName(String flexibleName) {
+        final String key = flexibleName.toLowerCase();
+        if (getDbNamePropertyNameKeyToLowerMap().containsKey(key)) {
+            return true;
+        }
+        if (getPropertyNameDbNameKeyToLowerMap().containsKey(key)) {
+            return true;
+        }
+        return false;
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param flexibleName Flexible-name(IgnoreCase). (NotNull and NotEmpty)
+     * @return DB name. (NotNull and NotEmpty)
+     */
+    public String findDbName(String flexibleName) {
+        final String key = flexibleName.toLowerCase();
+        if (getPropertyNameDbNameKeyToLowerMap().containsKey(key)) {
+            return (String) getPropertyNameDbNameKeyToLowerMap().get(key);
+        }
+        if (getDbNamePropertyNameKeyToLowerMap().containsKey(key)) {
+            final String dbNameKeyToLower = ((String) getDbNamePropertyNameKeyToLowerMap()
+                    .get(key)).toLowerCase();
+            if (getPropertyNameDbNameKeyToLowerMap().containsKey(
+                    dbNameKeyToLower)) {
+                return (String) getPropertyNameDbNameKeyToLowerMap().get(
+                        dbNameKeyToLower);
+            }
+        }
+        String msg = "Not found object by the flexible name: flexibleName="
+                + flexibleName;
+        throw new IllegalStateException(msg);
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param flexibleName Flexible-name(IgnoreCase). (NotNull and NotEmpty)
+     * @return DB name. (NotNull and NotEmpty)
+     */
+    public String findPropertyName(String flexibleName) {
+        final String key = flexibleName.toLowerCase();
+        if (getDbNamePropertyNameKeyToLowerMap().containsKey(key)) {
+            return (String) getDbNamePropertyNameKeyToLowerMap().get(key);
+        }
+        if (getPropertyNameDbNameKeyToLowerMap().containsKey(key)) {
+            final String dbNameToLower = ((String) getPropertyNameDbNameKeyToLowerMap()
+                    .get(key)).toLowerCase();
+            if (getDbNamePropertyNameKeyToLowerMap().containsKey(dbNameToLower)) {
+                return (String) getDbNamePropertyNameKeyToLowerMap().get(
+                        dbNameToLower);
+            }
+        }
+        String msg = "Not found object by the flexible name: flexibleName="
+                + flexibleName;
+        throw new IllegalStateException(msg);
+    }
+
+    // ===================================================================================
+    //                                                                         Column Info
+    //                                                                         ===========
+    /**
+     * The implementation.
+     * 
+     * @param columnFlexibleName The flexible name of the column. (NotNull)
+     * @return Determination.
+     */
+    public boolean hasColumn(String columnFlexibleName) {
+        if (!hasFlexibleName(columnFlexibleName)) {
+            return false;
+        }
+        final String propertyName = findPropertyName(columnFlexibleName);
+        return hasMethod("column" + initCap(propertyName));
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param columnFlexibleName The flexible name of the column. (NotNull and NotEmpty)
+     * @return The information of the column. (NotNull)
+     */
+    public ColumnInfo findColumnInfo(String columnFlexibleName) {
+        assertStringNotNullAndNotTrimmedEmpty("columnFlexibleName",
+                columnFlexibleName);
+        if (!hasColumn(columnFlexibleName)) {
+            String msg = "Not found column by columnFlexibleName: "
+                    + columnFlexibleName;
+            msg = msg + " tableName=" + getTableDbName();
+            throw new IllegalArgumentException(msg);
+        }
+        final String propertyName = findPropertyName(columnFlexibleName);
+        final String methodName = "column" + initCap(propertyName);
+        java.lang.reflect.Method method = null;
+        try {
+            method = this.getClass().getMethod(methodName, new Class[] {});
+        } catch (NoSuchMethodException e) {
+            String msg = "Not found column by columnFlexibleName: "
+                    + columnFlexibleName;
+            msg = msg + " tableName=" + getTableDbName() + " methodName="
+                    + methodName;
+            throw new RuntimeException(msg, e);
+        }
+        try {
+            return (ColumnInfo) method.invoke(this, new Object[] {});
+        } catch (IllegalAccessException e) {
+            throw new RuntimeException(e);
+        } catch (java.lang.reflect.InvocationTargetException e) {
+            throw new RuntimeException(e.getCause());
+        }
+    }
+
+    // ===================================================================================
+    //                                                                       Relation Info
+    //                                                                       =============
+    /**
+     * The implementation.
+     * 
+     * @param relationPropertyName Relation property name. (Both OK - InitCap or not). (NotNull)
+     * @return The information of relation. (NotNull)
+     */
+    public RelationInfo findRelationInfo(String relationPropertyName) {
+        assertStringNotNullAndNotTrimmedEmpty("relationPropertyName",
+                relationPropertyName);
+        return hasForeign(relationPropertyName) ? (RelationInfo) findForeignInfo(relationPropertyName)
+                : (RelationInfo) findReferrerInfo(relationPropertyName);
+    }
+
+    // -----------------------------------------------------
+    //                                       Foreign Element
+    //                                       ---------------
+    /**
+     * The implementation.
+     * 
+     * @param foreignPropertyName The property name of foreign. (Both OK - InitCap or not). (NotNull)
+     * @return Determination. (NotNull)
+     */
+    public boolean hasForeign(String foreignPropertyName) {
+        assertStringNotNullAndNotTrimmedEmpty("foreignPropertyName",
+                foreignPropertyName);
+        final String methodName = buildRelationInfoGetterMethodNameInitCap(
+                "foreign", foreignPropertyName);
+        return hasMethod(methodName);
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param foreignPropertyName The property name of foreign. (Both OK - InitCap or not). (NotNull)
+     * @return Foreign DBMeta. (NotNull)
+     */
+    public DBMeta findForeignDBMeta(String foreignPropertyName) {
+        return findForeignInfo(foreignPropertyName).getForeignDBMeta();
+    }
+
+    /**
+     * Get foreign information.
+     * 
+     * @param foreignPropertyName The property name of foreign. (Both OK - InitCap or not). (NotNull)
+     * @return Foreign information. (NotNull)
+     */
+    public jp.sf.pal.announcement.db.allcommon.dbmeta.info.ForeignInfo findForeignInfo(
+            String foreignPropertyName) {
+        assertStringNotNullAndNotTrimmedEmpty("foreignPropertyName",
+                foreignPropertyName);
+        final String methodName = buildRelationInfoGetterMethodNameInitCap(
+                "foreign", foreignPropertyName);
+        java.lang.reflect.Method method = null;
+        try {
+            method = this.getClass().getMethod(methodName, new Class[] {});
+        } catch (NoSuchMethodException e) {
+            String msg = "Not found foreign by foreignPropertyName: foreignPropertyName="
+                    + foreignPropertyName;
+            msg = msg + " tableName=" + getTableDbName() + " methodName="
+                    + methodName;
+            throw new RuntimeException(msg, e);
+        }
+        try {
+            return (ForeignInfo) method.invoke(this, new Object[] {});
+        } catch (IllegalAccessException e) {
+            throw new RuntimeException(e);
+        } catch (java.lang.reflect.InvocationTargetException e) {
+            throw new RuntimeException(e.getCause());
+        }
+    }
+
+    // -----------------------------------------------------
+    //                                      Referrer Element
+    //                                      ----------------
+
+    /**
+     * The implementation.
+     * 
+     * @param referrerPropertyName The property name of referrer. (Both OK - InitCap or not). (NotNull)
+     * @return Determination. (NotNull)
+     */
+    public boolean hasReferrer(String referrerPropertyName) {
+        assertStringNotNullAndNotTrimmedEmpty("referrerPropertyName",
+                referrerPropertyName);
+        final String methodName = buildRelationInfoGetterMethodNameInitCap(
+                "referrer", referrerPropertyName);
+        return hasMethod(methodName);
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param referrerPropertyName The property name of referrer. (Both OK - InitCap or not). (NotNull)
+     * @return Referrer DBMeta. (NotNull)
+     */
+    public DBMeta findReferrerDBMeta(String referrerPropertyName) {
+        assertStringNotNullAndNotTrimmedEmpty("referrerPropertyName",
+                referrerPropertyName);
+        return findReferrerInfo(referrerPropertyName).getReferrerDBMeta();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param referrerPropertyName The property name of referrer. (Both OK - InitCap or not). (NotNull)
+     * @return Referrer information. (NotNull)
+     */
+    public ReferrerInfo findReferrerInfo(String referrerPropertyName) {
+        assertStringNotNullAndNotTrimmedEmpty("referrerPropertyName",
+                referrerPropertyName);
+        final String methodName = buildRelationInfoGetterMethodNameInitCap(
+                "referrer", referrerPropertyName);
+        java.lang.reflect.Method method = null;
+        try {
+            method = this.getClass().getMethod(methodName, new Class[] {});
+        } catch (NoSuchMethodException e) {
+            String msg = "Not found referrer by referrerPropertyName: referrerPropertyName="
+                    + referrerPropertyName;
+            msg = msg + " tableName=" + getTableDbName() + " methodName="
+                    + methodName;
+            throw new RuntimeException(msg, e);
+        }
+        try {
+            return (ReferrerInfo) method.invoke(this, new Object[] {});
+        } catch (IllegalAccessException e) {
+            throw new RuntimeException(e);
+        } catch (java.lang.reflect.InvocationTargetException e) {
+            throw new RuntimeException(e.getCause());
+        }
+    }
+
+    protected String buildRelationInfoGetterMethodNameInitCap(
+            String targetName, String relationPropertyName) {
+        return targetName + relationPropertyName.substring(0, 1).toUpperCase()
+                + relationPropertyName.substring(1);
+    }
+
+    // -----------------------------------------------------
+    //                                        Relation Trace
+    //                                        --------------
+    /**
+     * Relation trace.
+     */
+    protected static abstract class AbstractRelationTrace implements
+            RelationTrace {
+
+        /** The list of relation. */
+        protected List<RelationInfo> _relationList;
+
+        /** The list of relation trace. */
+        protected List<AbstractRelationTrace> _relationTraceList;
+
+        /** The list of relation info as trace. */
+        protected List<RelationInfo> _traceRelationInfoList;
+
+        /** The column info as trace. */
+        protected ColumnInfo _traceColumnInfo;
+
+        /** The handler of fixed relation trace. */
+        protected RelationTraceFixHandler _relationTraceFixHandler;
+
+        /**
+         * Constructor for first step.
+         * 
+         * @param relationTraceFixHandler The handler of fixed relation trace. (Nullable)
+         */
+        public AbstractRelationTrace(
+                RelationTraceFixHandler relationTraceFixHandler) {
+            this(new ArrayList<RelationInfo>(),
+                    new ArrayList<AbstractRelationTrace>());
+            this._relationTraceFixHandler = relationTraceFixHandler;
+        }
+
+        /**
+         * Constructor for relation step.
+         * 
+         * @param relationList The list of relation. (NotNull)
+         * @param relationTraceList The list of relation trace. (NotNull)
+         */
+        public AbstractRelationTrace(List<RelationInfo> relationList,
+                List<AbstractRelationTrace> relationTraceList) {
+            this._relationList = relationList;
+            this._relationTraceList = relationTraceList;
+            this._relationTraceList.add(this);
+        }
+
+        /**
+         * The implementation.
+         * 
+         * @return The trace of relation as the list of relation info. (NotNull)
+         */
+        public List<RelationInfo> getTraceRelation() {
+            return _traceRelationInfoList;
+        }
+
+        /**
+         * The implementation.
+         * 
+         * @return The trace of column as column info. (Nullable)
+         */
+        public ColumnInfo getTraceColumn() {
+            return _traceColumnInfo;
+        }
+
+        /**
+         * Fix trace.
+         * 
+         * @param traceRelationInfoList The trace of relation as the list of relation info. (NotNull)
+         * @param traceColumnInfo The trace of column as column info. (Nullable)
+         * @return Relation trace(result). (NotNull)
+         */
+        protected RelationTrace fixTrace(
+                List<RelationInfo> traceRelationInfoList,
+                ColumnInfo traceColumnInfo) {
+            final AbstractRelationTrace localRelationTrace = (AbstractRelationTrace) _relationTraceList
+                    .get(0);
+            localRelationTrace.setTraceRelation(traceRelationInfoList);
+            localRelationTrace.setTraceColumn(traceColumnInfo);
+            localRelationTrace.recycle();
+            localRelationTrace.handleFixedRelationTrace();
+            return localRelationTrace;
+        }
+
+        protected void setTraceRelation(List<RelationInfo> traceRelationInfoList) {
+            this._traceRelationInfoList = traceRelationInfoList;
+        }
+
+        protected void setTraceColumn(ColumnInfo traceColumn) {
+            this._traceColumnInfo = traceColumn;
+        }
+
+        /**
+         * The implementation.
+         */
+        protected void recycle() {
+            this._relationList = new ArrayList<RelationInfo>();
+            this._relationTraceList = new ArrayList<AbstractRelationTrace>();
+            this._relationTraceList.add(this);
+        }
+
+        protected void handleFixedRelationTrace() {
+            if (_relationTraceFixHandler != null) {
+                _relationTraceFixHandler.handleFixedTrace(this);
+            }
+        }
+    }
+
+    // ===================================================================================
+    //                                                                        JDBC Support
+    //                                                                        ============
+    /**
+     * The implementation.
+     * 
+     * @param conn Connection. (NotNull)
+     * @param entity Entity. (NotNull)
+     * @return Prepared insert clause. (NotNull and NotEmpty)
+     */
+    public int insertEntity(java.sql.Connection conn, Entity entity) {
+        return insertEntity(conn, entity, new PreparedInsertClauseOption());
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @param conn Connection. (NotNull)
+     * @param entity Entity. (NotNull)
+     * @param preparedInsertClauseOption Prepared insert clause option. (NotNull)
+     * @return Prepared insert clause. (NotNull and NotEmpty)
+     */
+    public int insertEntity(java.sql.Connection conn, Entity entity,
+            PreparedInsertClauseOption preparedInsertClauseOption) {
+        checkDowncast(entity);
+        final String sql = getPreparedInsertClause(preparedInsertClauseOption);
+        java.sql.PreparedStatement ps = null;
+        try {
+            ps = conn.prepareStatement(sql);
+            final List<Object> valueList = convertToColumnValueList(entity);
+            int settingIndex = 1;
+            for (final Iterator<Object> ite = valueList.iterator(); ite
+                    .hasNext();) {
+                Object value = ite.next();
+                if (value == null) {
+                    ps.setNull(settingIndex, java.sql.Types.VARCHAR);// Giving a clear-cut attitude!
+                } else {
+                    ps.setObject(settingIndex, value);
+                }
+                ++settingIndex;
+            }
+            return ps.executeUpdate();
+        } catch (java.sql.SQLException e) {
+            String msg = "The sql threw the exception: sql=" + sql;
+            throw new RuntimeException(msg, e);
+        } finally {
+            if (ps != null) {
+                try {
+                    ps.close();
+                } catch (java.sql.SQLException ignored) {
+                }
+            }
+        }
+    }
+
+    // ===================================================================================
+    //                                                                          Map String
+    //                                                                          ==========
+    /**
+     * The implementation.
+     * 
+     * @return Map list string that is prepared. (NotNull)
+     */
+    public MapListString createMapListString() {
+        return MapStringUtil.createMapListString();
+    }
+
+    /**
+     * The implementation.
+     * 
+     * @return Map string builder that is prepared. (NotNull)
+     */
+    public MapStringBuilder createMapStringBuilder() {
+        final List<String> columnDbNameList = new ArrayList<String>();
+        for (final Iterator<ColumnInfo> ite = getColumnInfoList().iterator(); ite
+                .hasNext();) {
+            final ColumnInfo columnInfo = (ColumnInfo) ite.next();
+            columnDbNameList.add(columnInfo.getColumnDbName());
+        }
+        return MapStringUtil.createMapStringBuilder(columnDbNameList);
+    }
+
+    // ===================================================================================
+    //                                                               Entity Property Setup
+    //                                                               =====================
+    // It's very INTERNAL!
+    protected <ENTITY extends Entity> void registerEntityPropertySetupper(
+            String columnName,
+            String propertyName,
+            EntityPropertySetupper<ENTITY> setupper,
+            Map<String, EntityPropertySetupper<ENTITY>> entityPropertySetupperMap) {
+        entityPropertySetupperMap.put(columnName, setupper);
+        entityPropertySetupperMap.put(propertyName, setupper);
+        entityPropertySetupperMap.put(columnName.toLowerCase(), setupper);
+        entityPropertySetupperMap.put(propertyName.toLowerCase(), setupper);
+    }
+
+    // ===================================================================================
+    //                                                                          Util Class
+    //                                                                          ==========
+    /**
+     * This class is for Internal. Don't use this!
+     */
+    protected static class MapStringUtil {
+        public static void acceptPrimaryKeyMapString(
+                String primaryKeyMapString, Entity entity) {
+            if (primaryKeyMapString == null) {
+                String msg = "The argument[primaryKeyMapString] should not be null.";
+                throw new IllegalArgumentException(msg);
+            }
+            final String prefix = MAP_STRING_MAP_MARK + MAP_STRING_START_BRACE;
+            final String suffix = MAP_STRING_END_BRACE;
+            if (!primaryKeyMapString.trim().startsWith(prefix)) {
+                primaryKeyMapString = prefix + primaryKeyMapString;
+            }
+            if (!primaryKeyMapString.trim().endsWith(suffix)) {
+                primaryKeyMapString = primaryKeyMapString + suffix;
+            }
+            MapListString mapListString = createMapListString();
+            entity.getDBMeta().acceptPrimaryKeyMap(entity,
+                    mapListString.generateMap(primaryKeyMapString));
+        }
+
+        public static void acceptColumnValueMapString(
+                String columnValueMapString, Entity entity) {
+            if (columnValueMapString == null) {
+                String msg = "The argument[columnValueMapString] should not be null.";
+                throw new IllegalArgumentException(msg);
+            }
+            final String prefix = MAP_STRING_MAP_MARK + MAP_STRING_START_BRACE;
+            final String suffix = MAP_STRING_END_BRACE;
+            if (!columnValueMapString.trim().startsWith(prefix)) {
+                columnValueMapString = prefix + columnValueMapString;
+            }
+            if (!columnValueMapString.trim().endsWith(suffix)) {
+                columnValueMapString = columnValueMapString + suffix;
+            }
+            MapListString mapListString = createMapListString();
+            entity.getDBMeta().acceptColumnValueMap(entity,
+                    mapListString.generateMap(columnValueMapString));
+        }
+
+        public static String extractPrimaryKeyMapString(Entity entity) {
+            final String startBrace = MAP_STRING_START_BRACE;
+            final String endBrace = MAP_STRING_END_BRACE;
+            final String delimiter = MAP_STRING_DELIMITER;
+            final String equal = MAP_STRING_EQUAL;
+            return entity.getDBMeta().extractPrimaryKeyMapString(entity,
+                    startBrace, endBrace, delimiter, equal);
+        }
+
+        public static String extractColumnValueMapString(Entity entity) {
+            final String startBrace = MAP_STRING_START_BRACE;
+            final String endBrace = MAP_STRING_END_BRACE;
+            final String delimiter = MAP_STRING_DELIMITER;
+            final String equal = MAP_STRING_EQUAL;
+            return entity.getDBMeta().extractColumnValueMapString(entity,
+                    startBrace, endBrace, delimiter, equal);
+        }
+
+        public static void checkTypeString(Object value, String propertyName,
+                String typeName) {
+            if (value == null) {
+                throw new IllegalArgumentException(
+                        "The value should not be null: " + propertyName);
+            }
+            if (!(value instanceof String)) {
+                String msg = "The value of " + propertyName + " should be "
+                        + typeName + " or String: ";
+                msg = msg + "valueType=" + value.getClass() + " value=" + value;
+                throw new IllegalArgumentException(msg);
+            }
+        }
+
+        public static long parseDateStringAsMillis(Object value,
+                String propertyName, String typeName) {
+            checkTypeString(value, propertyName, typeName);
+            try {
+                final String valueString = filterTimestampValue(((String) value)
+                        .trim());
+                return java.sql.Timestamp.valueOf(valueString).getTime();
+            } catch (RuntimeException e) {
+                String msg = "The value of " + propertyName + " should be "
+                        + typeName + ". but: " + value;
+                throw new RuntimeException(msg
+                        + " threw the exception: value=[" + value + "]", e);
+            }
+        }
+
+        public static String filterTimestampValue(String value) {
+            value = value.trim();
+            if (value.indexOf("/") == 4 && value.lastIndexOf("/") == 7) {
+                value = value.replaceAll("/", "-");
+            }
+            if (value.indexOf("-") == 4 && value.lastIndexOf("-") == 7) {
+                if (value.length() == "2007-07-09".length()) {
+                    value = value + " 00:00:00";
+                }
+            }
+            return value;
+        }
+
+        public static String formatDate(java.util.Date value) {
+            return getFormatDateFormat().format(value);
+        }
+
+        public static String formatTimestamp(java.sql.Timestamp value) {
+            return getFormatDateFormat().format(value);
+        }
+
+        public static java.text.DateFormat getParseDateFormat() {
+            return java.text.DateFormat.getDateInstance();
+        }
+
+        public static java.text.DateFormat getFormatDateFormat() {
+            return new java.text.SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS");
+        }
+
+        public static MapListString createMapListString() {
+            final MapListString mapListString = new MapListStringImpl();
+            mapListString.setMapMark(MAP_STRING_MAP_MARK);
+            mapListString.setListMark(MAP_STRING_LIST_MARK);
+            mapListString.setStartBrace(MAP_STRING_START_BRACE);
+            mapListString.setEndBrace(MAP_STRING_END_BRACE);
+            mapListString.setEqual(MAP_STRING_EQUAL);
+            mapListString.setDelimiter(MAP_STRING_DELIMITER);
+            return mapListString;
+        }
+
+        public static MapStringBuilder createMapStringBuilder(
+                List<String> columnNameList) {
+            MapStringBuilder mapStringBuilder = new MapStringBuilderImpl();
+            mapStringBuilder.setMsMapMark(MAP_STRING_MAP_MARK);
+            mapStringBuilder.setMsStartBrace(MAP_STRING_START_BRACE);
+            mapStringBuilder.setMsEndBrace(MAP_STRING_END_BRACE);
+            mapStringBuilder.setMsEqual(MAP_STRING_EQUAL);
+            mapStringBuilder.setMsDelimiter(MAP_STRING_DELIMITER);
+            mapStringBuilder.setColumnNameList(columnNameList);
+            return mapStringBuilder;
+        }
+    }
+
+    /**
+     * This class is for Internal. Don't use this!
+     */
+    protected static class MapAssertUtil {
+        public static void assertPrimaryKeyMapNotNullAndNotEmpty(
+                java.util.Map<String, ? extends Object> primaryKeyMap) {
+            if (primaryKeyMap == null) {
+                String msg = "The argument[primaryKeyMap] should not be null.";
+                throw new IllegalArgumentException(msg);
+            }
+            if (primaryKeyMap.isEmpty()) {
+                String msg = "The argument[primaryKeyMap] should not be empty.";
+                throw new IllegalArgumentException(msg);
+            }
+        }
+
+        public static void assertColumnExistingInPrimaryKeyMap(
+                java.util.Map<String, ? extends Object> primaryKeyMap,
+                String columnName) {
+            if (!primaryKeyMap.containsKey(columnName)) {
+                String msg = "The primaryKeyMap must have the value of "
+                        + columnName;
+                throw new IllegalStateException(msg + ": primaryKeyMap --> "
+                        + primaryKeyMap);
+            }
+        }
+
+        public static void assertColumnValueMapNotNullAndNotEmpty(
+                java.util.Map<String, ? extends Object> columnValueMap) {
+            if (columnValueMap == null) {
+                String msg = "The argument[columnValueMap] should not be null.";
+                throw new IllegalArgumentException(msg);
+            }
+            if (columnValueMap.isEmpty()) {
+                String msg = "The argument[columnValueMap] should not be empty.";
+                throw new IllegalArgumentException(msg);
+            }
+        }
+    }
+
+    /**
+     * This class is for Internal. Don't use this!
+     */
+    protected static class MapStringValueAnalyzer {
+        protected java.util.Map<String, ? extends Object> _valueMap;
+
+        protected java.util.Set<String> _modifiedPropertyNames;
+
+        protected String _columnName;
+
+        protected String _uncapPropName;
+
+        protected String _propertyName;
+
+        public MapStringValueAnalyzer(
+                java.util.Map<String, ? extends Object> valueMap,
+                java.util.Set<String> modifiedPropertyNames) {
+            this._valueMap = valueMap;
+            this._modifiedPropertyNames = modifiedPropertyNames;
+        }
+
+        public boolean init(String columnName, String uncapPropName,
+                String propertyName) {
+            this._columnName = columnName;
+            this._uncapPropName = uncapPropName;
+            this._propertyName = propertyName;
+            return _valueMap.containsKey(_columnName);
+        }
+
+        public <COLUMN_TYPE> COLUMN_TYPE analyzeString(
+                Class<COLUMN_TYPE> javaType) {
+            final Object obj = _valueMap.get(_columnName);
+            if (obj == null) {
+                _modifiedPropertyNames.remove(_propertyName);
+                return null;
+            }
+            helpCheckingTypeString(obj, _uncapPropName, javaType.getName());
+            return (COLUMN_TYPE) obj;
+        }
+
+        public <COLUMN_TYPE> COLUMN_TYPE analyzeNumber(
+                Class<COLUMN_TYPE> javaType) {
+            final Object obj = _valueMap.get(_columnName);
+            if (obj == null) {
+                _modifiedPropertyNames.remove(_propertyName);
+                return null;
+            }
+            if (javaType.isAssignableFrom(obj.getClass())) {
+                return (COLUMN_TYPE) obj;
+            }
+            return (COLUMN_TYPE) newInstanceByConstructor(javaType,
+                    String.class, obj.toString());
+        }
+
+        public <COLUMN_TYPE> COLUMN_TYPE analyzeDate(Class<COLUMN_TYPE> javaType) {
+            final Object obj = _valueMap.get(_columnName);
+            if (obj == null) {
+                _modifiedPropertyNames.remove(_propertyName);
+                return null;
+            }
+            if (javaType.isAssignableFrom(obj.getClass())) {
+                return (COLUMN_TYPE) obj;
+            }
+            return (COLUMN_TYPE) newInstanceByConstructor(javaType, long.class,
+                    helpParsingDateString(obj, _uncapPropName, javaType
+                            .getName()));
+        }
+
+        public <COLUMN_TYPE> COLUMN_TYPE analyzeOther(
+                Class<COLUMN_TYPE> javaType) {
+            final Object obj = _valueMap.get(_columnName);
+            if (obj == null) {
+                _modifiedPropertyNames.remove(_propertyName);
+                return null;
+            }
+            return (COLUMN_TYPE) obj;
+        }
+
+        private void helpCheckingTypeString(Object value, String uncapPropName,
+                String typeName) {
+            MapStringUtil.checkTypeString(value, uncapPropName, typeName);
+        }
+
+        private long helpParsingDateString(Object value, String uncapPropName,
+                String typeName) {
+            return MapStringUtil.parseDateStringAsMillis(value, uncapPropName,
+                    typeName);
+        }
+
+        protected Object newInstanceByConstructor(Class targetType,
+                Class argType, Object arg) {
+            java.lang.reflect.Constructor constructor;
+            try {
+                constructor = targetType
+                        .getConstructor(new Class[] { argType });
+            } catch (SecurityException e) {
+                String msg = "targetType=" + targetType + " argType=" + argType
+                        + " arg=" + arg;
+                throw new RuntimeException(msg, e);
+            } catch (NoSuchMethodException e) {
+                String msg = "targetType=" + targetType + " argType=" + argType
+                        + " arg=" + arg;
+                throw new RuntimeException(msg, e);
+            }
+            try {
+                return constructor.newInstance(new Object[] { arg });
+            } catch (IllegalArgumentException e) {
+                String msg = "targetType=" + targetType + " argType=" + argType
+                        + " arg=" + arg;
+                throw new RuntimeException(msg, e);
+            } catch (InstantiationException e) {
+                String msg = "targetType=" + targetType + " argType=" + argType
+                        + " arg=" + arg;
+                throw new RuntimeException(msg, e);
+            } catch (IllegalAccessException e) {
+                String msg = "targetType=" + targetType + " argType=" + argType
+                        + " arg=" + arg;
+                throw new RuntimeException(msg, e);
+            } catch (java.lang.reflect.InvocationTargetException e) {
+                String msg = "targetType=" + targetType + " argType=" + argType
+                        + " arg=" + arg;
+                throw new RuntimeException(msg, e);
+            }
+        }
+    }
+
+    // ===================================================================================
+    //                                                                       Assist Helper
+    //                                                                       =============
+    abstract protected void checkDowncast(Entity entity);
+
+    protected String helpGettingColumnStringValue(Object value) {
+        if (value instanceof java.sql.Timestamp) {
+            return (value != null ? helpFormatingTimestamp((java.sql.Timestamp) value)
+                    : "");
+        } else if (value instanceof java.util.Date) {
+            return (value != null ? helpFormatingDate((java.util.Date) value)
+                    : "");
+        } else {
+            return (value != null ? value.toString() : "");
+        }
+    }
+
+    protected String helpFormatingDate(java.util.Date date) {
+        return MapStringUtil.formatDate(date);
+    }
+
+    protected String helpFormatingTimestamp(java.sql.Timestamp timestamp) {
+        return MapStringUtil.formatTimestamp(timestamp);
+    }
+
+    // ===================================================================================
+    //                                                                      General Helper
+    //                                                                      ==============
+    // -----------------------------------------------------
+    //                                   Reflection Handling
+    //                                   -------------------
+    protected boolean hasMethod(String methodName) {
+        assertStringNotNullAndNotTrimmedEmpty("methodName", methodName);
+        try {
+            this.getClass().getMethod(methodName, new Class[] {});
+            return true;
+        } catch (NoSuchMethodException ignored) {
+            return false;
+        }
+    }
+
+    // -----------------------------------------------------
+    //                                       String Handling
+    //                                       ---------------
+    protected String initCap(String str) {
+        return SimpleStringUtil.initCap(str);
+    }
+
+    // -----------------------------------------------------
+    //                                         Assert Object
+    //                                         -------------
+    /**
+     * Assert that the argument is not null.
+     * 
+     * @param variableName Variable name. (NotNull)
+     * @param arg Argument. (NotNull)
+     */
+    protected void assertObjectNotNull(String variableName, Object value) {
+        SimpleAssertUtil.assertObjectNotNull(variableName, value);
+    }
+
+    // -----------------------------------------------------
+    //                                         Assert String
+    //                                         -------------
+    /**
+     * Assert that the string is not null and not trimmed empty.
+     * 
+     * @param variableName Variable name. (NotNull)
+     * @param value Value. (NotNull)
+     */
+    protected void assertStringNotNullAndNotTrimmedEmpty(String variableName,
+            String value) {
+        SimpleAssertUtil.assertStringNotNullAndNotTrimmedEmpty(variableName,
+                value);
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/AbstractDBMeta.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/DBMeta.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/DBMeta.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/DBMeta.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,626 @@
+package jp.sf.pal.announcement.db.allcommon.dbmeta;
+
+import java.sql.Connection;
+import java.util.List;
+import java.util.Map;
+
+import jp.sf.pal.announcement.db.allcommon.Entity;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.ColumnInfo;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.ForeignInfo;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.ReferrerInfo;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.RelationInfo;
+import jp.sf.pal.announcement.db.allcommon.dbmeta.info.UniqueInfo;
+import jp.sf.pal.announcement.db.allcommon.helper.MapListString;
+import jp.sf.pal.announcement.db.allcommon.helper.MapStringBuilder;
+
+/**
+ * The interface of dbmeta.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+ @ SuppressWarnings("unchecked")
+public interface DBMeta {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** Map-string map-mark. */
+    public static final String MAP_STRING_MAP_MARK = "map:";
+
+    /** Map-string list-mark. */
+    public static final String MAP_STRING_LIST_MARK = "list:";
+
+    /** Map-string start-brace. */
+    public static final String MAP_STRING_START_BRACE = "@{";
+
+    /** Map-string end-brace. */
+    public static final String MAP_STRING_END_BRACE = "@}";
+
+    /** Map-string delimiter. */
+    public static final String MAP_STRING_DELIMITER = "@;";
+
+    /** Map-string equal. */
+    public static final String MAP_STRING_EQUAL = "@=";
+
+    // ===================================================================================
+    //                                                                          Table Name
+    //                                                                          ==========
+    /**
+     * Get table db-name.
+     * 
+     * @return Table db-name. (NotNull)
+     */
+    public String getTableDbName();
+
+    /**
+     * Get table prop-name(JavaBeansRule).
+     * 
+     * @return Table property-name(JavaBeansRule). (NotNull)
+     */
+    public String getTablePropertyName();
+
+    // ===================================================================================
+    //                                                                       Name Handling
+    //                                                                       =============
+    /**
+     * Has object of flexible name? {Target objects are TABLE and COLUMN}
+     * 
+     * @param flexibleName The flexible name. (NotNull and NotEmpty)
+     * @return Determination.
+     */
+    public boolean hasFlexibleName(String flexibleName);
+
+    /**
+     * Find db name by flexible name. {Target objects are TABLE and COLUMN}
+     * 
+     * @param flexibleName The flexible name. (NotNull and NotEmpty)
+     * @return Db name. (NotNull and NotEmpty)
+     */
+    public String findDbName(String flexibleName);
+
+    /**
+     * Find property name(JavaBeansRule) by flexible name. {Target objects are TABLE and COLUMN}
+     * 
+     * @param flexibleName The flexible name. (NotNull and NotEmpty)
+     * @return Db name. (NotNull and NotEmpty)
+     */
+    public String findPropertyName(String flexibleName);
+
+    // ===================================================================================
+    //                                                                            Name Map
+    //                                                                            ========
+    /**
+     * Get the key-to-lower map of DB name(lower) and property name.
+     * 
+     * @return The key-to-lower map of DB name(lower) and property name. (NotNull)
+     */
+    public Map<String, String> getDbNamePropertyNameKeyToLowerMap();
+
+    /**
+     * Get the key-to-lower map of property name(lower) and db name.
+     * 
+     * @return The key-to-lower map of property name(lower) and db name. (NotNull)
+     */
+    public Map<String, String> getPropertyNameDbNameKeyToLowerMap();
+
+    // ===================================================================================
+    //                                                                           Type Name
+    //                                                                           =========
+    /**
+     * Get the type-name of entity.
+     * 
+     * @return The type-name of entity. (NotNull)
+     */
+    public String getEntityTypeName();
+
+    /**
+     * Get the type-name of condition-bean.
+     * 
+     * @return The type-name of condition-bean. (Nullable: If the condition-bean does not exist)
+     */
+    public String getConditionBeanTypeName();
+
+    /**
+     * Get the type-name of dao.
+     * 
+     * @return The type-name of dao. (Nullable: If the dao does not exist)
+     */
+    public String getDaoTypeName();
+
+    /**
+     * Get the type-name of behavior.
+     * 
+     * @return The type-name of behavior. (Nullable: If the behavior does not exist)
+     */
+    public String getBehaviorTypeName();
+
+    // ===================================================================================
+    //                                                                         Object Type
+    //                                                                         ===========
+    /**
+     * Get the type of entity.
+     * 
+     * @return The type of entity. (NotNull)
+     */
+    public Class<? extends Entity> getEntityType();
+
+    // ===================================================================================
+    //                                                                     Object Instance
+    //                                                                     ===============
+    /**
+     * New the instance of entity.
+     * 
+     * @return The instance of entity. (NotNull)
+     */
+    public Entity newEntity();
+
+    // ===================================================================================
+    //                                                                         Column Info
+    //                                                                         ===========
+    /**
+     * The implementation.
+     * 
+     * @return The list of DB name of column. (NotNull and NotEmpty)
+     */
+    public List<ColumnInfo> getColumnInfoList();
+
+    /**
+     * Has column?
+     * 
+     * @param columnFlexibleName The flexible name of the column. (NotNull)
+     * @return Determination.
+     */
+    public boolean hasColumn(String columnFlexibleName);
+
+    /**
+     * Find the information of the column by the flexible name of the column.
+     * <pre>
+     * If the table name is 'BOOK_ID', you can find the dbmeta by ...(as follows)
+     *     'BOOK_ID', 'BOok_iD', 'book_id'
+     *     , 'BookId', 'bookid', 'bOoKiD'
+     * </pre>
+     * @param columnFlexibleName The flexible name of the column. (NotNull)
+     * @return The information of the column. (NotNull)
+     */
+    public ColumnInfo findColumnInfo(String columnFlexibleName);
+
+    // ===================================================================================
+    //                                                                         Unique Info
+    //                                                                         ===========
+    /**
+     * Get primary unique info.
+     * 
+     * @return Primary unique info. (NotNull)
+     */
+    public UniqueInfo getPrimaryUniqueInfo();
+
+    /**
+     * Has primary-key?
+     * 
+     * @return Determination.
+     */
+    public boolean hasPrimaryKey();
+
+    /**
+     * Has two or more primary-keys?
+     * 
+     * @return Determination.
+     */
+    public boolean hasTwoOrMorePrimaryKeys();
+
+    // ===================================================================================
+    //                                                                       Relation Info
+    //                                                                       =============
+    // -----------------------------------------------------
+    //                                      Relation Element
+    //                                      ----------------
+    /**
+     * Find relation info.
+     * 
+     * @param relationPropertyName Relation property name. (Both OK - InitCap or not). (NotNull)
+     * @return Relation info. (NotNull)
+     */
+    public RelationInfo findRelationInfo(String relationPropertyName);
+
+    // -----------------------------------------------------
+    //                                       Foreign Element
+    //                                       ---------------
+    /**
+     * Has foreign?
+     * 
+     * @param foreignPropName Foreign property name. (Both OK - InitCap or not). (NotNull)
+     * @return Determination. (NotNull)
+     */
+    public boolean hasForeign(String foreignPropName);
+
+    /**
+     * Find foreign dbmeta.
+     * 
+     * @param foreignPropName Foreign property name. (Both OK - InitCap or not). (NotNull)
+     * @return Foreign DBMeta. (NotNull)
+     */
+    public DBMeta findForeignDBMeta(String foreignPropName);
+
+    /**
+     * Find foreign info.
+     * 
+     * @param foreignPropName Foreign property name. (Both OK - InitCap or not). (NotNull)
+     * @return Foreign info. (NotNull)
+     */
+    public ForeignInfo findForeignInfo(String foreignPropName);
+
+    // -----------------------------------------------------
+    //                                      Referrer Element
+    //                                      ----------------
+
+    /**
+     * Has referrer?
+     * 
+     * @param referrerPropertyName The property name of referrer. (Both OK - InitCap or not). (NotNull)
+     * @return Determination. (NotNull)
+     */
+    public boolean hasReferrer(String referrerPropertyName);
+
+    /**
+     * Find referrer dbmeta.
+     * 
+     * @param referrerPropertyName The property name of referrer. (Both OK - InitCap or not). (NotNull)
+     * @return Referrer DBMeta. (NotNull)
+     */
+    public DBMeta findReferrerDBMeta(String referrerPropertyName);
+
+    /**
+     * Find referrer information.
+     * 
+     * @param referrerPropertyName The property name of referrer. (Both OK - InitCap or not). (NotNull)
+     * @return Referrer information. (NotNull)
+     */
+    public ReferrerInfo findReferrerInfo(String referrerPropertyName);
+
+    // -----------------------------------------------------
+    //                                        Relation Trace
+    //                                        --------------
+    /**
+     * Relation trace.
+     */
+    public static interface RelationTrace {
+
+        /**
+         * Get the trace of relation.
+         * 
+         * @return The trace of relation as the list of relation info. (NotNull)
+         */
+        public List<RelationInfo> getTraceRelation();
+
+        /**
+         * Get the trace of column.
+         * 
+         * @return The trace of column as column info. (Nullable)
+         */
+        public ColumnInfo getTraceColumn();
+    }
+
+    public static interface RelationTraceFixHandler {
+        public void handleFixedTrace(RelationTrace relationTrace);
+    }
+
+    // ===================================================================================
+    //                                                                       Sequence Info
+    //                                                                       =============
+    /**
+     * Has sequence?
+     * 
+     * @return Determination.
+     */
+    public boolean hasSequence();
+
+    // ===================================================================================
+    //                                                                Optimistic Lock Info
+    //                                                                ====================
+    /**
+     * Has version no?
+     * 
+     * @return Determination.
+     */
+    public boolean hasVersionNo();
+
+    /**
+     * Has update date?
+     * 
+     * @return Determination.
+     */
+    public boolean hasUpdateDate();
+
+    // ===================================================================================
+    //                                                                  Common Column Info
+    //                                                                  ==================
+    /**
+     * Has common column?
+     * 
+     * @return Determination.
+     */
+    public boolean hasCommonColumn();
+
+    // ===================================================================================
+    //                                                                     Entity Handling
+    //                                                                     ===============
+    // -----------------------------------------------------
+    //                                                Accept
+    //                                                ------
+    /**
+     * Accept primary-key map.
+     * 
+     * The column that column-value map-string doesn't have the value of is reflected as null.
+     * The column that column-value map-string doesn't have the key of is NOT updated nothing.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @param primaryKeyMap Primary-key map. (NotNull and NotEmpty)
+     */
+    public void acceptPrimaryKeyMap(Entity entity,
+            Map<String, ? extends Object> primaryKeyMap);
+
+    /**
+     * Accept primary-key map-string.
+     * 
+     * The column that column-value map-string doesn't have the value of is reflected as null.
+     * The column that column-value map-string doesn't have the key of is NOT updated nothing.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @param primaryKeyMapString Primary-key map-string. (NotNull)
+     */
+    public void acceptPrimaryKeyMapString(Entity entity,
+            String primaryKeyMapString);
+
+    /**
+     * Accept column-value map.
+     * 
+     * The column that column-value map-string doesn't have the value of is reflected as null.
+     * The column that column-value map-string doesn't have the key of is NOT updated nothing.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @param columnValueMap Column-value map. (NotNull and NotEmpty)
+     */
+    public void acceptColumnValueMap(Entity entity,
+            Map<String, ? extends Object> columnValueMap);
+
+    /**
+     * Accept column-value map-string.
+     * 
+     * The column that column-value map-string doesn't have the value of is reflected as null.
+     * The column that column-value map-string doesn't have the key of is NOT updated nothing.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @param columnValueMapString Column-value map-string. (NotNull)
+     */
+    public void acceptColumnValueMapString(Entity entity,
+            String columnValueMapString);
+
+    // -----------------------------------------------------
+    //                                               Extract
+    //                                               -------
+    /**
+     * Extract primary-key map-string. Delimiter is at-mark and semicolon.
+     * <p>
+     * <pre>
+     * ex) Uses that this method have.
+     *   final String primaryKeyMapString = LdBookDbm.extractPrimaryKeyMapString(entity);
+     *   final LdBook entity = dao.selectEntity(new LdBookCB().acceptPrimaryKeyMapString(primaryKeyMapString));
+     *   ... // as primary key for condition.
+     * </pre>
+     * 
+     * @param entity Target entity. (NotNull)
+     * @return Primary-key map-string. (NotNull)
+     */
+    public String extractPrimaryKeyMapString(Entity entity);
+
+    /**
+     * Extract primary-key map-string.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @param startBrace Start-brace. (NotNull)
+     * @param endBrace End-brace. (NotNull)
+     * @param delimiter Delimiter. (NotNull)
+     * @param equal Equal. (NotNull)
+     * @return Primary-key map-string. (NotNull)
+     */
+    public String extractPrimaryKeyMapString(Entity entity, String startBrace,
+            String endBrace, String delimiter, String equal);
+
+    /**
+     * Extract column-value map-string. Delimiter is at-mark and semicolon.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @return Column-value map-string. (NotNull)
+     */
+    public String extractColumnValueMapString(Entity entity);
+
+    /**
+     * Extract column-value map-string.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @param startBrace Start-brace. (NotNull)
+     * @param endBrace End-brace. (NotNull)
+     * @param delimiter Delimiter. (NotNull)
+     * @param equal Equal. (NotNull)
+     * @return Column-value map-string. (NotNull)
+     */
+    public String extractColumnValueMapString(Entity entity, String startBrace,
+            String endBrace, String delimiter, String equal);
+
+    /**
+     * Extract common-column-value map-string.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @return Common-column-value map-string. (NotNull)
+     */
+    public String extractCommonColumnValueMapString(Entity entity);
+
+    /**
+     * Extract common-column-value map-string.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @param startBrace Start-brace. (NotNull)
+     * @param endBrace End-brace. (NotNull)
+     * @param delimiter Delimiter. (NotNull)
+     * @param equal Equal. (NotNull)
+     * @return Common-column-value map-string. (NotNull)
+     */
+    public String extractCommonColumnValueMapString(Entity entity,
+            String startBrace, String endBrace, String delimiter, String equal);
+
+    // -----------------------------------------------------
+    //                                               Convert
+    //                                               -------
+    /**
+     * Convert entity to column value as list.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @return The list of column value. (NotNull)
+     */
+    public List<Object> convertToColumnValueList(Entity entity);
+
+    /**
+     * Convert entity to column value as map.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @return The map of column value. (NotNull)
+     */
+    public Map<String, Object> convertToColumnValueMap(Entity entity);
+
+    /**
+     * Convert entity to column string-value as list.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @return The list of column string-value. (NotNull)
+     */
+    public List<String> convertToColumnStringValueList(Entity entity);
+
+    /**
+     * Convert entity to column string-value as map.
+     * 
+     * @param entity Target entity. (NotNull)
+     * @return The map of column string-value. (NotNull)
+     */
+    public Map<String, String> convertToColumnStringValueMap(Entity entity);
+
+    // ===================================================================================
+    //                                                                        JDBC Support
+    //                                                                        ============
+    /**
+     * Insert entity using specified connection.
+     * 
+     * @param conn Connection. (NotNull)
+     * @param entity Entity. (NotNull)
+     * @return Prepared insert clause. (NotNull and NotEmpty)
+     */
+    public int insertEntity(Connection conn, Entity entity);
+
+    /**
+     * Insert entity using specified connection.
+     * 
+     * @param conn Connection. (NotNull)
+     * @param entity Entity. (NotNull)
+     * @param preparedInsertClauseOption Prepared insert clause option. (NotNull)
+     * @return Prepared insert clause. (NotNull and NotEmpty)
+     */
+    public int insertEntity(Connection conn, Entity entity,
+            PreparedInsertClauseOption preparedInsertClauseOption);
+
+    /**
+     * Get prepared insert clause.
+     * 
+     * @return Prepared insert clause. (NotNull and NotEmpty)
+     */
+    public String getPreparedInsertClause();
+
+    /**
+     * Get prepared insert clause.
+     * 
+     * @param preparedInsertClauseOption Prepared insert clause option. (NotNull)
+     * @return Prepared insert clause. (NotNull and NotEmpty)
+     */
+    public String getPreparedInsertClause(
+            PreparedInsertClauseOption preparedInsertClauseOption);
+
+    /**
+     * The option of prepared insert clause.
+     */
+    public static class PreparedInsertClauseOption {
+
+        /** Table prefix. */
+        protected String _tablePrefix;
+
+        /**
+         * Get table prefix.
+         * 
+         * @return Table prefix. (Nullable)
+         */
+        public String getTablePrefix() {
+            return this._tablePrefix;
+        }
+
+        /**
+         * Set table prefix.
+         * 
+         * @param tablePrefix Table prefix. (Nullable)
+         */
+        public void setTablePrefix(String tablePrefix) {
+            this._tablePrefix = tablePrefix;
+        }
+    }
+
+    // ===================================================================================
+    //                                                                          Map String
+    //                                                                          ==========
+    /**
+     * Create map list string that is prepared. (for INTERNAL)
+     * 
+     * @return Map list string that is prepared. (NotNull)
+     */
+    public MapListString createMapListString();
+
+    /**
+     * Create map string builder that is prepared. (for INTERNAL)
+     * 
+     * @return Map string builder that is prepared. (NotNull)
+     */
+    public MapStringBuilder createMapStringBuilder();
+
+    // ===================================================================================
+    //                                                               Entity Property Setup
+    //                                                               =====================
+    // It's very INTERNAL!
+
+    /**
+     * Has the setupper of entity property by the name of property? <br />
+     * Comparing is so flexible. {Ignore cases and underscore}
+     * 
+     * @param propertyName The name of the property. (NotNull)
+     * @return Determination.
+     */
+    public boolean hasEntityPropertySetupper(String propertyName);
+
+    /**
+     * Set up entity property. (for INTERNAL)
+     * 
+     * @param propertyName The name of the property. (NotNull)
+     * @param entity The entity for the property. (NotNull)
+     * @param value The value of the property. (Nullable)
+     */
+    public void setupEntityProperty(String propertyName, Object entity,
+            Object value);
+
+    /**
+     * The setupper of entity property. <br />
+     * This class is for Internal. Don't use this!
+     * @param <ENTITY_TYPE> The type of entity.
+     */
+    public interface EntityPropertySetupper<ENTITY_TYPE extends Entity> {
+
+        /**
+         * @param entity Entity. (NotNull)
+         * @param value Value. (Nullable)
+         */
+        void setup(ENTITY_TYPE entity, Object value);
+    }
+}


Property changes on: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/DBMeta.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/DBMetaInstanceHandler.java
===================================================================
--- announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/DBMetaInstanceHandler.java	                        (rev 0)
+++ announcement/trunk/src/main/java/jp/sf/pal/announcement/db/allcommon/dbmeta/DBMetaInstanceHandler.java	2008-06-30 02:54:27 UTC (rev 1002)
@@ -0,0 +1,160 @@
+package jp.sf.pal.announcement.db.allcommon.dbmeta;
+
+import java.util.Collections;
+import java.util.LinkedHashMap;
+import java.util.Map;
+
+import jp.sf.pal.announcement.db.allcommon.util.SimpleAssertUtil;
+
+/**
+ * DBMeta instance handler.
+ * 
+ * @author DBFlute(AutoGenerator)
+ */
+ @ SuppressWarnings("unchecked")
+public class DBMetaInstanceHandler {
+
+    // ===================================================================================
+    //                                                                          Definition
+    //                                                                          ==========
+    /** The key-to-lower map of DB-name and property-name for table. */
+    protected static final Map<String, String> _tableDbNamePropertyNameKeyToLowerMap;
+    static {
+        Map<String, String> tmpMap = new LinkedHashMap<String, String>();
+
+        tmpMap.put("ANNOUNCEMENT".toLowerCase(), "announcement");
+        tmpMap.put("ANNOUNCEMENT_BODY".toLowerCase(), "announcementBody");
+
+        _tableDbNamePropertyNameKeyToLowerMap = Collections
+                .unmodifiableMap(tmpMap);
+    }
+
+    /** The key-to-lower map of property-name and DB-name for table. */
+    protected static final Map<String, String> _tablePropertyNameDbNameKeyToLowerMap;
+    static {
+        Map<String, String> tmpMap = new LinkedHashMap<String, String>();
+
+        tmpMap.put("announcement".toLowerCase(), "ANNOUNCEMENT");
+        tmpMap.put("announcementBody".toLowerCase(), "ANNOUNCEMENT_BODY");
+
+        _tablePropertyNameDbNameKeyToLowerMap = Collections
+                .unmodifiableMap(tmpMap);
+    }
+
+    /** Table db-name instance map. */
+    protected static final Map<String, DBMeta> _tableDbNameInstanceMap;
+    static {
+        Map<String, DBMeta> tmpMap = new LinkedHashMap<String, DBMeta>();
+
+        tmpMap
+                .put(
+                        "ANNOUNCEMENT",
+                        getDBMeta("jp.sf.pal.announcement.db.bsentity.dbmeta.AnnouncementDbm"));
+        tmpMap
+                .put(
+                        "ANNOUNCEMENT_BODY",
+                        getDBMeta("jp.sf.pal.announcement.db.bsentity.dbmeta.AnnouncementBodyDbm"));
+
+        _tableDbNameInstanceMap = Collections.unmodifiableMap(tmpMap);
+    }
+
+    protected static DBMeta getDBMeta(String className) {
+        try {
+            Class clazz = Class.forName(className);
+            java.lang.reflect.Method methoz = clazz.getMethod("getInstance",
+                    (Class[]) null);
+            Object result = methoz.invoke(null, (Object[]) null);
+            return (DBMeta) result;
+        } catch (Exception e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    /**
+     * @return The map that contains instances of dbmeta. (NotNull & NotEmpty)
+     */
+    public static Map<String, DBMeta> getDBMetaMap() {
+        return _tableDbNameInstanceMap;
+    }
+
+    // ===================================================================================
+    //                                                                         Main Method
+    //                                                                         ===========
+    /**
+     * Find dbmeta by table flexible-name.
+     * <pre>
+     * If the table name is 'ORDER_DETAIL', you can find the dbmeta by ...(as follows)
+     *     'ORDER_DETAIL', 'ORDer_DeTAiL', 'order_detail'
+     *     , 'OrderDetail', 'orderdetail', 'oRderDetaIl'
+     * </pre>
+     * @param tableFlexibleName Table flexible-name. (NotNull)
+     * @return Instance. (NotNull)
+     */
+    public static DBMeta findDBMeta(String tableFlexibleName) {
+        assertStringNotNullAndNotTrimmedEmpty("tableFlexibleName",
+                tableFlexibleName);
+        if (_tableDbNameInstanceMa