diff --git a/.gitignore b/.gitignore index 354dd0d77..c5cfabe0c 100644 --- a/.gitignore +++ b/.gitignore @@ -6,6 +6,7 @@ /src/main/webapp/WEB-INF/classes/ /src/main/webapp/WEB-INF/lib/ /src/main/webapp/jar/ +/dbflute_fess/log/*.log /dbflute_h2/log/*.log /dbflute_mysql/log/*.log /dbflute_oracle/log/*.log diff --git a/README.md b/README.md index 5412a24f3..84f13d0e9 100644 --- a/README.md +++ b/README.md @@ -12,24 +12,29 @@ Fess is Solr based search server, but knowledge/experience about Solr is NOT nee - [English](http://fess.codelibs.org/) - [Japanese](http://fess.codelibs.org/ja/) -### Issues/Questions +## Issues/Questions Please file an [issue](https://github.com/codelibs/fess/issues "issue"). (Japanese forum is [here](https://github.com/codelibs/codelibs-ja-forum "here").) -### Development +## Development + +### Get Source Code First of all, clone Fess's repositories: $ cd ~/workspace $ git clone https://github.com/codelibs/fess.git - $ git clone https://github.com/codelibs/fess-db.git - $ git clone https://github.com/codelibs/fess-suggest.git - $ git clone https://github.com/codelibs/fess-solr-plugin.git -and then imports them as Maven project. -If you want to re-create H2 database for Fess, runs: +and then imports it as Maven project on eclipse or ohter IDE. + +### Download Elasticsearch Plugins + +Run antrun:run to download plugins into plugins directory: + + $ mvn antrun:run + +### Run Fess + +Run or debug org.codelibs.fess.FessBoot on IDE, and then access http://localhost:8080/fess/ - $ cd fess-db/fess-db-h2 - $ mvn dbflute:download - $ mvn dbflute:replace-schema diff --git a/dbflute_fess/_project.bat b/dbflute_fess/_project.bat index cc8b987f1..c833fdcb9 100644 --- a/dbflute_fess/_project.bat +++ b/dbflute_fess/_project.bat @@ -2,7 +2,7 @@ set ANT_OPTS=-Xmx512m -set DBFLUTE_HOME=..\mydbflute\dbflute-1.1.0-sp1 +set DBFLUTE_HOME=..\mydbflute\dbflute-1.1.0-sp8 set MY_PROPERTIES_PATH=build.properties diff --git a/dbflute_fess/_project.sh b/dbflute_fess/_project.sh index 4ec99c2c4..0af133262 100644 --- a/dbflute_fess/_project.sh +++ b/dbflute_fess/_project.sh @@ -2,6 +2,6 @@ export ANT_OPTS=-Xmx512m -export DBFLUTE_HOME=../mydbflute/dbflute-1.1.0-sp1 +export DBFLUTE_HOME=../mydbflute/dbflute-1.1.0-sp8 export MY_PROPERTIES_PATH=build.properties diff --git a/dbflute_fess/dfprop/_readme.txt b/dbflute_fess/dfprop/_readme.txt index e839c244e..79c78a957 100644 --- a/dbflute_fess/dfprop/_readme.txt +++ b/dbflute_fess/dfprop/_readme.txt @@ -3,33 +3,34 @@ Directory for DBFlute properties Required (Basic) Properties: o basicInfoMap.dfprop o databaseInfoMap.dfprop -At first, you should set these properties -before executions of DBFlute tasks. Properties for additional informations: o additionalForeignKeyMap.dfprop o additionalPrimaryKeyMap.dfprop -o additionalUniqueKeyMap.dfprop -o additionalTableMap.dfprop +o additionalUniqueKeyMap.dfprop (manual making) +o additionalTableMap.dfprop (manual making) Properties for implementation environments: -o commonColumnMap.dfprop o classificationDefinitionMap.dfprop o classificationDeploymentMap.dfprop -o optimisticLockDefinitionMap.dfprop -o outsideSqlDefinitionMap.dfprop -o sequenceDefinitionMap.dfprop +o commonColumnMap.dfprop +o conditionBeanMap.dfprop o dependencyInjectionMap.dfprop o littleAdjustmentMap.dfprop -o includeQueryMap.dfprop -o typeMappingMap.dfprop +o outsideSqlMap.dfprop +o sequenceMap.dfprop Properties for ReplaceSchema: -o replaceSchemaDefinitionMap.dfprop +o replaceSchemaMap.dfprop Properties for documents: -o documentDefinitionMap.dfprop +o documentMap.dfprop Properties for non-functional adjustments: -o allClassCopyright.dfprop -o refreshDefinitionMap.dfprop +o sourceCopyright.dfprop +o infraMap.dfprop (manual making) + +Properties for plug-ins: +o freeGenMap.dfprop (manual making) +o lastafluteMap.dfprop (manual making) +o simpleDtoMap.dfprop (manual making) diff --git a/dbflute_fess/dfprop/additionalTableMap.dfprop b/dbflute_fess/dfprop/additionalTableMap.dfprop deleted file mode 100644 index 6a670a1c9..000000000 --- a/dbflute_fess/dfprop/additionalTableMap.dfprop +++ /dev/null @@ -1,42 +0,0 @@ -# /--------------------------------------------------------------------------- -# additionalTableMap: (NotRequired - Default map:{}) -# -# This property is valid at only JDBC task. -# You should use this when JDBC can not provide table information -# and when you have no table but call stored procedures only. -# -# The element 'columnMap' is only required in table elements. -# The element 'type' is only required in column elements. -# -# Specification: -# map: { -# [table-name] = map:{ -# columnMap = map:{ -# [column-name] = map:{ -# type = [column JDBC type] ; dbType = [column DB type] -# ; required = [true or false] ; size = [column size] -# ; primaryKey = [true or false] ; pkName = [PK constraint name] -# ; autoIncrement = [true or false] -# ; default = [default value] ; comment = [column comment] -# } -# } -# ; comment = [table comment] -# } -# } -# -# *The line that starts with '#' means comment-out. -# -map:{ - #; FOO_TABLE = map:{ - # ; columnMap = map:{ - # FOO_ID = map:{ type = INTEGER ; dbType = INTEGER - # ; required = true ; primaryKey = true ; autoIncrement = true - # } - # FOO_NAME = map:{ type = VARCHAR ; required = true ; size = 123 } - # FOO_DATE = map:{ type = DATE } - # } - #} -} -# ----------------/ -# -# *Refer to typeMappingMap.dfprop for JDBC type reference. diff --git a/dbflute_fess/dfprop/additionalUniqueKeyMap.dfprop b/dbflute_fess/dfprop/additionalUniqueKeyMap.dfprop deleted file mode 100644 index c3b2ea909..000000000 --- a/dbflute_fess/dfprop/additionalUniqueKeyMap.dfprop +++ /dev/null @@ -1,26 +0,0 @@ -# /--------------------------------------------------------------------------- -# additionalUniqueKeyMap: (NotRequired - Default map:{}) -# -# If unique key does not exist in your database, -# you can set up here as virtual unique key for DBFlute. -# And you can use it to view objects too. -# The names are treated as case insensitive. -# -# Example: -# map:{ -# ; UQ_MEMBER = map:{ -# ; tableName = MEMBER ; columnName = MEMBER_ACCOUNT -# } -# ; UQ_PRODUCT = map:{ -# ; tableName = PRODUCT ; columnName = PRODUCT_HANDLE_CODE -# } -# } -# -# *The line that starts with '#' means comment-out. -# -map:{ - #; UQ_MEMBER = map:{ - # ; tableName = MEMBER ; columnName = MEMBER_ACCOUNT - #} -} -# ----------------/ \ No newline at end of file diff --git a/dbflute_fess/dfprop/includeQueryMap.dfprop b/dbflute_fess/dfprop/conditionBeanMap.dfprop similarity index 56% rename from dbflute_fess/dfprop/includeQueryMap.dfprop rename to dbflute_fess/dfprop/conditionBeanMap.dfprop index 6ab84be3f..6c0d8147c 100644 --- a/dbflute_fess/dfprop/includeQueryMap.dfprop +++ b/dbflute_fess/dfprop/conditionBeanMap.dfprop @@ -42,24 +42,20 @@ map:{ # [Include] # String columns may not be needed # to be set these condition-keys basically. - #; GreaterThan = map:{} - #; LessThan = map:{} - #; GreaterEqual = map:{} - #; LessEqual = map:{} + ; GreaterThan = map:{} + ; LessThan = map:{} + ; GreaterEqual = map:{} + ; LessEqual = map:{} # [Exclude] # Common columns of String type may not be needed # to be set these condition-keys basically. - #; !NotEqual = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !GreaterThan = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !LessThan = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !GreaterEqual = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !LessEqual = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !InScope = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !NotInScope = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !PrefixSearch = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !LikeSearch = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !NotLikeSearch = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } + ; !NotEqual = map:{ $$ALL$$ = list:{ $$CommonColumn$$ ; type:LONGVARCHAR ; suffix:_NAME } } + ; !InScope = map:{ $$ALL$$ = list:{ $$CommonColumn$$ ; type:LONGVARCHAR ; suffix:_NAME } } + ; !NotInScope = map:{ $$ALL$$ = list:{ $$CommonColumn$$ ; type:LONGVARCHAR ; suffix:_NAME } } + ; !PrefixSearch = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } + ; !LikeSearch = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } + ; !NotLikeSearch = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } } ; Number = map:{ # [Include] @@ -68,14 +64,15 @@ map:{ # [Exclude] # VersionNo column may not be needed # to be set these condition-keys basically. - #; !NotEqual = map:{ $$ALL$$ = list:{ $$VersionNo$$ } } - #; !GreaterThan = map:{ $$ALL$$ = list:{ $$VersionNo$$ } } - #; !LessThan = map:{ $$ALL$$ = list:{ $$VersionNo$$ } } - #; !GreaterEqual = map:{ $$ALL$$ = list:{ $$VersionNo$$ } } - #; !LessEqual = map:{ $$ALL$$ = list:{ $$VersionNo$$ } } + ; !NotEqual = map:{ $$ALL$$ = list:{ $$VersionNo$$ ; DISPLAY_ORDER } } + ; !GreaterThan = map:{ $$ALL$$ = list:{ $$VersionNo$$ ; DISPLAY_ORDER } } + ; !LessThan = map:{ $$ALL$$ = list:{ $$VersionNo$$ ; DISPLAY_ORDER } } + ; !GreaterEqual = map:{ $$ALL$$ = list:{ $$VersionNo$$ ; DISPLAY_ORDER } } + ; !LessEqual = map:{ $$ALL$$ = list:{ $$VersionNo$$ ; DISPLAY_ORDER } } + # RangeOf only valid just in case #; !RangeOf = map:{ $$ALL$$ = list:{ $$VersionNo$$ } } - #; !InScope = map:{ $$ALL$$ = list:{ $$VersionNo$$ } } - #; !NotInScope = map:{ $$ALL$$ = list:{ $$VersionNo$$ } } + ; !InScope = map:{ $$ALL$$ = list:{ $$VersionNo$$ ; DISPLAY_ORDER } } + ; !NotInScope = map:{ $$ALL$$ = list:{ $$VersionNo$$ ; DISPLAY_ORDER } } } ; Date = map:{ # [Include] @@ -88,12 +85,17 @@ map:{ # [Exclude] # Common columns of Date type may not be needed # to be set these condition-keys basically. - #; !GreaterThan = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !LessThan = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !GreaterEqual = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !LessEqual = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !FromTo = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } - #; !DateFromTo = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } + ; !GreaterThan = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } + ; !LessThan = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } + ; !GreaterEqual = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } + ; !LessEqual = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } + # RangeOf only valid just in case + #; !FromTo = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } + ; !DateFromTo = map:{ $$ALL$$ = list:{ $$CommonColumn$$ } } + } + ; OrderBy = map:{ + ; !Asc = map:{ $$ALL$$ = list:{ type:LONGVARCHAR } } + ; !Desc = map:{ $$ALL$$ = list:{ type:LONGVARCHAR } } } } # ----------------/ \ No newline at end of file diff --git a/dbflute_fess/dfprop/databaseInfoMap.dfprop b/dbflute_fess/dfprop/databaseInfoMap.dfprop index 019715705..dcfcda233 100644 --- a/dbflute_fess/dfprop/databaseInfoMap.dfprop +++ b/dbflute_fess/dfprop/databaseInfoMap.dfprop @@ -16,7 +16,7 @@ # map:{ ; driver = org.h2.Driver - ; url = jdbc:h2:file:../src/main/resources/fess + ; url = jdbc:h2:file:../src/test/resources/dummydb/dummydb ; schema = ; user = sa ; password = diff --git a/dbflute_fess/dfprop/documentDefinitionMap.dfprop b/dbflute_fess/dfprop/documentMap.dfprop similarity index 100% rename from dbflute_fess/dfprop/documentDefinitionMap.dfprop rename to dbflute_fess/dfprop/documentMap.dfprop diff --git a/dbflute_fess/dfprop/freeGenDefinitionMap.dfprop b/dbflute_fess/dfprop/freeGenMap.dfprop similarity index 57% rename from dbflute_fess/dfprop/freeGenDefinitionMap.dfprop rename to dbflute_fess/dfprop/freeGenMap.dfprop index 024b878fc..2c9970ead 100644 --- a/dbflute_fess/dfprop/freeGenDefinitionMap.dfprop +++ b/dbflute_fess/dfprop/freeGenMap.dfprop @@ -1,4 +1,30 @@ map:{ + ; ElasticsearchFessUserGen = map:{ + ; resourceMap = map:{ + ; resourceType = ELASTICSEARCH + ; resourceFile = ../src/main/config/es/fess_user.json + } + ; outputMap = map:{ + ; templateFile = unused + ; outputDirectory = ../src/main/java + ; package = org.codelibs.fess.es + ; className = unused + } + ; tableMap = map:{ + ; tablePath = .fess_user -> mappings -> map + ; mappingMap = map:{ + ; type = map:{ + ; string = String + ; integer = Integer + ; long = Long + ; float = Float + ; double = Double + ; boolean = Boolean + ; date = LocalDateTime + } + } + } + } ; ElasticsearchFessConfigGen = map:{ ; resourceMap = map:{ ; resourceType = ELASTICSEARCH @@ -20,15 +46,15 @@ map:{ ; float = Float ; double = Double ; boolean = Boolean - ; date = java.time.LocalDateTime + ; date = LocalDateTime } } } } - ; ElasticsearchSearchLogGen = map:{ + ; ElasticsearchFessLogGen = map:{ ; resourceMap = map:{ ; resourceType = ELASTICSEARCH - ; resourceFile = ../src/main/config/es/search_log.json + ; resourceFile = ../src/main/config/es/fess_log.json } ; outputMap = map:{ ; templateFile = unused @@ -37,7 +63,7 @@ map:{ ; className = unused } ; tableMap = map:{ - ; tablePath = search_log -> mappings -> map + ; tablePath = fess_log -> mappings -> map ; mappingMap = map:{ ; type = map:{ ; string = String @@ -46,7 +72,7 @@ map:{ ; float = Float ; double = Double ; boolean = Boolean - ; date = java.time.LocalDateTime + ; date = LocalDateTime } } } diff --git a/dbflute_fess/dfprop/lastafluteMap.dfprop b/dbflute_fess/dfprop/lastafluteMap.dfprop new file mode 100644 index 000000000..6db7b17c8 --- /dev/null +++ b/dbflute_fess/dfprop/lastafluteMap.dfprop @@ -0,0 +1,53 @@ +# /--------------------------------------------------------------------------- +# lastafluteMap: (NotRequired - Default map:{}) +# +# Specification: +# map:{ +# ; serviceName = [your service name] +# ; domainPackage = [package] +# ; environmentList = list:{ [environment name] } +# ; isMakeActionHtml = [true or false] +# ; commonMap = map:{ +# ; path = [relative path to common project from DBFlute client] +# ; freeGenList = list:{ [env or config or label or message or html] } +# ; propertiesHtmlList = list:{ [env or config or label or message] } +# } +# ; appMap = map:{ +# ; [application name, camel case, initial uncapitalised] = map:{ +# ; path = [relative path to application project from DBFlute client] +# ; freeGenList = list:{ [env or config or label or message or html] } +# ; propertiesHtmlList = list:{ [env or config or label or message] } +# } +# } +# } +# +# *The line that starts with '#' means comment-out. +# +map:{ + # your service name, camel case, initial uncapitalised + ; serviceName = fess + + # package for your domain name, e.g. com.example + ; domainPackage = org.codelibs.fess + + # keywords for environment properties, same as directory name + ; environmentList = list:{} + + # environment dispatch by lasta.env of system property? + ; isUseLastaEnv = false + + # settings for web applications + ; appMap = map:{ + ; fess = map:{ + ; path = .. + ; freeGenList = list:{ env ; config ; label ; message ; mail ; template ; jsp ; doc } + ; propertiesHtmlList = list:{ env ; config ; label ; message } + } + } + + # you can override (several) default settings like this: + #; overrideMap = map:{ + # ; fess.freeGen.mail.targetDir = ./playsql/data/mail + #} +} +# ----------------/ diff --git a/dbflute_fess/dfprop/littleAdjustmentMap.dfprop b/dbflute_fess/dfprop/littleAdjustmentMap.dfprop index f1d37f295..5c9645fb4 100644 --- a/dbflute_fess/dfprop/littleAdjustmentMap.dfprop +++ b/dbflute_fess/dfprop/littleAdjustmentMap.dfprop @@ -7,24 +7,20 @@ # o isAvailableAddingCatalogToTableSqlName: (NotRequired - Default false) # o isAvailableDatabaseDependency: (NotRequired - Default false) # o isAvailableDatabaseNativeJDBC: (NotRequired - Default false) -# o isAvailableNonPrimaryKeyWritable: (NotRequired - Default false) # o classificationUndefinedHandlingType: (NotRequired - Default LOGGING) # o isEntityConvertEmptyStringToNull: (NotRequired - Default false) -# o isMakeConditionQueryEqualEmptyString: (NotRequired - Default false) # o isTableDispNameUpperCase: (NotRequired - Default false) # o isTableSqlNameUpperCase: (NotRequired - Default false) # o isColumnSqlNameUpperCase: (NotRequired - Default false) -# o isMakeDeprecated: (NotRequired - Default false) -# o isMakeRecentlyDeprecated: (NotRequired - Default true) # o extendedDBFluteInitializerClass: (NotRequired - Default null) -# o extendedImplementedInvokerAssistantClass: (NotRequired - Default null) -# o extendedImplementedCommonColumnAutoSetupperClass: (NotRequired - Default null) # o shortCharHandlingMode: (NotRequired - Default NONE) # o quoteTableNameList: (NotRequired - Default list:{}) # o quoteColumnNameList: (NotRequired - Default list:{}) # o columnNullObjectMap: (NotRequired - Default map:{}) # o relationalNullObjectMap: (NotRequired - Default map:{}) # o cursorSelectFetchSize: (NotRequired - Default null) +# o refreshMap: (NotRequired - Default map:{}) +# o optimisticLockMap: (NotRequired - Default map:{}) # # *The line that starts with '#' means comment-out. # @@ -34,9 +30,6 @@ map:{ # [true] # Add schema to table SQL name. (The table name on query is SCHEMA.TABLE) # - # [false] - # Non. - # #; isAvailableAddingSchemaToTableSqlName = false # - - - - - - - - - -/ @@ -44,10 +37,6 @@ map:{ # o isAvailableAddingCatalogToTableSqlName: (NotRequired - Default false) # [true] # Add catalog to table SQL name. (The table name on query is CATALOG.SCHEMA.TABLE) - # This property works only when isAvailableAddingSchemaToTableSqlName is true. - # - # [false] - # Non. # #; isAvailableAddingCatalogToTableSqlName = false # - - - - - - - - - -/ @@ -55,11 +44,7 @@ map:{ # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o isAvailableDatabaseDependency: (NotRequired - Default false) # [true] - # Generate the method that depends on the database. - # For example: cb.lockWithRR() at DB2. - # - # [false] - # Non. + # Generate the method that depends on the database. e.g. cb.lockWithRR() at DB2. # #; isAvailableDatabaseDependency = false # - - - - - - - - - -/ @@ -67,27 +52,12 @@ map:{ # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o isAvailableDatabaseNativeJDBC: (NotRequired - Default false) # [true] - # Use classes of database native JDBC on generated classes - # to get best performances of DB access. + # Use classes of database native JDBC on generated classes to get best performances of DB access. # Your project needs to refer to database native JDBC. # - # [false] - # Non. - # #; isAvailableDatabaseNativeJDBC = false # - - - - - - - - - -/ - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o isAvailableNonPrimaryKeyWritable: (NotRequired - Default false) - # [true] - # Generate writable methods at non-primary-key table. - # - # [false] - # Non. - # - #; isAvailableNonPrimaryKeyWritable = false - # - - - - - - - - - -/ - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o classificationUndefinedHandlingType: (NotRequired - Default LOGGING) # The handling type when undefined classification is found. @@ -104,32 +74,13 @@ map:{ # [true] # Convert empty-string data to null in entity. # - # [false] - # Non. - # #; isEntityConvertEmptyStringToNull = false # - - - - - - - - - -/ - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o isMakeConditionQueryEqualEmptyString: (NotRequired - Default false) - # [true] - # Make equal-empty-string methods of condition-query. - # For example: cb.query().setMemberName_Equal_EmptyString() - # - # [false] - # Non. - # - #; isMakeConditionQueryEqualEmptyString = false - # - - - - - - - - - -/ - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o isTableDispNameUpperCase: (NotRequired - Default false) # [true] - # Table names for display, e.g. on documents, - # are forcedly treated as upper case. - # - # [false] - # Non. + # Table names for display, e.g. on documents, are forcedly treated as upper case. # #; isTableDispNameUpperCase = false # - - - - - - - - - -/ @@ -140,9 +91,6 @@ map:{ # Table names on SQL executed by condition-bean or behavior # are forcedly treated as upper case. (except outside-SQL) # - # [false] - # Non. - # #; isTableSqlNameUpperCase = false # - - - - - - - - - -/ @@ -152,36 +100,9 @@ map:{ # Column names on SQL executed by condition-bean or behavior # are forcedly treated as upper case. (except outside-SQL) # - # [false] - # Non. - # #; isColumnSqlNameUpperCase = false # - - - - - - - - - -/ - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o isMakeDeprecated: (NotRequired - Default false) - # [true] - # Make deprecated method and class and so on... - # *You should specify this property 'false'! - # - # [false] - # Non. - # - #; isMakeDeprecated = false - # - - - - - - - - - -/ - - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o isMakeRecentlyDeprecated: (NotRequired - Default true) - # [true] - # Make RECENTLY deprecated method and class and so on... - # *You should specify this property 'false'! - # - # [false] - # Non. - # - #; isMakeRecentlyDeprecated = true - # - - - - - - - - - -/ - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o extendedDBFluteInitializerClass: (NotRequired - Default null) # If you want to extend the embedded DBFlute initializer, @@ -192,26 +113,6 @@ map:{ #; extendedDBFluteInitializerClass = com.example.ExtendedDBFluteInitializer # - - - - - - - - - -/ - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o extendedImplementedInvokerAssistantClass: (NotRequired - Default null) - # If you want to extend the embedded invoker assistant, - # specify the class name of your original invoker assistant - # that extends the embedded one. - # *Basically you SHOULD NOT specify this property! - # - #; extendedImplementedInvokerAssistantClass = com.example.ExtendedImplementedInvokerAssistant - # - - - - - - - - - -/ - - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o extendedImplementedCommonColumnAutoSetupperClass: (NotRequired - Default null) - # If you want to extend the embedded common column auto setupper, - # specify the class name of your original common column auto setupper - # that extends the embedded one. - # *Basically you SHOULD NOT specify this property! - # - #; extendedImplementedCommonColumnAutoSetupperClass = com.example.ExtendedImplementedCommonColumnAutoSetupper - # - - - - - - - - - -/ - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o shortCharHandlingMode: (NotRequired - Default NONE) # If the parameter of condition-bean or parameter-bean has short size, @@ -225,16 +126,14 @@ map:{ # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o quoteTableNameList: (NotRequired - Default list:{}) - # The list of table DB names that need to be quoted. - # Specified tables is quoted on auto-generated SQL. + # The list of table DB names that need to be quoted. Specified tables is quoted on auto-generated SQL. # #; quoteTableNameList = list:{} # - - - - - - - - - -/ # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o quoteColumnNameList: (NotRequired - Default list:{}) - # The list of column DB names that need to be quoted. - # Specified columns is quoted on auto-generated SQL. + # The list of column DB names that need to be quoted. Specified columns is quoted on auto-generated SQL. # #; quoteColumnNameList = list:{} # - - - - - - - - - -/ @@ -278,5 +177,32 @@ map:{ # #; cursorSelectFetchSize = Integer.MIN_VALUE # - - - - - - - - - -/ + + # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + # o refreshMap: (NotRequired - Default map:{projectName=$$AutoDetect$$ ; requestUrl=http://localhost:8386/}) + # If you use synchronizer and specify this property, no need to refresh(F5) your eclipse project. + # The projectName can be set plural names by slash '/'. e.g. sea/land + # + #; refreshMap = map:{ + # ; projectName = $$AutoDetect$$ + # ; requestUrl = http://localhost:8386/ + #} + # - - - - - - - - - -/ + + # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + # o optimisticLockMap: (NotRequired - Default map:{}) + # The definition for optimistic lock of DBFlute. + # + #; optimisticLockMap = map:{ + # # o updateDateFieldName: (NotRequired - Default '') + # ; updateDateFieldName = UPDATE_DATE + # + # # o versionNoFieldName: (NotRequired - Default 'VERSION_NO') + # # The column name of version no for optimistic lock. + # # Basically you don't need this if your tables have the column 'VERSION_NO'. + # # because the default value is 'VERSION_NO'. + # ; versionNoFieldName = VERSION_NO + #} + # - - - - - - - - - -/ } # ----------------/ \ No newline at end of file diff --git a/dbflute_fess/dfprop/optimisticLockDefinitionMap.dfprop b/dbflute_fess/dfprop/optimisticLockDefinitionMap.dfprop deleted file mode 100644 index 840fe0641..000000000 --- a/dbflute_fess/dfprop/optimisticLockDefinitionMap.dfprop +++ /dev/null @@ -1,28 +0,0 @@ -# /--------------------------------------------------------------------------- -# optimisticLockDefinitionMap: (NotRequired - Default map:{}) -# -# The definition for optimistic lock of DBFlute. -# -# o updateDateFieldName: (NotRequired - Default '') -# o versionNoFieldName: (NotRequired - Default 'VERSION_NO') -# -# *The line that starts with '#' means comment-out. -# -map:{ - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o updateDateFieldName: (NotRequired - Default '') - # The column name of update date for optimistic lock. - # - #; updateDateFieldName = UPDATE_DATE - # - - - - - - - - - -/ - - # /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # o versionNoFieldName: (NotRequired - Default 'VERSION_NO') - # The column name of version no for optimistic lock. - # Basically you don't need this if your tables have the column 'VERSION_NO'. - # because the default value is 'VERSION_NO'. - # - #; versionNoFieldName = VERSION_NO - # - - - - - - - - - -/ -} -# ----------------/ \ No newline at end of file diff --git a/dbflute_fess/dfprop/outsideSqlDefinitionMap.dfprop b/dbflute_fess/dfprop/outsideSqlMap.dfprop similarity index 97% rename from dbflute_fess/dfprop/outsideSqlDefinitionMap.dfprop rename to dbflute_fess/dfprop/outsideSqlMap.dfprop index e9413a6b5..e18bc0ee7 100644 --- a/dbflute_fess/dfprop/outsideSqlDefinitionMap.dfprop +++ b/dbflute_fess/dfprop/outsideSqlMap.dfprop @@ -1,5 +1,5 @@ # /--------------------------------------------------------------------------- -# outsideSqlDefinitionMap: (NotRequired - Default map:{}) +# outsideSqlMap: (NotRequired - Default map:{}) # # The various settings about outsideSql. # @@ -27,9 +27,6 @@ map:{ # The parameter beans for procedure are auto-generated. # If you call the procedure from DBFlute, you should specify 'true'! # - # [false] - # Non. - # ; isGenerateProcedureParameterBean = false # - - - - - - - - - -/ @@ -43,9 +40,6 @@ map:{ # (because of getting from execution meta data (result set meta data)) # This property is valid only when isGenerateProcedureParameterBean is true. # - # [false] - # Non. - # ; isGenerateProcedureCustomizeEntity = false # - - - - - - - - - -/ @@ -104,9 +98,6 @@ map:{ # You should always write the title of outsideSql. # If it doesn't exist, the OutsideSqlTest task fails. # - # [false] - # Non. - # #; isRequiredSqlTitle = true # - - - - - - - - - -/ @@ -116,9 +107,6 @@ map:{ # You should always write the description of outsideSql. # If it doesn't exist, the OutsideSqlTest task fails. # - # [false] - # Non. - # #; isRequiredSqlDescription = true # - - - - - - - - - -/ diff --git a/dbflute_fess/dfprop/refreshDefinitionMap.dfprop b/dbflute_fess/dfprop/refreshDefinitionMap.dfprop deleted file mode 100644 index ddfa4dec7..000000000 --- a/dbflute_fess/dfprop/refreshDefinitionMap.dfprop +++ /dev/null @@ -1,19 +0,0 @@ -# /--------------------------------------------------------------------------- -# refreshDefinitionMap: (NotRequired - Default map:{}) -# -# If you use synchronizer and specify this property, -# You don't need to refresh(F5) your eclipse project. -# -# Specification: -# map:{ -# ; projectName = [Eclipse Project1] / [Eclipse Project2] / ... -# ; requestUrl = [synchronizer's URL] -# } -# -# *The line that starts with '#' means comment-out. -# -map:{ - ; projectName = $$AutoDetect$$ - ; requestUrl = http://localhost:8386/ -} -# ----------------/ \ No newline at end of file diff --git a/dbflute_fess/dfprop/replaceSchemaDefinitionMap.dfprop b/dbflute_fess/dfprop/replaceSchemaDefinitionMap.dfprop index 11b8705b8..809260fdc 100644 --- a/dbflute_fess/dfprop/replaceSchemaDefinitionMap.dfprop +++ b/dbflute_fess/dfprop/replaceSchemaDefinitionMap.dfprop @@ -1,5 +1,5 @@ # /--------------------------------------------------------------------------- -# replaceSchemaDefinitionMap: (NotRequired - Default map:{}) +# replaceSchemaMap: (NotRequired - Default map:{}) # # The various settings about replace-schema. # diff --git a/dbflute_fess/dfprop/sequenceDefinitionMap.dfprop b/dbflute_fess/dfprop/sequenceDefinitionMap.dfprop index f04451cae..c8144ced5 100644 --- a/dbflute_fess/dfprop/sequenceDefinitionMap.dfprop +++ b/dbflute_fess/dfprop/sequenceDefinitionMap.dfprop @@ -1,11 +1,10 @@ # /--------------------------------------------------------------------------- -# sequenceDefinitionMap: (NotRequired - Default map:{}) -# +# sequenceMap: (NotRequired - Default map:{}) +# # The relation mappings between sequence and table. -# If you don't specify the mappings, you cannot insert -# a record of the table by sequence. +# If you don't specify the mappings, you cannot insert a record of the table by sequence. # The table names are treated as case insensitive. -# +# # Example: # map:{ # ; PURCHASE = SEQ_PURCHASE diff --git a/dbflute_fess/freegen/elasticsearch/AbstractBehavior.vm b/dbflute_fess/freegen/elasticsearch/AbstractBehavior.vm index 6f9d6fd14..8bf7e2f15 100644 --- a/dbflute_fess/freegen/elasticsearch/AbstractBehavior.vm +++ b/dbflute_fess/freegen/elasticsearch/AbstractBehavior.vm @@ -25,6 +25,7 @@ import org.dbflute.cbean.ConditionBean; import org.dbflute.cbean.coption.CursorSelectOption; import org.dbflute.cbean.result.ListResultBean; import org.dbflute.exception.IllegalBehaviorStateException; +import org.dbflute.util.DfTypeUtil; import org.elasticsearch.action.bulk.BulkItemResponse; import org.elasticsearch.action.bulk.BulkRequestBuilder; import org.elasticsearch.action.bulk.BulkResponse; @@ -76,10 +77,17 @@ public abstract class AbstractBehavior List delegateSelectList(final ConditionBean cb, final Class entityType) { // TODO check response final SearchRequestBuilder builder = client.prepareSearch(asEsIndex()).setTypes(asEsSearchType()); + final int from; + final int size; if (cb.isFetchScopeEffective()) { - builder.setFrom(cb.getFetchStartIndex()); - builder.setSize(cb.getFetchSize()); + from = cb.getFetchStartIndex(); + size = cb.getFetchSize(); + } else { + from = 0; + size = 10; } + builder.setFrom(from); + builder.setSize(size); ((AbstractConditionBean) cb).request().build(builder); final SearchResponse response = ((AbstractConditionBean) cb).build(builder).execute().actionGet(); @@ -94,8 +102,8 @@ public abstract class AbstractBehavior createPlainUpdateOption() { + UpdateOption updateOption = new UpdateOption(); + updateOption.xtoBeCompatibleBatchUpdateDefaultEveryColumn(); + return updateOption; } - protected static Short toShort(final Object value) { - if (value instanceof Number) { - return ((Number) value).shortValue(); - } else if (value instanceof String) { - return Short.parseShort(value.toString()); - } else { - return null; - } - } - - protected static Integer toInteger(final Object value) { - if (value instanceof Number) { - return ((Number) value).intValue(); - } else if (value instanceof String) { - return Integer.parseInt(value.toString()); - } else { - return null; - } - } - - protected static Long toLong(final Object value) { - if (value instanceof Number) { - return ((Number) value).longValue(); - } else if (value instanceof String) { - return Long.parseLong(value.toString()); - } else { - return null; - } - } - - protected static Float toFloat(final Object value) { - if (value instanceof Number) { - return ((Number) value).floatValue(); - } else if (value instanceof String) { - return Float.parseFloat(value.toString()); - } else { - return null; - } - } - - protected static Double toDouble(final Object value) { - if (value instanceof Number) { - return ((Number) value).doubleValue(); - } else if (value instanceof String) { - return Double.parseDouble(value.toString()); - } else { - return null; - } - } - - protected static Boolean toBoolean(final Object value) { - if (value instanceof Boolean) { - return ((Boolean) value).booleanValue(); - } else if (value instanceof String) { - return Boolean.parseBoolean(value.toString()); - } else { + public static String[] toStringArray(final Object value) { + if (value instanceof String[]) { + return (String[]) value; + } else if (value instanceof List) { + return ((List) value).stream().map(v -> v.toString()).toArray(n -> new String[n]); + } + String str = DfTypeUtil.toString(value); + if (str == null) { return null; } + return new String[] { str }; } public static class BulkList implements List { diff --git a/dbflute_fess/freegen/elasticsearch/AbstractConditionBean.vm b/dbflute_fess/freegen/elasticsearch/AbstractConditionBean.vm index 90b3e62ef..d3ded9713 100644 --- a/dbflute_fess/freegen/elasticsearch/AbstractConditionBean.vm +++ b/dbflute_fess/freegen/elasticsearch/AbstractConditionBean.vm @@ -572,6 +572,28 @@ public abstract class AbstractConditionBean implements ConditionBean { // do nothing } + @Override + public boolean hasSpecifiedLocalColumn() { + // TODO Auto-generated method stub + return false; + } + + @Override + public void enableUndefinedClassificationSelect() { + // TODO Auto-generated method stub + } + + @Override + public void disableUndefinedClassificationSelect() { + // TODO Auto-generated method stub + } + + @Override + public boolean isUndefinedClassificationSelectAllowed() { + // TODO Auto-generated method stub + return false; + } + public SearchRequestParams request() { return _searchRequestParams; } diff --git a/dbflute_fess/freegen/elasticsearch/AbstractConditionQuery.vm b/dbflute_fess/freegen/elasticsearch/AbstractConditionQuery.vm index 857218e2a..b3b7396f7 100644 --- a/dbflute_fess/freegen/elasticsearch/AbstractConditionQuery.vm +++ b/dbflute_fess/freegen/elasticsearch/AbstractConditionQuery.vm @@ -164,12 +164,14 @@ public abstract class AbstractConditionQuery implements ConditionQuery { } protected RangeQueryBuilder regRangeQ(String name, ConditionKey ck, Object value) { - for (QueryBuilder builder : queryBuilderList) { - if (builder instanceof RangeQueryBuilder) { - RangeQueryBuilder rangeQueryBuilder = (RangeQueryBuilder) builder; - if (rangeQueryBuilder.toString().replaceAll("\\s", "").startsWith("{\"range\":{\"" + name + "\"")) { - addRangeC(rangeQueryBuilder, ck, value); - return rangeQueryBuilder; + if (queryBuilderList != null) { + for (QueryBuilder builder : queryBuilderList) { + if (builder instanceof RangeQueryBuilder) { + RangeQueryBuilder rangeQueryBuilder = (RangeQueryBuilder) builder; + if (rangeQueryBuilder.toString().replaceAll("\\s", "").startsWith("{\"range\":{\"" + name + "\"")) { + addRangeC(rangeQueryBuilder, ck, value); + return rangeQueryBuilder; + } } } } diff --git a/dbflute_fess/freegen/elasticsearch/AbstractEntity.vm b/dbflute_fess/freegen/elasticsearch/AbstractEntity.vm index 4bae5c20a..31710cd34 100644 --- a/dbflute_fess/freegen/elasticsearch/AbstractEntity.vm +++ b/dbflute_fess/freegen/elasticsearch/AbstractEntity.vm @@ -163,9 +163,22 @@ public abstract class AbstractEntity implements Entity, Serializable, Cloneable return null; } + @Override + public void myunlockUndefinedClassificationAccess() { + // TODO Auto-generated method stub + } + + @Override + public boolean myundefinedClassificationAccessAllowed() { + // TODO Auto-generated method stub + return false; + } + public abstract Map toSource(); - public class DocMeta { + public class DocMeta implements Serializable { + + private static final long serialVersionUID = 1L; protected String id; diff --git a/dbflute_fess/freegen/elasticsearch/BsBehavior.vm b/dbflute_fess/freegen/elasticsearch/BsBehavior.vm index c5068fbd6..89363a8f0 100644 --- a/dbflute_fess/freegen/elasticsearch/BsBehavior.vm +++ b/dbflute_fess/freegen/elasticsearch/BsBehavior.vm @@ -16,6 +16,7 @@ import org.dbflute.cbean.result.ListResultBean; import org.dbflute.cbean.result.PagingResultBean; import org.dbflute.exception.IllegalBehaviorStateException; import org.dbflute.optional.OptionalEntity; +import org.dbflute.util.DfTypeUtil; import org.elasticsearch.action.bulk.BulkRequestBuilder; import org.elasticsearch.action.delete.DeleteRequestBuilder; import org.elasticsearch.action.index.IndexRequestBuilder; @@ -54,10 +55,15 @@ public abstract class Bs${table.camelizedName}Bhv extends AbstractBehavior<${tab protected RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); +#set ($tableMetaSettings = ${table.indexSettings.settings.index.dbflute.get($table.name)}) #foreach ($column in $table.columnList) #if ($column.isNormalColumn) #set ($javaNative = ${column.type}) - result.set${column.capCamelName}(to$javaNative(source.get("${column.name}"))); +#if ($tableMetaSettings.properties.get($column.name).array) + result.set${column.capCamelName}(to${javaNative}Array(source.get("${column.name}"))); +#else + result.set${column.capCamelName}(DfTypeUtil.to$javaNative(source.get("${column.name}"))); +#end #end #end return result; @@ -224,5 +230,10 @@ public abstract class Bs${table.camelizedName}Bhv extends AbstractBehavior<${tab } // TODO create, modify, remove + + @Override + protected boolean isCompatibleBatchInsertDefaultEveryColumn() { + return true; + } } diff --git a/dbflute_fess/freegen/elasticsearch/BsConditionFilter.vm b/dbflute_fess/freegen/elasticsearch/BsConditionFilter.vm index 2c5e5176b..d93cded2e 100644 --- a/dbflute_fess/freegen/elasticsearch/BsConditionFilter.vm +++ b/dbflute_fess/freegen/elasticsearch/BsConditionFilter.vm @@ -1,5 +1,6 @@ package ${request.package}.cbean.cf.bs; +import java.time.LocalDateTime; import java.util.Collection; import ${request.package}.cbean.cf.${table.camelizedName}CF; @@ -90,11 +91,11 @@ public abstract class Bs${table.camelizedName}CF extends AbstractConditionFilter } } - public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall<${table.camelizedName}CQ> queryLambda) { + public void query(${request.package}.cbean.cq.bs.AbstractConditionQuery.OperatorCall<${table.camelizedName}CQ> queryLambda) { query(queryLambda, null); } - public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall<${table.camelizedName}CQ> queryLambda, + public void query(${request.package}.cbean.cq.bs.AbstractConditionQuery.OperatorCall<${table.camelizedName}CQ> queryLambda, ConditionOptionCall opLambda) { ${table.camelizedName}CQ query = new ${table.camelizedName}CQ(); queryLambda.callback(query); diff --git a/dbflute_fess/freegen/elasticsearch/BsConditionQuery.vm b/dbflute_fess/freegen/elasticsearch/BsConditionQuery.vm index 05cd90025..6986c794c 100644 --- a/dbflute_fess/freegen/elasticsearch/BsConditionQuery.vm +++ b/dbflute_fess/freegen/elasticsearch/BsConditionQuery.vm @@ -1,5 +1,6 @@ package ${request.package}.cbean.cq.bs; +import java.time.LocalDateTime; import java.util.Collection; import ${request.package}.cbean.cq.${table.camelizedName}CQ; diff --git a/dbflute_fess/freegen/elasticsearch/BsEntity.vm b/dbflute_fess/freegen/elasticsearch/BsEntity.vm index 37001d1f6..f6e488795 100644 --- a/dbflute_fess/freegen/elasticsearch/BsEntity.vm +++ b/dbflute_fess/freegen/elasticsearch/BsEntity.vm @@ -33,15 +33,17 @@ public class Bs${table.camelizedName} extends AbstractEntity { // =================================================================================== // Attribute // ========= +#set ($tableMetaSettings = ${table.indexSettings.settings.index.dbflute.get($table.name)}) #foreach ($column in $table.columnList) #if ($column.isNormalColumn) #set ($javaNative = ${column.type}) #elseif ($column.isRefColumn) #set ($javaNative = ${column.camelizedName}) #end +#if ($tableMetaSettings.properties.get($column.name).array)#set($arrayType = "[]")#else#set($arrayType = "")#end #if ($column.name != $idColumn) /** ${column.name} */ - protected ${javaNative} ${column.uncapCamelName}; + protected ${javaNative}${arrayType} ${column.uncapCamelName}; #end #end @@ -59,6 +61,7 @@ public class Bs${table.camelizedName} extends AbstractEntity { #elseif ($column.isRefColumn) #set ($javaNative = ${column.camelizedName}) #end +#if ($tableMetaSettings.properties.get($column.name).array)#set($arrayType = "[]")#else#set($arrayType = "")#end #if ($column.name != $idColumn) #if ($javaNative == "boolean") public ${javaNative} is${column.capCamelName}() { @@ -66,13 +69,13 @@ public class Bs${table.camelizedName} extends AbstractEntity { return ${column.uncapCamelName}; } #else - public ${javaNative} get${column.capCamelName}() { + public ${javaNative}${arrayType} get${column.capCamelName}() { checkSpecifiedProperty("${column.uncapCamelName}"); return ${column.uncapCamelName}; } #end - public void set${column.capCamelName}(${javaNative} value) { + public void set${column.capCamelName}(${javaNative}${arrayType} value) { registerModifiedProperty("${column.uncapCamelName}"); this.${column.uncapCamelName} = value; } diff --git a/dbflute_fess/freegen/elasticsearch/DBMeta.vm b/dbflute_fess/freegen/elasticsearch/DBMeta.vm index 95e177496..4c6fe2446 100644 --- a/dbflute_fess/freegen/elasticsearch/DBMeta.vm +++ b/dbflute_fess/freegen/elasticsearch/DBMeta.vm @@ -2,13 +2,19 @@ package ${request.package}.bsentity.dbmeta; import java.util.List; import java.util.Map; +import java.time.LocalDateTime; + +import ${request.package}.exentity.${table.camelizedName}; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; + public class ${table.camelizedName}Dbm extends AbstractDBMeta { @@ -24,6 +30,73 @@ public class ${table.camelizedName}Dbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { +#set ($tableMetaSettings = ${table.indexSettings.settings.index.dbflute.get($table.name)}) +#foreach ($col in $table.columnList) +#if ($col.isNormalColumn) +#set ($javaNative = ${col.type}) +#elseif ($col.isRefColumn) +#set ($javaNative = ${col.camelizedName}) +#end +#if ($tableMetaSettings.properties.get($col.name).array) + setupEpg(_epgMap, et-> ((${table.camelizedName})et).get${col.camelizedName}(),(et,vl)->((${table.camelizedName}) et).set${col.camelizedName}((${javaNative}[])vl), "${col.uncapCamelName}"); +#else + setupEpg(_epgMap, et-> ((${table.camelizedName})et).get${col.camelizedName}(),(et,vl)->((${table.camelizedName}) et).set${col.camelizedName}(DfTypeUtil.to${javaNative}(vl)), "${col.uncapCamelName}"); +#end +#end + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== +#foreach ($col in $table.columnList) +#if ($col.isNormalColumn) +#set ($javaNative = ${col.type}) +#elseif ($col.isRefColumn) +#set ($javaNative = ${col.camelizedName}) +#end +#if ($tableMetaSettings.properties.get($col.name).array)#set($arrayType = "[]")#else#set($arrayType = "")#end + protected final ColumnInfo _column${col.camelizedName} = cci("${col.name}", "${col.name}", null, null, ${javaNative}${arrayType}.class, "${col.uncapCamelName}", null, false, false, false, "${col.type}", 0, 0, null, false, null, null, null, null, null, false); +#end + +#foreach ($col in $table.columnList) + public ColumnInfo column${col.camelizedName}() { return _column${col.camelizedName}; } +#end + + protected List ccil() { + List ls = newArrayList(); +#foreach ($col in $table.columnList) + ls.add(column${col.camelizedName}()); +#end + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "${table.name}"; + protected final String _tableDispName = "${table.name}"; + protected final String _tablePropertyName = "${table.camelizedName}"; + public String getTableDbName() { return _tableDbName; } + @Override + public String getTableDispName() { return _tableDispName; } + @Override + public String getTablePropertyName() { return _tablePropertyName; } + @Override + public TableSqlName getTableSqlName() { return null; } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +121,6 @@ public class ${table.camelizedName}Dbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +135,27 @@ public class ${table.camelizedName}Dbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "${request.package}.exentity.${table.camelizedName}"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "${request.package}.cbean.${table.camelizedName}CB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "${request.package}.exbhv.${table.camelizedName}Bhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return ${table.camelizedName}.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new ${table.camelizedName}(); } @Override @@ -138,12 +182,6 @@ public class ${table.camelizedName}Dbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/dbflute_fess/output/doc/properties-fess.html b/dbflute_fess/output/doc/properties-fess.html new file mode 100644 index 000000000..727b3dc73 --- /dev/null +++ b/dbflute_fess/output/doc/properties-fess.html @@ -0,0 +1,40814 @@ + + + + + fess properties + + + + +

Properties for fess

+ + +

Properties List

+ +

FessEnv

+ + + + + + + + + + + + + + + + + + + + + + + +
FileEnvLangKey CountDuplicate KeyOver KeyShort Key
../src/main/resources/fess_env.properties--9 --
+

FessConfig (extends FessEnv)

+ + + + + + + + + + + + + + + + + + + + + + + + + +
FileEnvLangKey CountExtendsDuplicate KeyOver KeyShort Key
../src/main/resources/fess_config.properties--8../src/main/resources/fess_env.properties --
+

FessLabel

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileEnvLangKey CountDuplicate KeyOver KeyShort Key
../src/main/resources/fess_label.properties--1103 +

labels.fileConfigId

+

labels.intervalTime

+

labels.webConfigId

+

labels.file_crawling_link_delete

+

labels.web_crawling_link_delete

+

labels.optimize

+

labels.commit

+

labels.path_mapping_button_create

+

labels.path_mapping_button_back

+

labels.path_mapping_link_delete

+

labels.overlapping_host_button_create

+

labels.overlapping_host_button_back

+

labels.overlapping_host_link_delete

+

labels.web_authentication_link_delete

+

labels.labeltype_button_create

+

labels.labeltype_button_back

+

labels.labeltype_link_delete

+

labels.roletype_button_create

+

labels.roletype_button_back

+

labels.roletype_link_delete

+

labels.request_header_link_delete

+

labels.key_match_link_delete

+

labels.role_type

+

labels.label_type

+

labels.data_crawling_link_delete

+

labels.search_log_client_ip

+

labels.failure_url_url

+

labels.file_authentication_link_delete

+

labels.scheduledjob_button_create

+

labels.scheduledjob_button_back

+

labels.scheduledjob_link_delete

+

labels.boost_document_rule_link_delete

+

labels.suggest_elevate_word_link_delete

+

labels.suggest_bad_word_link_delete

+
--
../src/main/resources/fess_label_en.properties-en1105 +

labels.intervalTime

+

labels.file_crawling_link_delete

+

labels.web_crawling_link_delete

+

labels.optimize

+

labels.commit

+

labels.path_mapping_button_create

+

labels.path_mapping_button_back

+

labels.path_mapping_link_delete

+

labels.overlapping_host_button_create

+

labels.overlapping_host_button_back

+

labels.overlapping_host_link_delete

+

labels.web_authentication_link_delete

+

labels.labeltype_button_create

+

labels.labeltype_button_back

+

labels.labeltype_link_delete

+

labels.roletype_button_create

+

labels.roletype_button_back

+

labels.roletype_link_delete

+

labels.request_header_link_delete

+

labels.key_match_link_delete

+

labels.role_type

+

labels.label_type

+

labels.data_crawling_link_delete

+

labels.search_log_client_ip

+

labels.failure_url_url

+

labels.file_authentication_link_delete

+

labels.scheduledjob_button_create

+

labels.scheduledjob_button_back

+

labels.scheduledjob_link_delete

+

labels.boost_document_rule_link_delete

+

labels.suggest_elevate_word_link_delete

+

labels.suggest_bad_word_link_delete

+
+

labels.webCrawlingConfigId

+

labels.fileCrawlingConfigId

+
 
../src/main/resources/fess_label_ja.properties-ja1103 +

labels.fileConfigId

+

labels.intervalTime

+

labels.webConfigId

+

labels.file_crawling_link_delete

+

labels.web_crawling_link_delete

+

labels.optimize

+

labels.commit

+

labels.path_mapping_button_create

+

labels.path_mapping_button_back

+

labels.path_mapping_link_delete

+

labels.overlapping_host_button_create

+

labels.overlapping_host_button_back

+

labels.overlapping_host_link_delete

+

labels.web_authentication_link_delete

+

labels.labeltype_button_create

+

labels.labeltype_button_back

+

labels.labeltype_link_delete

+

labels.roletype_button_create

+

labels.roletype_button_back

+

labels.roletype_link_delete

+

labels.request_header_link_delete

+

labels.key_match_link_delete

+

labels.role_type

+

labels.label_type

+

labels.data_crawling_link_delete

+

labels.search_log_client_ip

+

labels.failure_url_url

+

labels.file_authentication_link_delete

+

labels.scheduledjob_button_create

+

labels.scheduledjob_button_back

+

labels.scheduledjob_link_delete

+

labels.boost_document_rule_link_delete

+

labels.suggest_elevate_word_link_delete

+

labels.suggest_bad_word_link_delete

+
  
+

FessMessage (extends FessLabel)

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileEnvLangKey CountExtendsDuplicate KeyOver KeyShort Key
../src/main/resources/fess_message.properties--144../src/main/resources/fess_label.properties --
../src/main/resources/fess_message_en.properties-en144../src/main/resources/fess_label_en.properties   
../src/main/resources/fess_message_ja.properties-ja144../src/main/resources/fess_label_ja.properties   
+ +

FessEnv

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
No.Property KeyContents
1lasta_di.smart.deploy.mode + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--hot1The mode of Lasta Di's smart-deploy, should be cool in production (e.g. hot, cool, warm)
+
2development.here + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--true1Is development environment here? (used for various purpose, you should set false if unknown)
+
3environment.title + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--Local Development1The title of environment (e.g. local or integartion or production)
+
4framework.debug + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--false1Does it enable the Framework internal debug? (true only when emergency)
+
5time.adjust.time.millis + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--01The milliseconds for (relative or absolute) adjust time (set only when test) @LongType *dynamic in development
+
6mail.send.mock + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--true1Does it send mock mail? (true: no send actually, logging only)
+
7mail.smtp.server.main.host.and.port + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--localhost:251SMTP server settings for main: host:port
+
8mail.subject.test.prefix + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--[Test]1The prefix of subject to show test environment or not
+
9mail.return.path + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--returnpath@docksidestage.org1The common return path of all mail
+
+

*uq: Unique No (same value, same No)

+

FessConfig (extends FessEnv)

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
No.Property KeyContents
1domain.title + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--Fess1The title of domain the application for logging
+
2cookie.default.path + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--/1The default path of cookie (basically '/' if no context path)
+
3cookie.default.expire + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--315569261The default expire of cookie in seconds e.g. 31556926: one year, 86400: one day
+
4cookie.eternal.expire + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--3153600001The eternal expire of cookie in seconds e.g. 315360000: ten year, 86400: one day
+
5cookie.remember.me.harbor.key + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--FES1The cookie key of remember-me for Fess
+
6paging.page.size + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--41The size of one page for paging
+
7paging.page.range.size + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--31The size of page range for paging
+
8paging.page.range.fill.limit + + + + + + + + + + + + + + + +
EnvLangPropertyuqComment
--true1The option 'fillLimit' of page range for paging
+
+

*uq: Unique No (same value, same No)

+

FessLabel

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
No.Property KeyContents
1labels.authRealm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Realm1
-enRealm1
-ja認証レルム2
+
2labels.available + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Status1
-enStatus1
-ja状態2
+
3labels.createdBy + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Created by1
-enCreated by1
-ja作成者2
+
4labels.createdTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Created Time1
-enCreated Time1
-ja作成日時2
+
5labels.deletedBy + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Deleted by1
-enDeleted by1
-ja削除者2
+
6labels.deletedTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Deleted Time1
-enDeleted Time1
-ja削除日時2
+
7labels.depth + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Depth1
-enDepth1
-ja深さ2
+
8labels.excludedPaths + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Excluded Paths For Crawling1
-enExcluded Paths For Crawling1
-jaクロール対象から除外するパス2
+
9labels.excludedUrls + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Excluded URLs For Crawling1
-enExcluded URLs For Crawling1
-jaクロール対象から除外するURL2
+
10labels.excludedDocPaths + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Excluded Paths For Indexing1
-enExcluded Paths For Indexing1
-ja検索対象から除外するパス2
+
11labels.excludedDocUrls + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Excluded URLs For Indexing1
-enExcluded URLs For Indexing1
-ja検索対象から除外するURL2
+
12labels.hostname + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Hostname1
-enHostname1
-jaホスト名2
+
13labels.id + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--ID1
-enID1
-jaID1
+
14labels.includedPaths + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Included Paths For Crawling1
-enIncluded Paths For Crawling1
-jaクロール対象とするパス2
+
15labels.includedUrls + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Included URLs For Crawling1
-enIncluded URLs For Crawling1
-jaクロール対象とするURL2
+
16labels.includedDocPaths + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Included Paths For Indexing1
-enIncluded Paths For Indexing1
-ja検索対象とするパス2
+
17labels.includedDocUrls + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Included URLs For Indexing1
-enIncluded URLs For Indexing1
-ja検索対象とするURL2
+
18labels.maxAccessCount + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Max Access Count1
-enMax Access Count1
-ja最大アクセス数2
+
19labels.name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-ja設定名2
+
20labels.numOfThread + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Num of Thread1
-enNum of Thread1
-jaスレッド数2
+
21labels.overlappingName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Overlapping Name1
-enOverlapping Name1
-ja重複名2
+
22labels.pageNumber + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Page Number1
-enPage Number1
-jaページ番号2
+
23labels.password + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Password1
-enPassword1
-jaパスワード2
+
24labels.paths + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Paths1
-enPaths1
-jaパス2
+
25labels.port + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Port1
-enPort1
-jaポート2
+
26labels.regex + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Regexp.1
-enRegexp.1
-ja正規表現2
+
27labels.regularName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Regular Name1
-enRegular Name1
-ja正規名2
+
28labels.replacement + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Replacement1
-enReplacement1
-ja置換文字2
+
29labels.sessionId + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Session ID1
-enSession ID1
-jaセッションID2
+
30labels.sortOrder + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Display Order1
-enDisplay Order1
-ja表示順2
+
31labels.updatedBy + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Updated by1
-enUpdated by1
-ja更新者2
+
32labels.updatedTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Updated Time1
-enUpdated Time1
-ja更新日時2
+
33labels.urls + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--URLs1
-enURLs1
-jaURL2
+
34labels.userAgent + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User Agent1
-enUser Agent1
-jaユーザーエージェント2
+
35labels.username + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Username1
-enUsername1
-jaユーザー名2
+
36labels.value + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Value1
-enValue1
-ja2
+
37labels.versionNo + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Version No.1
-enVersion No.1
-jaバージョン番号2
+
38labels.logFileName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Log File Name1
-enLog File Name1
-jaログファイル名2
+
39labels.cronExpression + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Schedule1
-enSchedule1
-jaスケジュール2
+
40labels.dayForCleanup + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Remove Index Before Days1
-enRemove Index Before Days1
-jaインデックスの有効期限2
+
41labels.commitPerCount + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Commit per Document Size1
-enCommit per Document Size1
-jaドキュメント数毎にコミット2
+
42labels.crawlingThreadCount + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Num of Simultaneous Crawler Config1
-enNum of Simultaneous Crawler Config1
-ja同時実行のクロール設定数2
+
43labels.snapshotPath + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Snapshot Path1
-enSnapshot Path1
-jaスナップショットパス2
+
44labels.boost + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Boost1
-enBoost1
-jaブースト値2
+
45labels.uploadedFile + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File1
-enFile1
-jaファイル2
+
46labels.scheduleEnabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Use Schedule1
-enUse Schedule1
-jaスケジュールの利用2
+
47labels.scheduleMonth + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Month1
-enMonth1
-ja2
+
48labels.scheduleDate + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Date1
-enDate1
-ja2
+
49labels.scheduleHour + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Hours1
-enHours1
-ja2
+
50labels.scheduleMin + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Minutes1
-enMinutes1
-ja2
+
51labels.crawlingConfigName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-jaクロール設定名2
+
52labels.crawlingConfigPath + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawling Path1
-enCrawling Path1
-jaクロールパス2
+
53labels.deleteUrl + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--URL1
-enURL1
-jaURL1
+
54labels.processType + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Process Type1
-enProcess Type1
-ja処理方法2
+
55labels.parameters + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Parameters1
-enParameters1
-jaパラメータ2
+
56labels.designFile + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upaload File1
-enUpaload File1
-jaアップロードファイル2
+
57labels.accessType + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Access Type1
-enAccess Type1
-jaアクセス種別2
+
58labels.additional + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Additional Parameters1
-enAdditional Parameters1
-ja追加パラメータ2
+
59labels.appendQueryParameter + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Additional Query Parameters1
-enAdditional Query Parameters1
-ja検索パラメータの追加2
+
60labels.callback + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--callback1
-encallback1
-jacallback1
+
61labels.clientIp + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Client IP1
-enClient IP1
-jaアクセス元2
+
62labels.code + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User ID1
-enUser ID1
-ja利用者ID2
+
63labels.configId + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Config ID1
-enConfig ID1
-ja設定ID2
+
64labels.configParameter + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Config Parameters1
-enConfig Parameters1
-ja設定パラメータ2
+
65labels.content + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Content1
-enContent1
-jaコンテンツ2
+
66labels.csvEncoding + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--CSV Encoding1
-enCSV Encoding1
-jaCSVエンコーディング2
+
67labels.csvFileEncoding + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--CSV Encoding1
-enCSV Encoding1
-jaCSVエンコーディング2
+
68labels.currentServerForSelect + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Current Server (Select)1
-enCurrent Server (Select)1
-ja現在の検索用サーバー2
+
69labels.currentServerForUpdate + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Current Server (Update)1
-enCurrent Server (Update)1
-ja現在の更新用サーバー2
+
70labels.currentServerStatusForSelect + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Current Server Status (Select)1
-enCurrent Server Status (Select)1
-ja現在の検索用サーバーの状態2
+
71labels.currentServerStatusForUpdate + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Current Server Status (Update)1
-enCurrent Server Status (Update)1
-ja現在の更新用サーバーの状態2
+
72labels.defaultLabelValue + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Default Label1
-enDefault Label1
-jaデフォルトラベル値2
+
73labels.designFileName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File Name1
-enFile Name1
-jaファイル名2
+
74labels.diffCrawling + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Check Last Modified1
-enCheck Last Modified1
-ja差分クロール2
+
75labels.distance + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Distance1
-enDistance1
-ja距離2
+
76labels.encoding + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Encoding1
-enEncoding1
-jaエンコーディング2
+
77labels.errorCount + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error Count1
-enError Count1
-jaエラー回数2
+
78labels.errorLog + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error Log1
-enError Log1
-jaエラーログ2
+
79labels.errorName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error Name1
-enError Name1
-jaエラー名2
+
80labels.expiredTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Expired1
-enExpired1
-ja有効期限2
+
81labels.failureCountThreshold + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failure Count1
-enFailure Count1
-ja障害回数2
+
82labels.fileConfigName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Config Name1
-enConfig Name1
-ja設定名2
+
83labels.fileConfigId + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--FS Config Name1
-enID2
-jaFS設定名3
+
84labels.fileName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File name1
-enFile name1
-jaファイル名2
+
85labels.groupName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Solr Group1
-enSolr Group1
-jaSolrグループ名2
+
86labels.handlerName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Handler Name1
-enHandler Name1
-jaハンドラ名2
+
87labels.handlerParameter + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Parameters1
-enParameters1
-jaパラメータ2
+
88labels.handlerScript + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Scripts1
-enScripts1
-jaスクリプト2
+
89labels.hitCount + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Hit Count1
-enHit Count1
-jaヒット数2
+
90labels.hotSearchWord + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Popular words1
-enPopular words1
-ja注目キーワード2
+
91labels.ignoreFailureType + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Ignored Failure Type1
-enIgnored Failure Type1
-ja除外する障害タイプ2
+
92labels.intervalTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Interval1
-enInterval1
-ja間隔2
+
93labels.lastAccessTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Last Accessed1
-enLast Accessed1
-ja最終アクセス日時2
+
94labels.latitude + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Latitude1
-enLatitude1
-ja緯度2
+
95labels.longitude + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Longitude1
-enLongitude1
-ja軽度2
+
96labels.notificationTo + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Notification To1
-enNotification To1
-ja通知アドレス2
+
97labels.num + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Num1
-enNum1
-ja表示数2
+
98labels.overwrite + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Overwrite1
-enOverwrite1
-jaデータの上書き2
+
99labels.pn + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Page Numger1
-enPage Numger1
-jaページ番号2
+
100labels.protocolScheme + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Scheme1
-enScheme1
-ja認証方法2
+
101labels.purgeByBots + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Purge By Bots1
-enPurge By Bots1
-jaログ削除のBots名2
+
102labels.purgeSearchLogDay + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Purge Search Log1
-enPurge Search Log1
-ja指定日数以前の検索ログ削除2
+
103labels.query + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Query1
-enQuery1
-jaクエリー2
+
104labels.queryId + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Query ID1
-enQuery ID1
-jaクエリーID2
+
105labels.queryOffset + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Offset1
-enOffset1
-jaオフセット2
+
106labels.queryPageSize + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Page Size1
-enPage Size1
-ja表示サイズ2
+
107labels.range + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Range1
-enRange1
-ja範囲2
+
108labels.referer + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Referrer1
-enReferrer1
-ja参照元2
+
109labels.requestedTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Requested Time1
-enRequested Time1
-ja検索時刻2
+
110labels.responseTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Response Time1
-enResponse Time1
-ja応答時間2
+
111labels.returnPath + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Return Path1
-enReturn Path1
-ja戻りパス2
+
112labels.rt + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--rt1
-enrt1
-jart1
+
113labels.scheduleDay + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Schedule1
-enSchedule1
-jaスケジュール2
+
114labels.searchLog + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Log1
-enSearch Log1
-ja検索ログ2
+
115labels.searchWord + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Word1
-enSearch Word1
-ja検索語2
+
116labels.serverRotation + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Server Rotation1
-enServer Rotation1
-jaサーバ切り替え2
+
117labels.snapshotReplication + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Index Replication1
-enIndex Replication1
-jaリプリケーション機能2
+
118labels.solrInstanceName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Solr Instance Name1
-enSolr Instance Name1
-jaSolrインスタンス名2
+
119labels.sort + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Sort1
-enSort1
-jaソート2
+
120labels.start + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Pos1
-enStart Pos1
-ja開始位置2
+
121labels.supportedSearch + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Supported Search1
-enSupported Search1
-jaサポートする検索2
+
122labels.threadName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Thread Name1
-enThread Name1
-jaスレッド名2
+
123labels.type + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Type1
-enType1
-jaタイプ2
+
124labels.u + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--URL1
-enURL1
-jaURL1
+
125labels.uri + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--URI1
-enURI1
-jaURI1
+
126labels.url + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--URL1
-enURL1
-jaURL1
+
127labels.userFavorite + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Favorite Log1
-enFavorite Log1
-jaお気に入りログ2
+
128labels.userId + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User ID1
-enUser ID1
-ja利用者ID2
+
129labels.userInfo + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User Info1
-enUser Info1
-ja利用者情報2
+
130labels.userSessionId + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User ID1
-enUser ID1
-ja利用者ID2
+
131labels.webApiJson + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--JSON Response1
-enJSON Response1
-jaJSON応答2
+
132labels.webApiXml + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--XML Response1
-enXML Response1
-jaXML応答2
+
133labels.webConfigId + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--ID1
-enID1
-jaID1
+
134labels.webConfigName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Config Name1
-enConfig Name1
-ja設定名2
+
135labels.allLanguages + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--All Languages1
-enAll Languages1
-jaすべての言語2
+
136labels.dictId + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Dictionary ID1
-enDictionary ID1
-ja辞書ID2
+
137labels.docId + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Document ID1
-enDocument ID1
-jaドキュメントID2
+
138labels.endTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--End Time1
-enEnd Time1
-ja終了時刻2
+
139labels.fn + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--fn1
-enfn1
-jafn1
+
140labels.hq + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--hq1
-enhq1
-jahq1
+
141labels.inputs + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Source1
-enSource1
-ja変換元2
+
142labels.jobLogging + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Logging1
-enLogging1
-jaログ2
+
143labels.jobName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-ja名前2
+
144labels.jobStatus + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Status1
-enStatus1
-ja状態2
+
145labels.lang + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--lang1
-enlang1
-jalang1
+
146labels.outputs + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Target 1
-enTarget 1
-ja変換後 2
+
147labels.pos + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--POS1
-enPOS1
-japos2
+
148labels.purgeJobLogDay + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Purge Job Log Before1
-enPurge Job Log Before1
-ja指定日数以前のジョブログ削除2
+
149labels.purgeUserInfoDay + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Purge User Before1
-enPurge User Before1
-ja指定日数以前の利用者情報削除 2
+
150labels.reading + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reading1
-enReading1
-ja読み2
+
151labels.roleTypeIds + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Role ID1
-enRole ID1
-jaロールID2
+
152labels.scriptData + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Script1
-enScript1
-jaスクリプト2
+
153labels.scriptResult + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Result1
-enResult1
-ja結果2
+
154labels.scriptType + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Executor1
-enExecutor1
-ja実行方法2
+
155labels.segmentation + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Segmentation1
-enSegmentation1
-ja分割2
+
156labels.startTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Time1
-enStart Time1
-ja開始時刻2
+
157labels.target + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Target1
-enTarget1
-ja対象2
+
158labels.token + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Token1
-enToken1
-jaトークン2
+
159labels.useAclAsRole + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Use ACL as Role1
-enUse ACL as Role1
-jaACLをロールに利用2
+
160labels.synonymFile + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Synonym File1
-enSynonym File1
-ja同義語ファイル2
+
161labels.userDictFile + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--UserDict File1
-enUserDict File1
-jaユーザー辞書ファイル2
+
162labels.suggestElevateWordFile + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Additional Word File1
-enAdditional Word File1
-ja追加候補ファイル2
+
163labels.suggestBadWordFile + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Bad Word File1
-enBad Word File1
-jaNGワードファイル2
+
164labels.menu_system + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--System1
-enSystem1
-jaシステム2
+
165labels.menu.wizard + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Wizard1
-enWizard2
-ja設定ウィザード3
+
166labels.menu.crawl_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» General1
-enGeneral2
-jaクロール全般3
+
167labels.menu.scheduled_job_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Scheduled Jobs1
-enScheduled Jobs2
-jaジョブ管理3
+
168labels.menu.system_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» System1
-enSystem2
-jaシステム設定3
+
169labels.menu.document_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Index1
-enIndex2
-jaインデックス3
+
170labels.menu.design + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Design1
-enDesign2
-jaデザイン3
+
171labels.menu.dict + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Dictionary1
-enDictionary2
-ja辞書3
+
172labels.menu.data + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Backup/Restore1
-enBackup/Restore2
-jaバックアップ/リストア3
+
173labels.menu_crawl + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawler1
-enCrawler1
-jaクロール2
+
174labels.menu.web + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Web1
-enWeb2
-jaウェブ3
+
175labels.menu.file_system + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» File System1
-enFile System2
-jaファイルシステム3
+
176labels.menu.data_store + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Data Store1
-enData Store2
-jaデータストア3
+
177labels.menu.label_type + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Label1
-enLabel2
-jaラベル3
+
178labels.menu.key_match + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Key Match1
-enKey Match2
-jaキーマッチ3
+
179labels.menu.boost_document_rule + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Doc Boost1
-enDoc Boost2
-jaドキュメントブースト3
+
180labels.menu.path_mapping + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Path Mapping1
-enPath Mapping2
-jaパスマッピング3
+
181labels.menu.web_authentication + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Web Authentication1
-enWeb Authentication2
-jaウェブ認証3
+
182labels.menu.file_authentication + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» File Authentication1
-enFile Authentication2
-jaファイルシステム認証3
+
183labels.menu.request_header + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Request Header1
-enRequest Header2
-jaリクエストヘッダー3
+
184labels.menu.overlapping_host + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Overlapping Host1
-enOverlapping Host2
-ja重複ホスト3
+
185labels.menu.role_type + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Role1
-enRole2
-jaロール3
+
186labels.menu_suggest + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Suggest1
-enSuggest1
-jaサジェスト2
+
187labels.menu.suggest_elevate_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Additional Word1
-enAdditional Word2
-ja追加候補3
+
188labels.menu.suggest_bad_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Bad Word1
-enBad Word2
-jaNGワード3
+
189labels.menu_system_log + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--System Info1
-enSystem Info1
-jaシステム情報2
+
190labels.menu.system_info + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Config Info1
-enConfig Info2
-ja設定情報3
+
191labels.menu.session_info + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Session Info1
-enSession Info2
-jaセッション情報3
+
192labels.menu.log + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Log Files1
-enLog Files2
-jaログファイル3
+
193labels.menu.jobLog + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Job Log1
-enJob Log2
-jaジョブログ3
+
194labels.menu.failure_url + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Failure URL1
-enFailure URL2
-ja障害URL3
+
195labels.menu.search_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Search1
-enSearch2
-ja検索3
+
196labels.menu_user_log + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User Info1
-enUser Info1
-ja利用者情報2
+
197labels.menu.search_log + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Search Log1
-enSearch Log2
-ja検索ログ3
+
198labels.menu.stats + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Statistics1
-enStatistics2
-ja統計3
+
199labels.menu.user + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Users1
-enUsers2
-ja利用者3
+
200labels.menu.favoriteLog + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--» Popular URL1
-enPopular URL2
-ja人気URL3
+
201labels.menu.logout + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Logout1
-enLogout1
-jaログアウト2
+
202labels.header.logo_alt + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Fess1
-enFess1
-jaFess1
+
203labels.header.home + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Home1
-enHome1
-jaホーム2
+
204labels.header.help + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Help1
-enHelp1
-jaヘルプ2
+
205labels.footer.copyright + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Copyright(C) 2009-2015 CodeLibs Project. <span class="br-phone"></span>All Rights Reserved.1
-enCopyright(C) 2009-2015 CodeLibs Project. <span class="br-phone"></span>All Rights Reserved.1
-jaCopyright(C) 2009-2015 CodeLibs Project. <span class="br-phone"></span>All Rights Reserved.1
+
206labels.search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search1
-enSearch1
-ja検索2
+
207labels.search_result_status + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Results <b>{2}</b><span class="br-phone"></span><span class="hidden-phone"> -</span> <b>{3}</b> of <b>{1}</b> pages for <b>{0}</b>1
-enResults <b>{2}</b><span class="br-phone"></span><span class="hidden-phone"> -</span> <b>{3}</b> of <b>{1}</b> pages for <b>{0}</b>1
-ja<b>{0}</b> の検索結果<span class="br-phone"></span> <b>{1}</b> 件中 <b>{2}</b> - <b>{3}</b> 件目2
+
208labels.search_result_time + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--({0} sec)1
-en({0} sec)1
-ja({0} 秒)2
+
209labels.prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
210labels.next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
211labels.did_not_match + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Your search - <b>{0}</b> - did not match any documents.1
-enYour search - <b>{0}</b> - did not match any documents.1
-ja<b>{0}</b> に一致する情報は見つかりませんでした。2
+
212labels.search_header_logo_alt + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Fess1
-enFess1
-jaFess1
+
213labels.search_result_noneselect_label + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
---- Label --1
-en-- Label --1
-ja-- ラベル --2
+
214labels.search_result_select_label + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--# selected1
-en# selected1
-ja# 個を選択2
+
215labels.search_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Fess1
-enFess1
-jaFess1
+
216labels.search_hot_search_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Popular Words: 1
-enPopular Words: 1
-ja注目キーワード: 2
+
217labels.search_result_select_sort + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
---- Sort --1
-en-- Sort --1
-ja-- ソート --2
+
218labels.search_result_select_num + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
---- Results per page --1
-en-- Results per page --1
-ja-- 表示件数 --2
+
219labels.search_result_sort_created_asc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Date (ascending)1
-enDate (ascending)1
-ja登録日時 (昇順)2
+
220labels.search_result_sort_created_desc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Date (descending)1
-enDate (descending)1
-ja登録日時 (降順)2
+
221labels.search_result_sort_contentLength_asc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Size (ascending)1
-enSize (ascending)1
-jaサイズ (昇順)2
+
222labels.search_result_sort_contentLength_desc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Size (descending)1
-enSize (descending)1
-jaサイズ (降順)2
+
223labels.search_result_sort_lastModified_asc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Last Modified (ascending)1
-enLast Modified (ascending)1
-ja更新日時 (昇順)2
+
224labels.search_result_sort_lastModified_desc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Last Modified (descending)1
-enLast Modified (descending)1
-ja更新日時 (降順)2
+
225labels.search_result_sort_clickCount_asc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Click (ascending)1
-enClick (ascending)1
-jaクリック数 (昇順)2
+
226labels.search_result_sort_clickCount_desc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Click (descending)1
-enClick (descending)1
-jaクリック数 (降順)2
+
227labels.search_result_sort_favoriteCount_asc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Favorite (ascending)1
-enFavorite (ascending)1
-jaお気に入り数 (昇順)2
+
228labels.search_result_sort_favoriteCount_desc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Favorite (descending)1
-enFavorite (descending)1
-jaお気に入り数 (降順)2
+
229labels.search_result_size + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} bytes1
-en{0} bytes1
-ja{0} バイト2
+
230labels.search_result_created + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Registered: 1
-enRegistered: 1
-ja登録日時: 2
+
231labels.search_result_lastModified + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Last Modified: 1
-enLast Modified: 1
-ja更新日時: 2
+
232labels.search_result_favorite + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Vote it1
-enVote it1
-ja1票入れる2
+
233labels.search_result_favorited + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Voted1
-enVoted1
-ja投票済み2
+
234labels.search_click_count + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Click: {0}1
-enClick: {0}1
-jaクリック数: {0}2
+
235labels.search_result_more + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--more..1
-enmore..1
-ja詳細..2
+
236labels.search_result_cache + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Cache1
-enCache1
-jaキャッシュ2
+
237labels.searchoptions_all + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--All1
-enAll1
-jaすべて2
+
238labels.searchoptions_score + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Score1
-enScore1
-jaスコア2
+
239labels.searchoptions_menu_sort + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Sort: 1
-enSort: 1
-jaソート: 2
+
240labels.searchoptions_menu_num + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Result Per Page: 1
-enResult Per Page: 1
-ja表示件数: 2
+
241labels.searchoptions_num + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} results1
-en{0} results1
-ja{0} 件2
+
242labels.searchoptions_menu_lang + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Language: 1
-enLanguage: 1
-ja言語: 2
+
243labels.searchoptions_menu_labels + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Labels: 1
-enLabels: 1
-jaラベル: 2
+
244labels.searchheader_username + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Username: {0}1
-enUsername: {0}1
-jaユーザー名: {0}2
+
245labels.error_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error1
-enError1
-jaエラー2
+
246labels.system_error_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--System Error1
-enSystem Error1
-jaシステムエラー2
+
247labels.contact_site_admin + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Contact the Site Administrator.1
-enContact the Site Administrator.1
-jaサイト管理者にお問い合わせください。2
+
248labels.request_error_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Bad Request1
-enBad Request1
-jaリクエストエラー2
+
249labels.bad_request + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Invalid request for the url.1
-enInvalid request for the url.1
-jaページへのリクエストが正しくありません。2
+
250labels.page_not_found_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Page Not Found1
-enPage Not Found1
-jaページが存在しません2
+
251labels.check_url + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Check the url.1
-enCheck the url.1
-jaURLを確認してください。2
+
252labels.home + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Home1
-enHome1
-jaホーム2
+
253labels.user_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User Name1
-enUser Name1
-jaユーザー名2
+
254labels.login + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Login1
-enLogin1
-jaログイン2
+
255labels.login.footer_copyright + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Copyright(C) 2009-2014 CodeLibs Project. All Rights Reserved.1
-enCopyright(C) 2009-2014 CodeLibs Project. All Rights Reserved.1
-jaCopyright(C) 2009-2014 CodeLibs Project. All Rights Reserved.1
+
256labels.login_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Login1
-enLogin1
-jaログイン2
+
257labels.index_label + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Labels1
-enLabels1
-jaラベル2
+
258labels.index_lang + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Languages1
-enLanguages1
-ja言語2
+
259labels.index_sort + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Sort1
-enSort1
-jaソート2
+
260labels.index_num + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Results per page1
-enResults per page1
-ja表示件数2
+
261labels.logout_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Logout1
-enLogout1
-jaログアウト2
+
262labels.logout + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Logout1
-enLogout1
-jaログアウト2
+
263labels.do_you_want_to_logout + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Do you want to logout?1
-enDo you want to logout?1
-jaログアウトしますか?2
+
264labels.logout_button + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Logout1
-enLogout1
-jaログアウト2
+
265labels.top.search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search1
-enSearch1
-ja検索2
+
266labels.search_top_logo_alt + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Fess1
-enFess1
-jaFess1
+
267labels.index_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Fess1
-enFess1
-jaFess1
+
268labels.index_subtitle + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Full tExt Search Server1
-enFull tExt Search Server1
-jaFull tExt Search Server 〜 全文検索サーバー2
+
269labels.index_search_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search1
-enSearch1
-ja検索2
+
270labels.index_form_query_label + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search the Web/Document1
-enSearch the Web/Document1
-jaウェブ/文書の検索2
+
271labels.index_form_label_label + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Select a label1
-enSelect a label1
-jaラベルの選択2
+
272labels.index_form_search_btn + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search1
-enSearch1
-ja検索2
+
273labels.index_form_reset_btn + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reset1
-enReset1
-jaリセット2
+
274labels.index_hotkeywords_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Popular Words1
-enPopular Words1
-ja注目キーワード2
+
275labels.index_osdd_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Fess Search1
-enFess Search1
-jaFess Search1
+
276labels.index_form_option_btn + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Options1
-enOptions1
-jaオプション2
+
277labels.index_help + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Help1
-enHelp1
-jaヘルプ2
+
278labels.search_options + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Options1
-enSearch Options1
-ja検索オプション2
+
279labels.search_options_close + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Close1
-enClose1
-ja閉じる2
+
280labels.search_options_clear + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Clear1
-enClear1
-jaクリア2
+
281labels.search_cache_msg + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--This is a cache of {0}. It is a snapshot of the page at {1}.1
-enThis is a cache of {0}. It is a snapshot of the page at {1}.1
-jaこのページは {0} のキャッシュです。{1} に存在していたページのスナップショットです。2
+
282labels.search_unknown + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Unknown1
-enUnknown1
-ja不明2
+
283labels.footer_back_to_top + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back to top1
-enBack to top1
-ja上部へ移動2
+
284labels.header_brand_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Fess1
-enFess1
-jaFess1
+
285labels.header_form_option_btn + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Options1
-enOptions1
-jaオプション2
+
286labels.file_crawling_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File Crawling Configuration1
-enFile Crawling Configuration1
-jaファイルシステムクロールの設定2
+
287labels.file_crawling_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File Crawling Configuration1
-enFile Crawling Configuration1
-jaファイルシステムクロールの設定2
+
288labels.included_paths + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Included Paths For Crawling1
-enIncluded Paths For Crawling1
-jaクロール対象とするパス2
+
289labels.excluded_paths + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Excluded Paths For Crawling1
-enExcluded Paths For Crawling1
-jaクロール対象から除外するパス2
+
290labels.included_doc_paths + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Included Paths For Indexing1
-enIncluded Paths For Indexing1
-ja検索対象とするパス2
+
291labels.excluded_doc_paths + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Excluded Paths For Indexing1
-enExcluded Paths For Indexing1
-ja検索対象から除外するパス2
+
292labels.config_parameter + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Config Parameters1
-enConfig Parameters1
-ja設定パラメータ2
+
293labels.max_access_count + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Max Access Count1
-enMax Access Count1
-ja最大アクセス数2
+
294labels.number_of_thread + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--The number of Tread1
-enThe number of Tread1
-jaスレッド数2
+
295labels.interval_time + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Interval time1
-enInterval time1
-ja間隔2
+
296labels.millisec + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--ms1
-enms1
-jaミリ秒2
+
297labels.file_crawling_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
298labels.file_crawling_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
299labels.file_crawling_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
300labels.file_crawling_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm File Crawling Configuration1
-enConfirm File Crawling Configuration1
-jaファイルシステムクロールの設定の確認2
+
301labels.file_crawling_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
302labels.file_crawling_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
303labels.file_crawling_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
304labels.file_crawling_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
305labels.file_crawling_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
306labels.file_crawling_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
307labels.file_crawling_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
308labels.file_crawling_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
309labels.file_crawling_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
310labels.file_crawling_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
311labels.file_crawling_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
312labels.file_crawling_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
313labels.file_crawling_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
314labels.web_crawling_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Web Crawling Configuration1
-enWeb Crawling Configuration1
-jaウェブクロールの設定2
+
315labels.web_crawling_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Web Crawling Configuration1
-enWeb Crawling Configuration1
-jaウェブクロールの設定2
+
316labels.included_urls + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Included URLs For Crawling1
-enIncluded URLs For Crawling1
-jaクロール対象とするURL2
+
317labels.excluded_urls + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Excluded URLs For Crawling1
-enExcluded URLs For Crawling1
-jaクロール対象から除外するURL2
+
318labels.included_doc_urls + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Included URLs For Indexing1
-enIncluded URLs For Indexing1
-ja検索対象とするURL2
+
319labels.excluded_doc_urls + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Excluded URLs For Indexing1
-enExcluded URLs For Indexing1
-ja検索対象から除外するURL2
+
320labels.user_agent + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User Agent1
-enUser Agent1
-jaユーザーエージェント2
+
321labels.web_crawling_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
322labels.web_crawling_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
323labels.web_crawling_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
324labels.web_crawling_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Web Crawling Configuration1
-enConfirm Web Crawling Configuration1
-jaウェブクロールの設定の確認2
+
325labels.web_crawling_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
326labels.web_crawling_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
327labels.web_crawling_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
328labels.web_crawling_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
329labels.web_crawling_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
330labels.web_crawling_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
331labels.web_crawling_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
332labels.web_crawling_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
333labels.web_crawling_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
334labels.web_crawling_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
335labels.web_crawling_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
336labels.web_crawling_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
337labels.web_crawling_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
338labels.crawler_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--General Configuration1
-enGeneral Configuration1
-jaクロール全般の設定2
+
339labels.crawler_title_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--General Configuration1
-enGeneral Configuration1
-jaクロール全般の設定2
+
340labels.schedule + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Schedule1
-enSchedule1
-jaスケジュール2
+
341labels.optimize + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Optimize Index1
-enOptimize Index1
-jaインデックスの最適化2
+
342labels.enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Enabled1
-enEnabled1
-ja有効2
+
343labels.commit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Commit Index1
-enCommit Index1
-jaインデックスのコミット2
+
344labels.server_rotation + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Server Rotation1
-enServer Rotation1
-jaサーバ切り替え2
+
345labels.day_for_cleanup + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Remove Index Before1
-enRemove Index Before1
-jaインデックスの有効期限2
+
346labels.day + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Day1
-enDay1
-ja2
+
347labels.crawl_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
348labels.none + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--None1
-enNone1
-jaなし2
+
349labels.commit_per_count + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Commit per Document Size1
-enCommit per Document Size1
-jaドキュメント数毎にコミット2
+
350labels.crawling_thread_count + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Num of Simultaneous Crawler Config1
-enNum of Simultaneous Crawler Config1
-ja同時実行のクロール設定数2
+
351labels.diff_crawling + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Check Last Modified1
-enCheck Last Modified1
-ja差分クロール2
+
352labels.use_acl_as_role + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Use ACL as Role1
-enUse ACL as Role1
-jaACLをロールに利用2
+
353labels.search_log_enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Logging1
-enSearch Logging1
-ja検索ログ2
+
354labels.user_info_enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User Logging1
-enUser Logging1
-ja利用者ログ2
+
355labels.user_favorite_enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Favarite Logging1
-enFavarite Logging1
-jaお気に入りログ2
+
356labels.web_api_xml_enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--XML Response1
-enXML Response1
-jaXML応答2
+
357labels.web_api_json_enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--JSON Response1
-enJSON Response1
-jaJSON応答2
+
358labels.web_api_suggest_enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Suggest API Response1
-enSuggest API Response1
-jaサジェストAPI応答2
+
359labels.web_api_analysis_enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Analysis API Response1
-enAnalysis API Response1
-ja解析API応答2
+
360labels.default_label_value + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Default Label Value1
-enDefault Label Value1
-jaデフォルトラベル値2
+
361labels.append_query_param_enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Append Params to URL1
-enAppend Params to URL1
-ja検索パラメータの追加2
+
362labels.supported_search_feature + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Supported Search1
-enSupported Search1
-jaサポートする検索2
+
363labels.ignore_failure_type + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Excluded Failure Type1
-enExcluded Failure Type1
-ja除外する障害タイプ2
+
364labels.failure_count_threshold + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failure Count Threshold1
-enFailure Count Threshold1
-ja障害回数2
+
365labels.hot_search_word_enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Popular Word Response1
-enPopular Word Response1
-ja注目キーワード応答2
+
366labels.supported_search_web + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Web1
-enWeb1
-jaウェブ2
+
367labels.supported_search_none + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Not Available1
-enNot Available1
-ja利用不可2
+
368labels.purge_session_info_day + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Purge Session Info Before1
-enPurge Session Info Before1
-ja指定日数以前のセッション情報削除2
+
369labels.purge_search_log_day + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Purge Search Log Before1
-enPurge Search Log Before1
-ja指定日数以前の検索ログ削除2
+
370labels.purge_job_log_day + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Purge Job Log Before1
-enPurge Job Log Before1
-ja指定日数以前のジョブログ削除2
+
371labels.purge_user_info_day + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Purge User Before1
-enPurge User Before1
-ja指定日数以前の利用者情報削除2
+
372labels.purge_by_bots + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Bots Name For Purge1
-enBots Name For Purge1
-jaログ削除のBots名2
+
373labels.csv_file_encoding + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Encoding for CSV1
-enEncoding for CSV1
-jaCSVエンコーディング2
+
374labels.notification_to + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Notification Email1
-enNotification Email1
-ja通知アドレス2
+
375labels.path_mapping_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Path Mapping Configuration1
-enPath Mapping Configuration1
-jaパスマッピングの設定2
+
376labels.path_mapping_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Path Mapping1
-enPath Mapping1
-jaパスマッピングの設定2
+
377labels.path_mapping_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
378labels.disabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Disabled1
-enDisabled1
-ja無効2
+
379labels.path_mapping_pt_crawling + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawling1
-enCrawling1
-jaクロール時2
+
380labels.path_mapping_pt_displaying + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Displaying1
-enDisplaying1
-ja表示時2
+
381labels.path_mapping_pt_both + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawling/Displaying1
-enCrawling/Displaying1
-jaクロール時/表示時2
+
382labels.path_mapping_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Path Mapping1
-enConfirm Path Mapping1
-jaパスマッピングの設定の確認2
+
383labels.regular_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Regular Name1
-enRegular Name1
-ja正規名2
+
384labels.overlapping_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Overlapping Name1
-enOverlapping Name1
-ja重複名2
+
385labels.path_mapping_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
386labels.path_mapping_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
387labels.path_mapping_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
388labels.path_mapping_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
389labels.path_mapping_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
390labels.path_mapping_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
391labels.path_mapping_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
392labels.path_mapping_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
393labels.path_mapping_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
394labels.path_mapping_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
395labels.path_mapping_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
396labels.path_mapping_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
397labels.path_mapping_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
398labels.path_mapping_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
399labels.path_mapping_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
400labels.overlapping_host_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Overlapping Host Configuration1
-enOverlapping Host Configuration1
-ja重複ホストの設定2
+
401labels.overlapping_host_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Overlapping Host1
-enOverlapping Host1
-ja重複ホストの設定2
+
402labels.overlapping_host_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
403labels.overlapping_host_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Overlapping Host1
-enConfirm Overlapping Host1
-ja重複ホストの設定の確認2
+
404labels.overlapping_host_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
405labels.overlapping_host_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
406labels.overlapping_host_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
407labels.overlapping_host_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
408labels.overlapping_host_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
409labels.overlapping_host_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
410labels.overlapping_host_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
411labels.overlapping_host_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
412labels.overlapping_host_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
413labels.overlapping_host_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
414labels.overlapping_host_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
415labels.overlapping_host_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
416labels.overlapping_host_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
417labels.overlapping_host_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
418labels.overlapping_host_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
419labels.system_title_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--System Configuration1
-enSystem Configuration1
-jaシステム設定2
+
420labels.system_title_system_status + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--System Status1
-enSystem Status1
-jaシステム状態2
+
421labels.es_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
422labels.es_active + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Active1
-enActive1
-ja有効2
+
423labels.es_inactive + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Inactive1
-enInactive1
-ja無効2
+
424labels.es_ready + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Ready1
-enReady1
-ja準備中2
+
425labels.es_completed + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Completed1
-enCompleted1
-ja完了2
+
426labels.es_unfinished + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Unfinished1
-enUnfinished1
-ja未完了2
+
427labels.es_action_none + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--None1
-enNone1
-jaなし2
+
428labels.es_action_commit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Commit1
-enCommit1
-jaコミット2
+
429labels.es_action_optimize + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Optimize1
-enOptimize1
-ja最適化2
+
430labels.es_action_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
431labels.es_action_confirm_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Results1
-enResults1
-ja結果一覧2
+
432labels.es_action_all + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--All1
-enAll1
-jaすべて2
+
433labels.es_cluster_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Cluster Name1
-enCluster Name1
-jaクラスタ名2
+
434labels.es_title_action + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Solr Action1
-enSolr Action1
-jaSolr アクション2
+
435labels.es_title_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete Docs From Index1
-enDelete Docs From Index1
-jaインデックス削除2
+
436labels.crawler_process_running + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawler Process1
-enCrawler Process1
-jaクローラープロセス2
+
437labels.crawler_running + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Running1
-enRunning1
-ja実行中2
+
438labels.crawler_stopped + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Stopped1
-enStopped1
-ja停止中2
+
439labels.crawler_process_action + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Action1
-enAction1
-jaアクション2
+
440labels.es_document_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Added Docs1
-enAdded Docs1
-ja追加されたドキュメント2
+
441labels.es_group_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Server Group1
-enServer Group1
-jaサーバーグループ2
+
442labels.session_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Session 1
-enSession 1
-jaセッション2
+
443labels.es_num_of_docs + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Num of Docs1
-enNum of Docs1
-jaドキュメント数2
+
444labels.es_title_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Solr Status1
-enSolr Status1
-jaSolr 状態設定2
+
445labels.crawler_button_start + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Crawler1
-enStart Crawler1
-jaクロールの開始2
+
446labels.crawler_button_stop + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Stop Crawker1
-enStop Crawker1
-jaクロールの停止2
+
447labels.es_management_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Solr Instance1
-enSolr Instance1
-jaSolrインスタンス2
+
448labels.es_instance_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-ja名前2
+
449labels.es_instance_status + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Status1
-enStatus1
-ja状態2
+
450labels.es_instance_action + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Action1
-enAction1
-jaアクション2
+
451labels.es_instance_start + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start1
-enStart1
-ja起動2
+
452labels.es_instance_stop + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Stop1
-enStop1
-ja停止2
+
453labels.es_instance_reload + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reload1
-enReload1
-jaリロード2
+
454labels.es_action_url_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--URL1
-enURL1
-jaURL1
+
455labels.system_document_all + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--All1
-enAll1
-jaすべて2
+
456labels.system_group_server_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Group : Server1
-enGroup : Server1
-jaグループ : サーバー2
+
457labels.system_server_status + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Server Status1
-enServer Status1
-jaサーバー状態2
+
458labels.system_index_status + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Index Status1
-enIndex Status1
-jaインデックス状態2
+
459labels.crawler_status_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawler Status1
-enCrawler Status1
-jaクローラー状態2
+
460labels.crawler_sessionid_all + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--All1
-enAll1
-jaすべて2
+
461labels.no_available_solr_servers + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--No available Solr server.1
-enNo available Solr server.1
-ja利用可能なSolrサーバがありません。2
+
462labels.suggest_document_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Added Suggest Docs1
-enAdded Suggest Docs1
-ja追加されたサジェストドキュメント2
+
463labels.suggest_type + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--type1
-entype1
-ja種別2
+
464labels.suggest_type_all + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--all1
-enall1
-jaすべて2
+
465labels.suggest_type_content + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--content1
-encontent1
-jaコンテンツ2
+
466labels.suggest_type_searchlog + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--search words1
-ensearch words1
-ja検索ログ2
+
467labels.suggest_search_log_enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Suggest by Search Words1
-enSuggest by Search Words1
-ja検索語サジェスト2
+
468labels.purge_suggest_search_log_day + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Purge Suggest Docs by Search Words1
-enPurge Suggest Docs by Search Words1
-ja検索語サジェストの有効期限2
+
469labels.crawling_session_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Session Information1
-enSession Information1
-jaセッション情報2
+
470labels.crawling_session_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawling Information1
-enCrawling Information1
-jaクロール情報2
+
471labels.crawling_session_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
472labels.crawling_session_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
473labels.crawling_session_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawling Session1
-enCrawling Session1
-jaクロール情報2
+
474labels.crawling_session_search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search1
-enSearch1
-ja検索2
+
475labels.crawling_session_reset + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reset1
-enReset1
-jaリセット2
+
476labels.crawling_session_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
477labels.crawling_session_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
478labels.crawling_session_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
479labels.crawling_session_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
480labels.crawling_session_session_id_search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Session ID: 1
-enSession ID: 1
-jaセッション ID: 2
+
481labels.crawling_session_session_id + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Session ID1
-enSession ID1
-jaセッション ID2
+
482labels.crawling_session_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-ja名前2
+
483labels.crawling_session_created_time + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Created1
-enCreated1
-ja登録時刻2
+
484labels.crawling_session_expired_time + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Expired1
-enExpired1
-ja期限2
+
485labels.crawling_session_delete_all_link + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete All1
-enDelete All1
-jaすべて削除2
+
486labels.crawling_session_delete_all_confirmation + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Do you want to delete all?1
-enDo you want to delete all?1
-ja削除しますか?2
+
487labels.crawling_session_CrawlerStatus + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawling Status1
-enCrawling Status1
-jaクロールステータス2
+
488labels.crawling_session_CrawlerStartTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Time (Crawling)1
-enStart Time (Crawling)1
-ja開始時刻 (クロール)2
+
489labels.crawling_session_CrawlerEndTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--End Time (Crawling)1
-enEnd Time (Crawling)1
-ja終了時刻 (クロール)2
+
490labels.crawling_session_CrawlerExecTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Exec Time (Crawling)1
-enExec Time (Crawling)1
-ja実行時間 (クロール)2
+
491labels.crawling_session_WebFsCrawlStartTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Time (Web/File)1
-enStart Time (Web/File)1
-ja開始時刻 (ウェブ/ファイル)2
+
492labels.crawling_session_WebFsCrawlEndTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--End Time (Web/File)1
-enEnd Time (Web/File)1
-ja終了時刻 (ウェブ/ファイル)2
+
493labels.crawling_session_DataCrawlStartTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Time (Data Store)1
-enStart Time (Data Store)1
-ja開始時刻 (データストア)2
+
494labels.crawling_session_DataCrawlEndTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--End Time (Data Store)1
-enEnd Time (Data Store)1
-ja終了時刻 (データストア)2
+
495labels.crawling_session_OptimizeStartTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Time (Optimize)1
-enStart Time (Optimize)1
-ja開始時刻 (最適化)2
+
496labels.crawling_session_OptimizeEndTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--End Time (Optimize)1
-enEnd Time (Optimize)1
-ja終了時刻 (最適化)2
+
497labels.crawling_session_OptimizeExecTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Exec Time (Optimize)1
-enExec Time (Optimize)1
-ja実行時間 (最適化)2
+
498labels.crawling_session_CommitStartTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Time (Commit)1
-enStart Time (Commit)1
-ja開始時刻 (コミット)2
+
499labels.crawling_session_CommitEndTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--End Time (Commit)1
-enEnd Time (Commit)1
-ja終了時刻 (コミット)2
+
500labels.crawling_session_CommitExecTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Exec Time (Commit)1
-enExec Time (Commit)1
-ja実行時間 (コミット)2
+
501labels.crawling_session_WebFsCrawlExecTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Exec Time (Web/File)1
-enExec Time (Web/File)1
-ja実行時間 (ウェブ/ファイル)2
+
502labels.crawling_session_WebFsIndexExecTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Indexing Exec Time (Web/File)1
-enIndexing Exec Time (Web/File)1
-jaインデックス化実行時間 (ウェブ/ファイル)2
+
503labels.crawling_session_WebFsIndexSize + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Index Size (Web/File)1
-enIndex Size (Web/File)1
-jaインデックスサイズ (ウェブ/ファイル)2
+
504labels.crawling_session_DataCrawlExecTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Exec Time (Data Store)1
-enExec Time (Data Store)1
-ja実行時間 (データストア)2
+
505labels.crawling_session_DataIndexExecTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Indexing Exec Time (Data Store)1
-enIndexing Exec Time (Data Store)1
-jaインデックス化実行時間 (データストア)2
+
506labels.crawling_session_DataIndexSize + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Index Size (Data Store)1
-enIndex Size (Data Store)1
-jaインデックスサイズ (データストア)2
+
507labels.crawling_session_ReplicationStatus + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Replication Status1
-enReplication Status1
-jaレプリケーションステータス2
+
508labels.crawling_session_ReplicationStartTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Time (Replication)1
-enStart Time (Replication)1
-ja開始時刻 (レプリケーション)2
+
509labels.crawling_session_ReplicationEndTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--End Time (Replication)1
-enEnd Time (Replication)1
-ja終了時刻 (レプリケーション)2
+
510labels.crawling_session_ReplicationExecTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Exec Time (Replication)1
-enExec Time (Replication)1
-ja実行時間 (レプリケーション)2
+
511labels.data_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Backup/Restore Configuration1
-enBackup/Restore Configuration1
-ja設定のバックアップ/リストア2
+
512labels.backup_title_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Backup 1
-enBackup 1
-ja設定のバックアップ2
+
513labels.backup + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Backup1
-enBackup1
-jaバックアップ2
+
514labels.download_data + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download as XML File1
-enDownload as XML File1
-jaダウンロード (XMLファイル)2
+
515labels.download_data_csv + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download as CSV File1
-enDownload as CSV File1
-jaダウンロード (CSVファイル)2
+
516labels.restore_title_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Restore 1
-enRestore 1
-ja設定のリストア2
+
517labels.restore + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File1
-enFile1
-jaファイル2
+
518labels.upload_button + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Restore Data1
-enRestore Data1
-jaデータのリストア2
+
519labels.backup_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confinguration1
-enConfinguration1
-ja設定2
+
520labels.backup_session_info + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Session Info1
-enSession Info1
-jaセッション情報2
+
521labels.backup_search_log + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Log1
-enSearch Log1
-ja検索ログ2
+
522labels.backup_click_log + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Click Long1
-enClick Long1
-jaクリックログ2
+
523labels.web_authentication_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Web Authentication1
-enWeb Authentication1
-jaウェブ認証2
+
524labels.web_authentication_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
525labels.web_authentication_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
526labels.web_authentication_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
527labels.web_authentication_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
528labels.web_authentication_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
529labels.web_authentication_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
530labels.web_authentication_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
531labels.web_authentication_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
532labels.web_authentication_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
533labels.web_authentication_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
534labels.web_authentication_list_hostname + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Hostname1
-enHostname1
-jaホスト名2
+
535labels.web_authentication_list_realm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Realm1
-enRealm1
-jaレルム2
+
536labels.web_authentication_list_web_crawling_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Config Name1
-enConfig Name1
-jaウェブ設定名2
+
537labels.web_authentication_any + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Any1
-enAny1
-ja任意2
+
538labels.web_authentication_create_web_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New Web Config1
-enCreate New Web Config1
-ja新規にウェブクロール設定を作成2
+
539labels.web_authentication_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Web Authentication1
-enWeb Authentication1
-jaウェブ認証2
+
540labels.web_authentication_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
541labels.web_authentication_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
542labels.web_authentication_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
543labels.web_authentication_hostname + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Hostname1
-enHostname1
-jaホスト名2
+
544labels.web_authentication_port + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Port1
-enPort1
-jaポート2
+
545labels.web_authentication_realm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Realm1
-enRealm1
-jaレルム2
+
546labels.web_authentication_scheme + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Scheme1
-enScheme1
-ja認証方法2
+
547labels.web_authentication_username + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Username1
-enUsername1
-jaユーザー名2
+
548labels.web_authentication_password + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Password1
-enPassword1
-jaパスワード2
+
549labels.web_authentication_parameters + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Parameters1
-enParameters1
-jaパラメータ2
+
550labels.web_authentication_web_crawling_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Web Config1
-enWeb Config1
-jaウェブ設定名2
+
551labels.web_authentication_scheme_basic + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Basic1
-enBasic1
-jaBasic認証2
+
552labels.web_authentication_scheme_digest + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Digest1
-enDigest1
-jaDigest認証2
+
553labels.web_authentication_scheme_ntlm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--NTLM1
-enNTLM1
-jaNTLM認証2
+
554labels.web_authentication_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Web Authentication1
-enWeb Authentication1
-jaウェブ認証2
+
555labels.web_authentication_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
556labels.web_authentication_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
557labels.web_authentication_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
558labels.log_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Log Files1
-enLog Files1
-jaログファイル2
+
559labels.log_file_download_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Log Files1
-enLog Files1
-jaログファイル2
+
560labels.log_file_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File Name1
-enFile Name1
-jaファイル名2
+
561labels.log_file_date + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Timestamp1
-enTimestamp1
-ja日時2
+
562labels.labeltype_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Label1
-enLabel1
-jaラベル2
+
563labels.labeltype_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Label1
-enLabel1
-jaラベル2
+
564labels.labeltype_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
565labels.labeltype_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-ja設定名2
+
566labels.labeltype_value + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Value1
-enValue1
-ja2
+
567labels.labeltype_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Label1
-enConfirm Label1
-jaラベルの確認2
+
568labels.labeltype_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
569labels.labeltype_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
570labels.labeltype_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
571labels.labeltype_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
572labels.labeltype_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
573labels.labeltype_included_paths + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Included Paths1
-enIncluded Paths1
-ja対象とするパス2
+
574labels.labeltype_excluded_paths + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Excluded Paths1
-enExcluded Paths1
-ja除外するパス2
+
575labels.labeltype_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
576labels.labeltype_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
577labels.labeltype_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
578labels.labeltype_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
579labels.labeltype_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
580labels.labeltype_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
581labels.labeltype_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
582labels.labeltype_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
583labels.labeltype_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
584labels.labeltype_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
585labels.roletype_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Role1
-enRole1
-jaロール2
+
586labels.roletype_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Role1
-enRole1
-jaロール2
+
587labels.roletype_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
588labels.roletype_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-ja設定名2
+
589labels.roletype_value + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Value1
-enValue1
-ja2
+
590labels.roletype_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Role1
-enConfirm Role1
-jaロールの確認2
+
591labels.roletype_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
592labels.roletype_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
593labels.roletype_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
594labels.roletype_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
595labels.roletype_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
596labels.roletype_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
597labels.roletype_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
598labels.roletype_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
599labels.roletype_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
600labels.roletype_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
601labels.roletype_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
602labels.roletype_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
603labels.roletype_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
604labels.roletype_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
605labels.roletype_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
606labels.request_header_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Request Header1
-enRequest Header1
-jaリクエストヘッダー2
+
607labels.request_header_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
608labels.request_header_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
609labels.request_header_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
610labels.request_header_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
611labels.request_header_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
612labels.request_header_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
613labels.request_header_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
614labels.request_header_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
615labels.request_header_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja戻る2
+
616labels.request_header_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
617labels.request_header_list_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-ja名前2
+
618labels.request_header_list_web_crawling_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Config Name1
-enConfig Name1
-jaウェブ設定名2
+
619labels.request_header_create_web_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New Web Config1
-enCreate New Web Config1
-ja新規にウェブクロール設定を作成2
+
620labels.request_header_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Request Header1
-enRequest Header1
-jaリクエストヘッダー2
+
621labels.request_header_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
622labels.request_header_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
623labels.request_header_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
624labels.request_header_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-ja名前2
+
625labels.request_header_value + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Value1
-enValue1
-ja2
+
626labels.request_header_web_crawling_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Web Config1
-enWeb Config1
-jaウェブ設定名2
+
627labels.request_header_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Request Header1
-enRequest Header1
-jaリクエストヘッダー2
+
628labels.request_header_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
629labels.request_header_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
630labels.request_header_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
631labels.key_match_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Key Match1
-enKey Match1
-jaキーマッチ2
+
632labels.key_match_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
633labels.key_match_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
634labels.key_match_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
635labels.key_match_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
636labels.key_match_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
637labels.key_match_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
638labels.key_match_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
639labels.key_match_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
640labels.key_match_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja戻る2
+
641labels.key_match_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
642labels.key_match_list_term + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Term1
-enTerm1
-ja検索語2
+
643labels.key_match_list_query + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Query1
-enQuery1
-jaクエリー2
+
644labels.key_match_term + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Term1
-enTerm1
-ja検索語2
+
645labels.key_match_query + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Query1
-enQuery1
-jaクエリー2
+
646labels.key_match_size + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Size1
-enSize1
-jaサイズ2
+
647labels.key_match_boost + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Boost1
-enBoost1
-jaブースト2
+
648labels.key_match_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Key Match1
-enKey Match1
-jaキーマッチ2
+
649labels.key_match_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
650labels.key_match_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
651labels.key_match_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
652labels.key_match_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-ja名前2
+
653labels.key_match_value + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Value1
-enValue1
-ja2
+
654labels.key_match_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Key Match1
-enConfirm Key Match1
-jaキーマッチの確認2
+
655labels.key_match_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
656labels.key_match_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
657labels.key_match_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
658labels.design_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Design1
-enDesign1
-jaデザイン2
+
659labels.design_title_file_upload + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File Upload1
-enFile Upload1
-jaファイルアップロード2
+
660labels.design_title_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File Manager1
-enFile Manager1
-jaファイル管理2
+
661labels.design_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upload File1
-enUpload File1
-jaアップロードファイル2
+
662labels.design_file_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upload File Name (Optional)1
-enUpload File Name (Optional)1
-jaアップロードファイル名 (省略可)2
+
663labels.design_button_upload + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upload1
-enUpload1
-jaアップロード2
+
664labels.design_file_title_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Page View Files1
-enPage View Files1
-ja画面表示ファイル2
+
665labels.design_edit_button + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
666labels.design_download_button + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download1
-enDownload1
-jaダウンロード2
+
667labels.design_delete_button + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
668labels.design_use_default_button + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Use Default1
-enUse Default1
-jaデフォルトを使用2
+
669labels.design_file_index + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Top Page1
-enTop Page1
-jaトップページ (フレーム)2
+
670labels.design_file_footer + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Footer1
-enFooter1
-jaフッター2
+
671labels.design_file_search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Results Page (Frame)1
-enResults Page (Frame)1
-ja検索結果ページ (フレーム)2
+
672labels.design_file_searchResults + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Results Page (Content)1
-enResults Page (Content)1
-ja検索結果ページ (コンテンツ)2
+
673labels.design_file_searchNoResult + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Results Page (No Result)1
-enResults Page (No Result)1
-ja検索結果ページ (結果なし)2
+
674labels.design_file_help + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Help Page (Content)1
-enHelp Page (Content)1
-jaヘルプページ (フレーム)2
+
675labels.design_file_header + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Header1
-enHeader1
-jaヘッダー2
+
676labels.design_file_error + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Error Page1
-enSearch Error Page1
-ja検索エラーページ2
+
677labels.design_file_cache + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Cache Page1
-enCache Page1
-jaキャッシュページ2
+
678labels.design_file_errorHeader + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error Page (Header)1
-enError Page (Header)1
-jaエラーページ (ヘッダー)2
+
679labels.design_file_errorFooter + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error Page (Footer)1
-enError Page (Footer)1
-jaエラーページ (フッター)2
+
680labels.design_file_errorNotFound + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error Page (Not Found)1
-enError Page (Not Found)1
-jaエラーページ (ページが見つかりません)2
+
681labels.design_file_errorSystem + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error Page (System Error)1
-enError Page (System Error)1
-jaエラーページ (システムエラー)2
+
682labels.design_file_errorRedirect + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error Page (Redirect)1
-enError Page (Redirect)1
-jaエラーページ (リダイレクト)2
+
683labels.design_file_errorBadRequest + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error Page (BadRequest)1
-enError Page (BadRequest)1
-jaエラーページ (不正なリクエスト)2
+
684labels.design_delete_confirmation + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Do you want to delete it?1
-enDo you want to delete it?1
-ja削除しますか?2
+
685labels.design_title_edit_content + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit Page View File1
-enEdit Page View File1
-ja画面表示ファイル編集2
+
686labels.design_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
687labels.design_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
688labels.data_crawling_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Data Crawling Configuration1
-enData Crawling Configuration1
-jaデータストアクロールの設定2
+
689labels.data_crawling_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Data Crawling Configuration1
-enData Crawling Configuration1
-jaデータストアクロールの設定2
+
690labels.handler_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Handler Name1
-enHandler Name1
-jaハンドラ名2
+
691labels.handler_parameter + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Parameter1
-enParameter1
-jaパラメータ2
+
692labels.handler_script + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Script1
-enScript1
-jaスクリプト2
+
693labels.role_type + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Role1
-enRole1
-jaロール2
+
694labels.label_type + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Label1
-enLabel1
-jaラベル2
+
695labels.data_crawling_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
696labels.data_crawling_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
697labels.data_crawling_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
698labels.data_crawling_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Data Crawling Configuration1
-enConfirm Data Crawling Configuration1
-jaデータストアクロールの設定の確認2
+
699labels.data_crawling_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
700labels.data_crawling_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
701labels.data_crawling_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
702labels.data_crawling_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
703labels.data_crawling_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
704labels.data_crawling_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
705labels.data_crawling_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
706labels.data_crawling_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
707labels.data_crawling_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
708labels.data_crawling_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
709labels.data_crawling_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
710labels.data_crawling_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
711labels.data_crawling_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
712labels.wizard_title_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Configuration Wizard1
-enConfiguration Wizard1
-ja設定ウィザード2
+
713labels.wizard_start_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Configuration Wizard1
-enConfiguration Wizard1
-ja設定ウィザード2
+
714labels.wizard_start_desc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Using Configuration Wizard, you can create crawling settings easily.1
-enUsing Configuration Wizard, you can create crawling settings easily.1
-ja設定ウィザードを利用することで<br>クロールに必要な項目を簡単に設定することができます。2
+
715labels.wizard_start_button + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start1
-enStart1
-ja開始2
+
716labels.wizard_schedule_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawling Schedule1
-enCrawling Schedule1
-jaスケジュールの設定2
+
717labels.wizard_schedule_enabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Use Schedule1
-enUse Schedule1
-jaスケジュールの利用2
+
718labels.wizard_schedule + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Schedule1
-enSchedule1
-jaスケジュール2
+
719labels.wizard_schedule_month_prefix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--MM:1
-enMM:1
-ja  2
+
720labels.wizard_schedule_month_suffix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--  1
-en  1
-ja2
+
721labels.wizard_schedule_date_prefix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--DD:1
-enDD:1
-ja  2
+
722labels.wizard_schedule_date_suffix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--  1
-en  1
-ja2
+
723labels.wizard_schedule_hour_prefix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--hh:1
-enhh:1
-ja  2
+
724labels.wizard_schedule_hour_suffix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--  1
-en  1
-ja2
+
725labels.wizard_schedule_min_prefix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--mm:1
-enmm:1
-ja  2
+
726labels.wizard_schedule_min_suffix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--  1
-en  1
-ja2
+
727labels.wizard_button_next + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
728labels.wizard_button_skip + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Skip1
-enSkip1
-jaスキップ2
+
729labels.wizard_button_cancel + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Cancel1
-enCancel1
-jaキャンセル2
+
730labels.wizard_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
731labels.wizard_crawling_config_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawling Configuration1
-enCrawling Configuration1
-jaクロール設定2
+
732labels.wizard_crawling_config_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-jaクロール設定名2
+
733labels.wizard_crawling_config_path + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawling Path1
-enCrawling Path1
-jaクロールパス2
+
734labels.wizard_button_register_again + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create again1
-enCreate again1
-ja続けて登録2
+
735labels.wizard_button_register_next + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create/Next1
-enCreate/Next1
-ja登録して次へ2
+
736labels.wizard_schedule_day_sun + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Sun1
-enSun1
-ja2
+
737labels.wizard_schedule_day_mon + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Mon1
-enMon1
-ja2
+
738labels.wizard_schedule_day_tue + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Tue1
-enTue1
-ja2
+
739labels.wizard_schedule_day_wed + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Wed1
-enWed1
-ja2
+
740labels.wizard_schedule_day_thu + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Thu1
-enThu1
-ja2
+
741labels.wizard_schedule_day_fri + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Fri1
-enFri1
-ja2
+
742labels.wizard_schedule_day_sat + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Sat1
-enSat1
-ja2
+
743labels.wizard_schedule_day_m_f + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Mon-Fri1
-enMon-Fri1
-ja月-金2
+
744labels.wizard_schedule_day_mwf + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Mon,Wed,Fri1
-enMon,Wed,Fri1
-ja月,水,金2
+
745labels.wizard_schedule_day_tt + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Tue,Thu1
-enTue,Thu1
-ja火,木2
+
746labels.wizard_start_crawling_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Crawling1
-enStart Crawling1
-jaクロール開始2
+
747labels.wizard_start_crawling_desc + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--To click "Start Crawling" button, you can start a crawling now.1
-enTo click "Start Crawling" button, you can start a crawling now.1
-ja「クロール開始」ボタンを押下することで即時にクロールを開始できます。2
+
748labels.wizard_button_start_crawling + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Crawling1
-enStart Crawling1
-jaクロール開始2
+
749labels.wizard_button_finish + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Finish1
-enFinish1
-ja完了2
+
750labels.search_list_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Result1
-enSearch Result1
-ja検索結果2
+
751labels.search_list_index_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Type a search query.1
-enType a search query.1
-ja検索クエリーを入力してください。2
+
752labels.search_list_title_confirm_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete Confirmation1
-enDelete Confirmation1
-ja削除の確認2
+
753labels.search_list_url + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--URL1
-enURL1
-jaURL1
+
754labels.search_list_delete_link + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
755labels.search_log_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Log1
-enSearch Log1
-ja検索ログ2
+
756labels.search_log_search_word_search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Word1
-enSearch Word1
-ja検索語2
+
757labels.search_log_user_code_search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User ID1
-enUser ID1
-ja利用者ID2
+
758labels.search_log_button_search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search1
-enSearch1
-ja検索2
+
759labels.search_log_button_reset + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reset1
-enReset1
-jaリセット2
+
760labels.search_log_requested_time + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Requested Time1
-enRequested Time1
-ja検索時刻2
+
761labels.search_log_search_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Word1
-enSearch Word1
-ja検索語2
+
762labels.search_log_search_query + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Query1
-enSearch Query1
-ja検索クエリー2
+
763labels.search_log_response_time + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Response Time1
-enResponse Time1
-ja応答時間2
+
764labels.search_log_hit_count + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Hits1
-enHits1
-jaヒット数2
+
765labels.search_log_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
766labels.search_log_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
767labels.search_log_delete_all_link + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete All1
-enDelete All1
-jaすべて削除2
+
768labels.search_log_delete_all_confirmation + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Do you want to delete all?1
-enDo you want to delete all?1
-ja削除しますか?2
+
769labels.search_log_sort_up + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--(Up)1
-en(Up)1
-ja2
+
770labels.search_log_sort_down + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--(Down)1
-en(Down)1
-ja2
+
771labels.search_log_download_csv + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download(CSV)1
-enDownload(CSV)1
-jaダウンロード(CSV)2
+
772labels.search_log_search_start_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--First Query Only1
-enFirst Query Only1
-ja検索開始時のみ2
+
773labels.search_log_search_term + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Term1
-enTerm1
-ja期間2
+
774labels.search_log_search_term_from + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--From: 1
-enFrom: 1
-ja開始: 2
+
775labels.search_log_search_term_to + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--To: 1
-enTo: 1
-ja終了: 2
+
776labels.search_log_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Log1
-enSearch Log1
-ja検索ログ2
+
777labels.search_log_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja検索ログ詳細2
+
778labels.search_log_id + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--ID1
-enID1
-jaID1
+
779labels.search_log_solr_query + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Solr Query1
-enSolr Query1
-jaSolrクエリー2
+
780labels.search_log_query_offset + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Offset1
-enOffset1
-jaオフセット2
+
781labels.search_log_query_page_size + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Size1
-enSize1
-ja表示サイズ2
+
782labels.search_log_user_agent + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User Agent1
-enUser Agent1
-jaユーザーエージェント2
+
783labels.search_log_referer + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Referer1
-enReferer1
-ja参照元2
+
784labels.search_log_client_ip + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--IP1
-enIP1
-jaアクセス元2
+
785labels.search_log_session_id + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Session ID1
-enSession ID1
-jaセッションID2
+
786labels.search_log_click_log_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Click Logs1
-enClick Logs1
-jaクリック一覧2
+
787labels.search_log_click_log_url + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--URL1
-enURL1
-jaURL1
+
788labels.search_log_click_log_requestedTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Requested Time1
-enRequested Time1
-jaクリック時刻2
+
789labels.search_log_access_type + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Access Type1
-enAccess Type1
-jaアクセス種別2
+
790labels.failure_url_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failure URL1
-enFailure URL1
-jaアクセス障害URL2
+
791labels.failure_url_search_url + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--URL1
-enURL1
-jaURL1
+
792labels.failure_url_search_error_count + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error Count1
-enError Count1
-jaエラー回数2
+
793labels.failure_url_search_error_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Type1
-enType1
-ja種類2
+
794labels.failure_url_last_access_time + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Last Access1
-enLast Access1
-ja最終アクセス時刻2
+
795labels.failure_url_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
796labels.failure_url_delete_all_confirmation + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Do you want to delete all?1
-enDo you want to delete all?1
-ja削除しますか?2
+
797labels.failure_url_error_count + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Error Count1
-enError Count1
-jaエラー回数2
+
798labels.failure_url_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failure URL Details1
-enFailure URL Details1
-jaアクセス障害URLの詳細2
+
799labels.failure_url_id + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--ID1
-enID1
-jaID1
+
800labels.failure_url_thread_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Thread Name1
-enThread Name1
-jaスレッド名2
+
801labels.failure_url_error_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Type1
-enType1
-ja種類2
+
802labels.failure_url_error_log + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Log1
-enLog1
-jaログ2
+
803labels.failure_url_url + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--URL1
-enURL1
-jaURL1
+
804labels.failure_url_web_config_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Web Crawling Configuration1
-enWeb Crawling Configuration1
-jaウェブクロール設定2
+
805labels.failure_url_file_config_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File Crawling Configuration1
-enFile Crawling Configuration1
-jaファイルクロール設定2
+
806labels.stats_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Statistics1
-enStatistics1
-ja統計2
+
807labels.stats_search_report_type + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Report Type1
-enReport Type1
-jaレポート種別2
+
808labels.stats_search_term + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Term1
-enTerm1
-ja期間2
+
809labels.stats_search_term_from + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--From: 1
-enFrom: 1
-ja開始: 2
+
810labels.stats_search_term_to + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--To: 1
-enTo: 1
-ja終了: 2
+
811labels.stats_button_search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search1
-enSearch1
-ja検索2
+
812labels.stats_button_reset + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reset1
-enReset1
-jaリセット2
+
813labels.stats_search_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Word1
-enSearch Word1
-ja検索語2
+
814labels.stats_search_query + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Query1
-enSearch Query1
-ja検索クエリー2
+
815labels.stats_solr_query + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Solr Query1
-enSolr Query1
-jaSolrクエリー2
+
816labels.stats_user_agent + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User Agent1
-enUser Agent1
-jaユーザーエージェント2
+
817labels.stats_referer + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Referer1
-enReferer1
-ja参照元2
+
818labels.stats_client_ip + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Client IP1
-enClient IP1
-jaクライアントIP2
+
819labels.stats_count + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Count1
-enCount1
-ja件数2
+
820labels.stats_click_url + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Clicked URL1
-enClicked URL1
-jaクリックされたURL2
+
821labels.stats_favorite_url + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Voted URL1
-enVoted URL1
-ja投票されたURL2
+
822labels.system_info_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--System Info1
-enSystem Info1
-jaシステム情報2
+
823labels.system_info_env_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Env Properties1
-enEnv Properties1
-ja環境変数プロパティ2
+
824labels.system_info_prop_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--System Properties1
-enSystem Properties1
-jaシステムプロパティ2
+
825labels.system_info_fess_prop_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Fess Properties1
-enFess Properties1
-jaFess プロパティ2
+
826labels.system_info_bug_report_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Properties for Bug Report1
-enProperties for Bug Report1
-jaバグレポート用2
+
827labels.system_info_crawler_properties_does_not_exist + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--crawler.properties does not exist. Default values are applied.1
-encrawler.properties does not exist. Default values are applied.1
-jacrawler.propertiesファイルが存在していません。デフォルト値が適用されています。2
+
828labels.file_authentication_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File Authentication1
-enFile Authentication1
-jaファイル認証2
+
829labels.file_authentication_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
830labels.file_authentication_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
831labels.file_authentication_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
832labels.file_authentication_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
833labels.file_authentication_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
834labels.file_authentication_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
835labels.file_authentication_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
836labels.file_authentication_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
837labels.file_authentication_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja戻る2
+
838labels.file_authentication_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
839labels.file_authentication_list_hostname + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Hostname1
-enHostname1
-jaホスト名2
+
840labels.file_authentication_list_file_crawling_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Config Name1
-enConfig Name1
-jaファイル設定名2
+
841labels.file_authentication_any + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Any1
-enAny1
-ja任意2
+
842labels.file_authentication_create_file_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New File Config1
-enCreate New File Config1
-ja新規にファイルクロール設定を作成2
+
843labels.file_authentication_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File Authentication1
-enFile Authentication1
-jaファイル認証2
+
844labels.file_authentication_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
845labels.file_authentication_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
846labels.file_authentication_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
847labels.file_authentication_hostname + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Hostname1
-enHostname1
-jaホスト名2
+
848labels.file_authentication_port + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Port1
-enPort1
-jaポート2
+
849labels.file_authentication_scheme + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Scheme1
-enScheme1
-ja認証方法2
+
850labels.file_authentication_username + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Username1
-enUsername1
-jaユーザー名2
+
851labels.file_authentication_password + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Password1
-enPassword1
-jaパスワード2
+
852labels.file_authentication_parameters + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Parameters1
-enParameters1
-jaパラメータ2
+
853labels.file_authentication_file_crawling_config + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--FS Config1
-enFS Config1
-jaFS設定名2
+
854labels.file_authentication_scheme_samba + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Samba1
-enSamba1
-jaSamba1
+
855labels.file_authentication_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File Authentication1
-enFile Authentication1
-jaファイル認証2
+
856labels.file_authentication_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
857labels.file_authentication_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
858labels.file_authentication_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
859labels.pagination_page_guide_msg + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0}/{1} ({2} items)1
-en{0}/{1} ({2} items)1
-ja{0}/{1} ({2}件)2
+
860labels.list_could_not_find_crud_table + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--No data.1
-enNo data.1
-ja登録されていません。2
+
861labels.user_info_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User Info1
-enUser Info1
-ja利用者情報2
+
862labels.user_info_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User Info1
-enUser Info1
-ja利用者情報2
+
863labels.user_info_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja利用者情報詳細2
+
864labels.user_info_search_log_link + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search Log1
-enSearch Log1
-ja検索ログ2
+
865labels.user_info_favorite_log_link + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Favorite Log1
-enFavorite Log1
-ja人気URL2
+
866labels.user_info_search_code + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User ID1
-enUser ID1
-ja利用者ID2
+
867labels.user_info_list_code + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User ID1
-enUser ID1
-ja利用者ID2
+
868labels.user_info_list_lastupdated + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Last Accessed1
-enLast Accessed1
-ja最終アクセス日時2
+
869labels.user_info_edit_code + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User ID1
-enUser ID1
-ja利用者ID2
+
870labels.user_info_edit_createddate + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Created1
-enCreated1
-ja初回アクセス日時2
+
871labels.user_info_edit_lastupdated + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Last Accessed1
-enLast Accessed1
-ja最終アクセス日時2
+
872labels.user_info_delete_all_link + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete All1
-enDelete All1
-jaすべて削除2
+
873labels.user_info_delete_all_confirmation + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Do you want to delete all?1
-enDo you want to delete all?1
-ja削除しますか?2
+
874labels.favorite_log_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Popular URL1
-enPopular URL1
-ja人気URL2
+
875labels.favorite_log_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Popular URL1
-enPopular URL1
-ja人気URL2
+
876labels.favorite_log_user_code_search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--User ID1
-enUser ID1
-ja利用者ID2
+
877labels.favorite_log_button_search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search1
-enSearch1
-ja検索2
+
878labels.favorite_log_button_reset + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reset1
-enReset1
-jaリセット2
+
879labels.favorite_log_url + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--URL1
-enURL1
-jaURL1
+
880labels.favorite_log_created_time + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Submitted1
-enSubmitted1
-ja登録時刻2
+
881labels.favorite_log_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
882labels.favorite_log_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
883labels.favorite_log_delete_all_link + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete All1
-enDelete All1
-jaすべて削除2
+
884labels.favorite_log_delete_all_confirmation + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Do you want to delete it?1
-enDo you want to delete it?1
-ja削除しますか?2
+
885labels.favorite_log_download_csv + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download (CSV)1
-enDownload (CSV)1
-jaダウンロード(CSV)2
+
886labels.favorite_log_search_term + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Term1
-enTerm1
-ja期間2
+
887labels.favorite_log_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja人気URL詳細2
+
888labels.favorite_log_id + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--ID1
-enID1
-jaID1
+
889labels.scheduledjob_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Managed Jobs1
-enManaged Jobs1
-jaジョブ管理2
+
890labels.scheduledjob_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Jobs1
-enJobs1
-jaジョブ2
+
891labels.scheduledjob_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
892labels.scheduledjob_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-ja名前2
+
893labels.scheduledjob_target + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Target1
-enTarget1
-ja対象2
+
894labels.scheduledjob_status + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Status1
-enStatus1
-ja状態2
+
895labels.scheduledjob_cronExpression + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Schedule1
-enSchedule1
-jaスケジュール2
+
896labels.scheduledjob_scriptType + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Executor1
-enExecutor1
-ja実行方法2
+
897labels.scheduledjob_scriptData + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Script1
-enScript1
-jaスクリプト2
+
898labels.scheduledjob_jobLogging + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Logging1
-enLogging1
-jaログ2
+
899labels.scheduledjob_crawler + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Crawler Job1
-enCrawler Job1
-jaクロールジョブ2
+
900labels.scheduledjob_running + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Running1
-enRunning1
-ja実行中2
+
901labels.scheduledjob_active + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Active1
-enActive1
-ja有効2
+
902labels.scheduledjob_nojob + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
---1
-en-1
-ja-1
+
903labels.scheduledjob_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Job1
-enConfirm Job1
-jaジョブの確認2
+
904labels.scheduledjob_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
905labels.scheduledjob_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
906labels.scheduledjob_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
907labels.scheduledjob_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
908labels.scheduledjob_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
909labels.scheduledjob_button_start + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start1
-enStart1
-ja開始2
+
910labels.scheduledjob_button_stop + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Stop1
-enStop1
-ja停止2
+
911labels.scheduledjob_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
912labels.scheduledjob_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
913labels.scheduledjob_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
914labels.scheduledjob_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
915labels.scheduledjob_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja確認2
+
916labels.scheduledjob_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
917labels.scheduledjob_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
918labels.scheduledjob_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
919labels.scheduledjob_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
920labels.scheduledjob_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
921labels.joblog_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
922labels.joblog_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
923labels.joblog_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
924labels.joblog_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
925labels.joblog_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
926labels.joblog_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Job Log1
-enJob Log1
-jaジョブログ2
+
927labels.joblog_endTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--End Time1
-enEnd Time1
-ja完了時刻2
+
928labels.joblog_jobLogging + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Job Log1
-enJob Log1
-ja女ブログ2
+
929labels.joblog_jobName + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-jaジョブ名2
+
930labels.joblog_jobStatus + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Status1
-enStatus1
-jaステータス2
+
931labels.joblog_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
932labels.joblog_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
933labels.joblog_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
934labels.joblog_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
935labels.joblog_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
936labels.joblog_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
937labels.joblog_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
938labels.joblog_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
939labels.joblog_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
940labels.joblog_scriptData + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Script1
-enScript1
-jaスクリプト2
+
941labels.joblog_scriptResult + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Result1
-enResult1
-ja結果2
+
942labels.joblog_scriptType + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Executor1
-enExecutor1
-ja実行方法2
+
943labels.joblog_startTime + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Start Time1
-enStart Time1
-ja開始時刻2
+
944labels.joblog_target + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Target1
-enTarget1
-ja対象2
+
945labels.joblog_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Job Log1
-enConfirm Job Log1
-jaジョブログの確認2
+
946labels.joblog_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Job Log Details1
-enJob Log Details1
-jaジョブログ詳細2
+
947labels.joblog_title_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Job Log List1
-enJob Log List1
-jaジョブログ一覧2
+
948labels.joblog_delete_all_link + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete All1
-enDelete All1
-jaすべて削除2
+
949labels.joblog_delete_all_confirmation + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Do you want to delete all?1
-enDo you want to delete all?1
-ja削除しますか?2
+
950labels.dict_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Dictionary List1
-enDictionary List1
-ja辞書一覧2
+
951labels.dict_list_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Dictionary List1
-enDictionary List1
-ja辞書一覧2
+
952labels.dict_list_link + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Dictionaries1
-enDictionaries1
-ja辞書一覧2
+
953labels.dictionary_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Name1
-enName1
-ja名前2
+
954labels.dictionary_type + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Type1
-enType1
-ja種類2
+
955labels.dict_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
956labels.dict_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
957labels.dict_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
958labels.dict_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
959labels.dict_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
960labels.dict_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
961labels.dict_synonym_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Synonym List1
-enSynonym List1
-ja同義語一覧2
+
962labels.dict_synonym_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Synonym List1
-enSynonym List1
-ja同義語一覧2
+
963labels.dict_synonym_list_link + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
964labels.dict_synonym_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
965labels.dict_synonym_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
966labels.dict_synonym_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
967labels.dict_synonym_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
968labels.dict_synonym_link_download + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download1
-enDownload1
-jaダウンロード2
+
969labels.dict_synonym_link_upload + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upload1
-enUpload1
-jaアップロード2
+
970labels.dict_synonym_source + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Source1
-enSource1
-ja変換元2
+
971labels.dict_synonym_target + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Target1
-enTarget1
-ja変換後2
+
972labels.dict_synonym_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
973labels.dict_synonym_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
974labels.dict_synonym_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
975labels.dict_synonym_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
976labels.dict_synonym_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
977labels.dict_synonym_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
978labels.dict_synonym_button_download + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download1
-enDownload1
-jaダウンロード2
+
979labels.dict_synonym_button_upload + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upload1
-enUpload1
-jaアップロード2
+
980labels.dict_synonym_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Synonym File1
-enSynonym File1
-ja同義語ファイル2
+
981labels.dict_userdict_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--UserDict List1
-enUserDict List1
-jaユーザー辞書一覧2
+
982labels.dict_userdict_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--UserDict List1
-enUserDict List1
-jaユーザー辞書一覧2
+
983labels.dict_userdict_list_link + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
984labels.dict_userdict_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
985labels.dict_userdict_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
986labels.dict_userdict_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
987labels.dict_userdict_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
988labels.dict_userdict_link_download + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download1
-enDownload1
-jaダウンロード2
+
989labels.dict_userdict_link_upload + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upload1
-enUpload1
-jaアップロード2
+
990labels.dict_userdict_token + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Token1
-enToken1
-jaトークン2
+
991labels.dict_userdict_segmentation + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Segmentation1
-enSegmentation1
-ja分割2
+
992labels.dict_userdict_reading + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reading1
-enReading1
-ja読み2
+
993labels.dict_userdict_pos + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--POS1
-enPOS1
-ja品詞2
+
994labels.dict_userdict_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
995labels.dict_userdict_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
996labels.dict_userdict_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
997labels.dict_userdict_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
998labels.dict_userdict_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
999labels.dict_userdict_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
1000labels.dict_userdict_button_download + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download1
-enDownload1
-jaダウンロード2
+
1001labels.dict_userdict_button_upload + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upload1
-enUpload1
-jaアップロード2
+
1002labels.dict_userdict_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--UserDict File1
-enUserDict File1
-jaユーザー辞書ファイル2
+
1003labels.boost_document_rule_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Doc Boost1
-enDoc Boost1
-jaドキュメントブースト2
+
1004labels.boost_document_rule_title_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Doc Boost1
-enDoc Boost1
-jaドキュメントブースト2
+
1005labels.boost_document_rule_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Doc Boost1
-enConfirm Doc Boost1
-jaドキュメントブーストの確認2
+
1006labels.boost_document_rule_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Doc Boost1
-enDoc Boost1
-jaドキュメントブースト2
+
1007labels.boost_document_rule_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
1008labels.boost_document_rule_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
1009labels.boost_document_rule_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
1010labels.boost_document_rule_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
1011labels.boost_document_rule_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
1012labels.boost_document_rule_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
1013labels.boost_document_rule_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja新規作成2
+
1014labels.boost_document_rule_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
1015labels.boost_document_rule_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
1016labels.boost_document_rule_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
1017labels.boost_document_rule_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
1018labels.boost_document_rule_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
1019labels.boost_document_rule_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
1020labels.boost_document_rule_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
1021labels.boost_document_rule_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
1022labels.boost_document_rule_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
1023labels.boost_document_rule_list_url_expr + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Condition1
-enCondition1
-ja条件2
+
1024labels.boost_document_rule_url_expr + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Condition1
-enCondition1
-ja条件2
+
1025labels.boost_document_rule_boost_expr + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Boost Expr1
-enBoost Expr1
-jaブースト値式2
+
1026labels.boost_document_rule_sort_order + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Sort Order1
-enSort Order1
-ja表示順2
+
1027labels.suggest_elevate_word_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Additional Word1
-enAdditional Word1
-ja追加候補2
+
1028labels.suggest_elevate_word_title_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Additional Word1
-enAdditional Word1
-ja追加候補2
+
1029labels.suggest_elevate_word_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Additional Word1
-enConfirm Additional Word1
-ja追加候補の確認2
+
1030labels.suggest_elevate_word_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Additional Word1
-enAdditional Word1
-ja追加候補2
+
1031labels.suggest_elevate_word_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
1032labels.suggest_elevate_word_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
1033labels.suggest_elevate_word_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
1034labels.suggest_elevate_word_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
1035labels.suggest_elevate_word_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
1036labels.suggest_elevate_word_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
1037labels.suggest_elevate_word_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja新規作成2
+
1038labels.suggest_elevate_word_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
1039labels.suggest_elevate_word_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
1040labels.suggest_elevate_word_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
1041labels.suggest_elevate_word_link_download + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download1
-enDownload1
-jaダウンロード2
+
1042labels.suggest_elevate_word_link_upload + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upload1
-enUpload1
-jaアップロード2
+
1043labels.suggest_elevate_word_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
1044labels.suggest_elevate_word_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
1045labels.suggest_elevate_word_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
1046labels.suggest_elevate_word_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
1047labels.suggest_elevate_word_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
1048labels.suggest_elevate_word_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
1049labels.suggest_elevate_word_button_download + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download1
-enDownload1
-jaダウンロード2
+
1050labels.suggest_elevate_word_button_upload + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upload1
-enUpload1
-jaアップロード2
+
1051labels.suggest_elevate_word_list_suggest_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Word1
-enWord1
-jaサジェスト候補2
+
1052labels.suggest_elevate_word_suggest_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Word1
-enWord1
-jaサジェスト候補2
+
1053labels.suggest_elevate_word_reading + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reading1
-enReading1
-ja読み2
+
1054labels.suggest_elevate_word_target_role + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Role1
-enRole1
-jaロール名2
+
1055labels.suggest_elevate_word_target_label + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Label1
-enLabel1
-jaラベル名2
+
1056labels.suggest_elevate_word_boost + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Boost1
-enBoost1
-jaブースト値2
+
1057labels.suggest_elevate_word_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Additional Word File1
-enAdditional Word File1
-ja追加候補ファイル2
+
1058labels.suggest_bad_word_configuration + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Bad Word1
-enBad Word1
-jaNGワード2
+
1059labels.suggest_bad_word_title_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Bad Word1
-enBad Word1
-jaNGワード2
+
1060labels.suggest_bad_word_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm Bad Word1
-enConfirm Bad Word1
-jaNGワードの確認2
+
1061labels.suggest_bad_word_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Bad Word1
-enBad Word1
-jaNGワード2
+
1062labels.suggest_bad_word_link_list + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--List1
-enList1
-ja一覧2
+
1063labels.suggest_bad_word_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
1064labels.suggest_bad_word_link_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
1065labels.suggest_bad_word_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
1066labels.suggest_bad_word_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Prev1
-enPrev1
-ja前へ2
+
1067labels.suggest_bad_word_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
1068labels.suggest_bad_word_link_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja新規作成2
+
1069labels.suggest_bad_word_link_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
1070labels.suggest_bad_word_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
1071labels.suggest_bad_word_link_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
1072labels.suggest_bad_word_link_download + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download1
-enDownload1
-jaダウンロード2
+
1073labels.suggest_bad_word_link_upload + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upload1
-enUpload1
-jaアップロード2
+
1074labels.suggest_bad_word_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
1075labels.suggest_bad_word_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
1076labels.suggest_bad_word_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
1077labels.suggest_bad_word_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
1078labels.suggest_bad_word_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
1079labels.suggest_bad_word_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
1080labels.suggest_bad_word_button_download + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Download1
-enDownload1
-jaダウンロード2
+
1081labels.suggest_bad_word_button_upload + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Upload1
-enUpload1
-jaアップロード2
+
1082labels.suggest_bad_word_list_suggest_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Bad Word1
-enBad Word1
-jaサジェスト候補2
+
1083labels.suggest_bad_word_suggest_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Bad Word1
-enBad Word1
-jaサジェスト候補2
+
1084labels.suggest_bad_word_target_role + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Role1
-enRole1
-jaロール名2
+
1085labels.suggest_bad_word_target_label + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Label1
-enLabel1
-jaラベル名2
+
1086labels.suggest_bad_word_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Bad Word File1
-enBad Word File1
-jaNGワードファイル2
+
1087labels.crud_button_create + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create1
-enCreate1
-ja作成2
+
1088labels.crud_button_update + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Update1
-enUpdate1
-ja更新2
+
1089labels.crud_button_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
1090labels.crud_button_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
1091labels.crud_button_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
1092labels.crud_button_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirm1
-enConfirm1
-ja確認2
+
1093labels.crud_button_search + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Search1
-enSearch1
-ja検索2
+
1094labels.crud_button_reset + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reset1
-enReset1
-jaリセット2
+
1095labels.crud_link_create_new + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Create New1
-enCreate New1
-ja新規作成2
+
1096labels.crud_link_delete + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Delete1
-enDelete1
-ja削除2
+
1097labels.crud_link_back + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja戻る2
+
1098labels.crud_link_edit + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Edit1
-enEdit1
-ja編集2
+
1099labels.crud_link_next_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Next1
-enNext1
-ja次へ2
+
1100labels.crud_link_prev_page + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Back1
-enBack1
-ja前へ2
+
1101labels.crud_title_details + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Details1
-enDetails1
-ja詳細2
+
1102labels.crud_title_confirm + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Confirmation1
-enConfirmation1
-ja確認2
+
1103labels.labelTypeIds + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--  1
-en  1
-ja  1
+
1104labels.webCrawlingConfigId + + + + + + + + + + + + + +
EnvLangPropertyuq
-enWeb Config Name1
+
1105labels.fileCrawlingConfigId + + + + + + + + + + + + + +
EnvLangPropertyuq
-enFS Config Name1
+
+

*uq: Unique No (same value, same No)

+

FessMessage (extends FessLabel)

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
No.Property KeyContents
1errors.front_header + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--<div class="alert"><button type="button" class="close" data-dismiss="alert">×</button>1
-en<div class="alert"><button type="button" class="close" data-dismiss="alert">×</button>1
-ja<div class="alert"><button type="button" class="close" data-dismiss="alert">×</button>1
+
2errors.front_footer + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--</div>1
-en</div>1
-ja</div>1
+
3errors.front_prefix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--<div>1
-en<div>1
-ja<div>1
+
4errors.front_suffix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--</div>1
-en</div>1
-ja</div>1
+
5errors.header + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--<div class="alert-message error">1
-en<div class="alert-message error">1
-ja<div class="alert-message error">1
+
6errors.footer + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--</div>1
-en</div>1
-ja</div>1
+
7errors.prefix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--<p>1
-en<p>1
-ja<p>1
+
8errors.suffix + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--</p>1
-en</p>1
-ja</p>1
+
9errors.invalid + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} is invalid.1
-en{0} is invalid.1
-ja{0}が不正です。2
+
10errors.maxlength + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} can not be greater than {1} characters.1
-en{0} can not be greater than {1} characters.1
-ja{0}の長さが最大値({1})を超えています。2
+
11errors.minlength + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} can not be less than {1} characters.1
-en{0} can not be less than {1} characters.1
-ja{0}の長さが最小値({1})未満です。2
+
12errors.maxbytelength + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} can not be greater than {1} bytes.1
-en{0} can not be greater than {1} bytes.1
-ja{0}のバイト長が最大値({1})を超えています。2
+
13errors.minbytelength + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} can not be less than {1} bytes.1
-en{0} can not be less than {1} bytes.1
-ja{0}のバイト長が最小値({1})未満です。2
+
14errors.range + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} is not in the range {1} through {2}.1
-en{0} is not in the range {1} through {2}.1
-ja{0}は{1}と{2}の間でなければいけません。2
+
15errors.required + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} is required.1
-en{0} is required.1
-ja{0}は必須です。2
+
16errors.byte + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} must be an byte.1
-en{0} must be an byte.1
-ja{0}はバイトでなければいけません。2
+
17errors.date + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} is not a date.1
-en{0} is not a date.1
-ja{0}は日付でなければいけません2
+
18errors.double + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} must be an double.1
-en{0} must be an double.1
-ja{0}は倍精度実数でなければいけません。2
+
19errors.float + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} must be an float.1
-en{0} must be an float.1
-ja{0}は単精度実数でなければいけません。2
+
20errors.integer + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} must be an integer.1
-en{0} must be an integer.1
-ja{0}は整数でなければいけません。2
+
21errors.long + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} must be an long.1
-en{0} must be an long.1
-ja{0}は長整数でなければいけません。2
+
22errors.short + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} must be an short.1
-en{0} must be an short.1
-ja{0}は短整数でなければいけません。2
+
23errors.creditcard + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} is not a valid credit card number.1
-en{0} is not a valid credit card number.1
-ja{0}はクレジットカード番号として不正です。2
+
24errors.email + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} is an invalid e-mail address.1
-en{0} is an invalid e-mail address.1
-ja{0}はメールアドレスとして不正です。2
+
25errors.url + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} is an invalid url (web address).1
-en{0} is an invalid url (web address).1
-ja{0}はURLとして不正です。2
+
26errors.cronexpression + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} is a invalid format.1
-en{0} is a invalid format.1
-ja{0}は正しいフォーマットではありません。2
+
27errors.uritype + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} is a invalid uri.1
-en{0} is a invalid uri.1
-ja{0}は正しい URI 形式ではありません。2
+
28errors.alphaDigitOnly + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} must be alphabet or digit only.1
-en{0} must be alphabet or digit only.1
-ja{0}は英数字でなければいけません。2
+
29errors.alphaDigitSpaceOnly + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} must be alphabet, digit, or space only.1
-en{0} must be alphabet, digit, or space only.1
-ja{0}は英数字または空白でなければいけません。2
+
30errors.token + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Invalid request.1
-enInvalid request.1
-ja不正なリクエストです。2
+
31errors.failed_to_update_crawler_params + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to update parameters. Please contact to a site administrator.1
-enFailed to update parameters. Please contact to a site administrator.1
-jaパラメータの更新に失敗しました。サイト管理者に連絡してください。2
+
32errors.failed_to_update_web_crawler_params + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to update parameters. Please contact to a site administrator.1
-enFailed to update parameters. Please contact to a site administrator.1
-jaパラメータの更新に失敗しました。サイト管理者に連絡してください。2
+
33errors.failed_to_update_solr_params + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to update parameters. Please contact to a site administrator.1
-enFailed to update parameters. Please contact to a site administrator.1
-jaパラメータの更新に失敗しました。サイト管理者に連絡してください。2
+
34error.login_error + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Username or Password is not correct.1
-enUsername or Password is not correct.1
-jaユーザー名またはパスワードが正しくありません。2
+
35errors.failed_to_commit_solr_index + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to commit index.1
-enFailed to commit index.1
-jaインデックスのコミットに失敗しました。2
+
36errors.failed_to_optimize_solr_index + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to optimize index.1
-enFailed to optimize index.1
-jaインデックスの最適化に失敗しました。2
+
37errors.failed_to_delete_solr_index + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to delete index.1
-enFailed to delete index.1
-jaインデックスの削除に失敗しました。2
+
38errors.failed_to_start_solr_process_because_of_running + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to start a process because of running solr process.1
-enFailed to start a process because of running solr process.1
-jaSolrプロセスが実行中なので、処理の起動に失敗しました。2
+
39errors.failed_to_import_data + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to restore data.1
-enFailed to restore data.1
-ja設定データのリストアに失敗しました。2
+
40errors.unknown_import_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Unknown file type.1
-enUnknown file type.1
-ja未知のファイル形式です。2
+
41errors.failed_to_export_data + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to backup data.1
-enFailed to backup data.1
-ja設定データのバックアップに失敗しました。2
+
42errors.could_not_find_log_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Could not find {0}.1
-enCould not find {0}.1
-ja{0}が見つかりません。2
+
43errors.no_running_crawl_process + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--No running crawl process.1
-enNo running crawl process.1
-ja実行中のプロセスがありません。2
+
44errors.failed_to_start_crawl_process + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to start a crawl process.1
-enFailed to start a crawl process.1
-jaクロールプロセスを開始できませんでした。2
+
45errors.invalid_design_jsp_file_name + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Invalid JSP file.1
-enInvalid JSP file.1
-jaJSPファイル名が正しくありません。2
+
46errors.design_jsp_file_does_not_exist + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--JSP file does not exist.1
-enJSP file does not exist.1
-jaJSPファイルが存在しません。2
+
47errors.design_file_name_is_not_found + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--The file name is not specified.1
-enThe file name is not specified.1
-jaファイル名が指定されていません。2
+
48errors.failed_to_write_design_image_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to upload an image file.1
-enFailed to upload an image file.1
-ja画像ファイルのアップロードにしっぱいしました。2
+
49errors.failed_to_update_jsp_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to update a jsp file.1
-enFailed to update a jsp file.1
-jaJSPファイルの更新に失敗しました。2
+
50errors.design_file_name_is_invalid + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--The file name is invalid.1
-enThe file name is invalid.1
-jaファイル名が正しくありません。2
+
51errors.design_file_is_unsupported_type + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--The kind of file is unsupported.1
-enThe kind of file is unsupported.1
-jaファイル名はサポートしていません。2
+
52errors.failed_to_start_solr_instance + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to start a solr instance.1
-enFailed to start a solr instance.1
-jaSolrインスタンスの起動に失敗しました。2
+
53errors.failed_to_stop_solr_instance + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to stop a solr instance.1
-enFailed to stop a solr instance.1
-jaSolrインスタンスの停止に失敗しました。2
+
54errors.failed_to_reload_solr_instance + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to reload a solr instance.1
-enFailed to reload a solr instance.1
-jaSolrインスタンスのリロードに失敗しました。2
+
55errors.failed_to_update_crawler_schedule + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to update a crawling schedule.1
-enFailed to update a crawling schedule.1
-jaクロールスケジュールの更新に失敗しました。2
+
56errors.failed_to_create_crawling_config_at_wizard + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to create a crawling config.1
-enFailed to create a crawling config.1
-jaクロール設定の作成に失敗しました。2
+
57errors.design_editor_disabled + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--This feature is disabled.1
-enThis feature is disabled.1
-jaこの機能は無効になっています。2
+
58errors.could_not_create_search_log_csv + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Could not create a search log csv file.1
-enCould not create a search log csv file.1
-ja検索ログのCSVファイルを作成できませんでした。2
+
59errors.not_found_on_file_system + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Not Found: {0}1
-enNot Found: {0}1
-ja{0} は見つかりません。2
+
60errors.could_not_open_on_system + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Could not open {0}. <br/>Please check if the file is associated with an application.1
-enCould not open {0}. <br/>Please check if the file is associated with an application.1
-ja{0}は開けませんでした。<br/>アプリケーションに関連付けられているか確認してください。2
+
61errors.process_time_is_exceeded + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--The limit of a search time was exceeded. The partial result was displayed.1
-enThe limit of a search time was exceeded. The partial result was displayed.1
-ja検索処理時間の上限を超えたため、検索結果の一部が表示されています。2
+
62errors.result_size_exceeded + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--No more results could be displayed.1
-enNo more results could be displayed.1
-jaこれ以上の検索結果の表示はできません。2
+
63errors.target_file_does_not_exist + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} file does not exist.1
-en{0} file does not exist.1
-jaファイル {0} が存在しません。2
+
64errors.failed_to_download_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to download {0} file.1
-enFailed to download {0} file.1
-ja{0} のダウンロードに失敗しました。2
+
65errors.failed_to_delete_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to delete {0} file.1
-enFailed to delete {0} file.1
-jaファイル {0} の削除に失敗しました。2
+
66errors.failed_to_redirect + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to redirect {0}.1
-enFailed to redirect {0}.1
-ja{0}へのリダイレクトに失敗しました。2
+
67errors.unsupported_encoding + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--{0} is not supported as encoding.1
-en{0} is not supported as encoding.1
-ja{0}はサポートされていないエンコーディングです。2
+
68errors.docid_not_found + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Not found Doc ID:{0}1
-enNot found Doc ID:{0}1
-jaID:{0}が見つかりません。2
+
69errors.document_not_found + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Not found URL of Doc ID:{0}1
-enNot found URL of Doc ID:{0}1
-jaID:{0}のURLが見つかりません。2
+
70errors.not_load_from_server + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Could not load from this server: {0}1
-enCould not load from this server: {0}1
-jaこのサーバからロードすることができませんでした: {0}2
+
71errors.failed_to_start_job + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to start job {0}.1
-enFailed to start job {0}.1
-jaジョブ {0} の開始に失敗しました。2
+
72errors.failed_to_stop_job + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to stop job {0}.1
-enFailed to stop job {0}.1
-jaジョブ {0} の開始に失敗しました。2
+
73errors.expired_dict_id + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Expired dictionary information. Please reload it.1
-enExpired dictionary information. Please reload it.1
-ja辞書情報が期限切れです。再度読みなおしてください。2
+
74errors.failed_to_create_cache + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to create a cache reponse for ID:{0}.1
-enFailed to create a cache reponse for ID:{0}.1
-jaID:{0}のキャッシュが生成できませんでした。2
+
75errors.synonym_file_is_not_found + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Synonym file is not found1
-enSynonym file is not found1
-ja同義語ファイルが見つかりません。2
+
76errors.failed_to_download_synonym_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to download the Synonym file.1
-enFailed to download the Synonym file.1
-ja同義語ファイルのダウンロードに失敗しました。2
+
77errors.failed_to_upload_synonym_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to upload the Synonym file.1
-enFailed to upload the Synonym file.1
-ja同義語ファイルのアップロードに失敗しました。2
+
78errors.userdict_file_is_not_found + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Synonym file is not found1
-enSynonym file is not found1
-jaユーザー辞書ファイルが見つかりません。2
+
79errors.failed_to_download_userdict_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to download the UserDict file.1
-enFailed to download the UserDict file.1
-jaユーザー辞書ファイルのダウンロードに失敗しました。2
+
80errors.failed_to_upload_userdict_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to upload the UserDict file.1
-enFailed to upload the UserDict file.1
-jaユーザー辞書ファイルのアップロードに失敗しました。2
+
81errors.invalid_query_unknown + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--The given query is invalid.1
-enThe given query is invalid.1
-ja検索クエリが正しくありません。2
+
82errors.invalid_query_quoted + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--An invalid quote character is used.1
-enAn invalid quote character is used.1
-jaクオート文字(")の利用方法が正しくありません。2
+
83errors.invalid_query_curly_bracket + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--An invalid curly bracket character is used.1
-enAn invalid curly bracket character is used.1
-ja括弧「'{}'」の利用方法が正しくありません。2
+
84errors.invalid_query_square_bracket + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--An invalid square bracket character is used.1
-enAn invalid square bracket character is used.1
-ja括弧「[]」の利用方法が正しくありません。2
+
85errors.invalid_query_parenthesis + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--An invalid parenthesis character is used.1
-enAn invalid parenthesis character is used.1
-ja括弧「()」の利用方法が正しくありません。2
+
86errors.invalid_query_num_range + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--An invalid range is used. The example of the range format is "field:[20020101 TO 20030101]".1
-enAn invalid range is used. The example of the range format is "field:[20020101 TO 20030101]".1
-ja範囲の指定が正しくありません。正しい例: field:[20020101 TO 20030101]2
+
87errors.invalid_query_str_range + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--An invalid range is used. The example of the range format is "field:'{'Aida TO Carmen'}'".1
-enAn invalid range is used. The example of the range format is "field:'{'Aida TO Carmen'}'".1
-ja範囲の指定が正しくありません。正しい例: "field:'{'Aida TO Carmen'}'"2
+
88success.update_crawler_params + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Updated parameters.1
-enUpdated parameters.1
-jaパラメータを更新しました。2
+
89success.update_web_crawler_params + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Updated parameters.1
-enUpdated parameters.1
-jaパラメータを更新しました。2
+
90success.update_solr_params + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Updated parameters.1
-enUpdated parameters.1
-jaパラメータを更新しました。2
+
91success.commit_solr_index + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Started a process to commit index.1
-enStarted a process to commit index.1
-jaインデックスのコミットプロセスを開始しました。2
+
92success.optimize_solr_index + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Started a process to optimize index.1
-enStarted a process to optimize index.1
-jaインデックスの最適化プロセスを開始しました。2
+
93success.delete_solr_index + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Started a process to optimize index.1
-enStarted a process to optimize index.1
-jaインデックスの削除プロセスを開始しました。2
+
94success.importing_data + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Started to restore data from the uploaded file.1
-enStarted to restore data from the uploaded file.1
-jaアップロードされたファイルからのデータリストアを開始しました。2
+
95success.crawling_session_delete_all + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Deleted session data.1
-enDeleted session data.1
-jaセッションデータを削除しました。2
+
96success.start_crawl_process + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Started a crawl process.1
-enStarted a crawl process.1
-jaクロールプロセスを開始しました。2
+
97success.stopping_crawl_process + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Stopping a crawl process.1
-enStopping a crawl process.1
-jaクロールプロセスを停止しています。しばらくお待ちください。2
+
98success.upload_design_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Uploaded {0}.1
-enUploaded {0}.1
-ja{0} をアップロードしました。2
+
99success.update_design_jsp_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Updated {0}.1
-enUpdated {0}.1
-ja{0} を更新しました。2
+
100success.starting_solr_instance + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Starting a solr instance.1
-enStarting a solr instance.1
-jaSolrインスタンスを起動しています。2
+
101success.stopping_solr_instance + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Stopping a solr instance.1
-enStopping a solr instance.1
-jaSolrインスタンスを停止しています。2
+
102success.reloading_solr_instance + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reloading a solr instance.1
-enReloading a solr instance.1
-jaSolrインスタンスをリロードしています。2
+
103success.update_crawler_schedule + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Updated a crawling schedule.1
-enUpdated a crawling schedule.1
-jaクロールスケジュールを更新しました。2
+
104success.create_crawling_config_at_wizard + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Created a crawling config ({0}).1
-enCreated a crawling config ({0}).1
-jaクロール設定 {0} を追加しました。2
+
105success.search_log_delete_all + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Deleted search logs.1
-enDeleted search logs.1
-ja検索ログを削除しました。2
+
106success.failure_url_delete_all + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Deleted failure urls.1
-enDeleted failure urls.1
-ja障害URLを削除しました。2
+
107success.delete_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Deleted {0} file.1
-enDeleted {0} file.1
-jaファイル {0} を削除しました。2
+
108success.user_info_delete_all + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Deleted user information.1
-enDeleted user information.1
-ja利用者情報を削除しました。2
+
109success.favorite_log_delete_all + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Deleted popular urls1
-enDeleted popular urls1
-ja人気URLを削除しました。2
+
110success.job_started + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Started job {0}.1
-enStarted job {0}.1
-jaジョブ {0} を開始しました。2
+
111success.job_stopped + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Stopped job {0}.1
-enStopped job {0}.1
-jaジョブ {0} を停止しました。2
+
112success.joblog_delete_all + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Deleted job logs.1
-enDeleted job logs.1
-jaジョブログを削除しました。2
+
113success.upload_synonym_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Uploaded Synonym file.1
-enUploaded Synonym file.1
-ja同義語ファイルをアップロードしました。2
+
114success.upload_userdict_file + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Uploaded UserDict file.1
-enUploaded UserDict file.1
-jaユーザー辞書ファイルをアップロードしました。2
+
115success.upload_suggest_elevate_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Uploaded Additional Word file.1
-enUploaded Additional Word file.1
-ja追加候補ファイルをアップロードしました。2
+
116success.upload_suggest_bad_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Uploaded Bad Word file.1
-enUploaded Bad Word file.1
-jaNGワードファイルをアップロードしました。2
+
117label.facet_label_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Label1
-enLabel1
-jaラベル2
+
118label.facet_lastModified_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Term1
-enTerm1
-ja期間2
+
119label.facet_lastModified_1day + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Past 24 Hours1
-enPast 24 Hours1
-ja24 時間以内2
+
120label.facet_lastModified_1week + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Past Week1
-enPast Week1
-ja1 週間以内2
+
121label.facet_lastModified_1month + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Past Month1
-enPast Month1
-ja1 ヶ月以内2
+
122label.facet_lastModified_1year + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Past Year1
-enPast Year1
-ja1 年以内2
+
123label.facet_contentLength_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Size1
-enSize1
-jaサイズ2
+
124label.facet_contentLength_10k + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--  - 10kb1
-en  - 10kb1
-ja  - 10KB2
+
125label.facet_contentLength_10kto100k + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--10kb - 100kb1
-en10kb - 100kb1
-ja10KB - 100KB2
+
126label.facet_contentLength_100kto500k + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--100kb - 500kb1
-en100kb - 500kb1
-ja100KB - 500KB2
+
127label.facet_contentLength_500kto1m + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--500kb - 1mb1
-en500kb - 1mb1
-ja500KB - 1MB2
+
128label.facet_contentLength_1m + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--1mb -  1
-en1mb -  1
-ja1MB -  2
+
129label.facet_filetype_title + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--File Type1
-enFile Type1
-jaファイルの種類2
+
130label.facet_filetype_html + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--HTML1
-enHTML1
-jaHTML1
+
131label.facet_filetype_word + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Word1
-enWord1
-jaWord1
+
132label.facet_filetype_excel + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Excel1
-enExcel1
-jaExcel1
+
133label.facet_filetype_powerpoint + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--PowerPoint1
-enPowerPoint1
-jaPowerPoint1
+
134label.facet_filetype_pdf + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--PDF1
-enPDF1
-jaPDF1
+
135label.facet_filetype_others + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--PDF1
-enPDF1
-jaその他2
+
136label.facet_label_reset + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Reset1
-enReset1
-jaリセット2
+
137errors.crud_invalid_mode + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Invalid mode(expected value is {0}, but it's {1}).1
-enInvalid mode(expected value is {0}, but it's {1}).1
-jaモードが違います。(正しい値は {0} ですが、入力された値は {1} になっています)2
+
138errors.crud_failed_to_create_crud_table + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to create a new data.1
-enFailed to create a new data.1
-jaデータの作成に失敗しました。2
+
139errors.crud_failed_to_update_crud_table + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to update the data.1
-enFailed to update the data.1
-jaデータの更新に失敗しました。2
+
140errors.crud_failed_to_delete_crud_table + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Failed to delete the data.1
-enFailed to delete the data.1
-jaデータの削除に失敗しました。2
+
141errors.crud_could_not_find_crud_table + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Could not find the data({0}).1
-enCould not find the data({0}).1
-jaデータ {0} が見つかりません。2
+
142success.crud_create_crud_table + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Created data.1
-enCreated data.1
-jaデータを作成しました。2
+
143success.crud_update_crud_table + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Updated data.1
-enUpdated data.1
-jaデータを更新しました。2
+
144success.crud_delete_crud_table + + + + + + + + + + + + + + + + + + + + + + + + + +
EnvLangPropertyuq
--Deleted data.1
-enDeleted data.1
-jaデータを削除しました。2
+
+

*uq: Unique No (same value, same No)

+ +

Thanks

+

+ Created by DBFlute(AutoGenerator) +

+ + diff --git a/dbflute_fess/output/doc/schema-fess.html b/dbflute_fess/output/doc/schema-fess.html new file mode 100644 index 000000000..a2b35857e --- /dev/null +++ b/dbflute_fess/output/doc/schema-fess.html @@ -0,0 +1,864 @@ + + + + + fess schema + + + + +

Schema for fess (h2)

+

generated from DUMMYDB.PUBLIC

+ + +

Table List

+
+ +
    + *Push 'tab' (primary tab order) +
    + + + + + + + + + + + + + + + + + + + + + +
    No.NameTypeForeignTableReferrerTableEntityName
    1DUMMY_MEMBERTABLE  DummyMember
    + +

    +DUMMY_MEMBER +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    No.PKIDUQIXNot
    Null
    NameTypeSizeForeignTableReferrerTableClassificationPropertyNameJavaType
    1oo  *MEMBER_IDINTEGER 10      memberIdInteger
    2     *MEMBER_NAMEVARCHAR 200      memberNameString
    3     *MEMBER_ACCOUNTVARCHAR 50      memberAccountString
    4     *MEMBER_STATUS_CODECHAR 3      memberStatusCodeString
    5       FORMALIZED_DATETIMETIMESTAMP 23, 10      formalizedDatetimeLocalDateTime
    6       BIRTHDATEDATE 8      birthdateLocalDate
    7     *REGISTER_DATETIMETIMESTAMP 23, 10      registerDatetimeLocalDateTime
    8     *REGISTER_USERVARCHAR 200      registerUserString
    9     *UPDATE_DATETIMETIMESTAMP 23, 10      updateDatetimeLocalDateTime
    10     *UPDATE_USERVARCHAR 200      updateUserString
    11     *VERSION_NOBIGINT 19      versionNoLong
    + + + +

    Thanks

    +

    + Created by DBFlute(AutoGenerator) +

    + + + diff --git a/dbflute_fess/output/lasta/fess-lastadoc.html b/dbflute_fess/output/lasta/fess-lastadoc.html new file mode 100644 index 000000000..391222003 --- /dev/null +++ b/dbflute_fess/output/lasta/fess-lastadoc.html @@ -0,0 +1,66 @@ + + + + + fess lasta_doc + + + +/ :: RootAction
    +/admin/ :: AdminAction
    +/dict/ :: DictAction
    +/admin/boostdocumentrule/ :: AdminBoostdocumentruleAction
    +/admin/crawl/ :: AdminCrawlAction
    +/admin/crawlingsession/ :: AdminCrawlingsessionAction
    +/admin/dataconfig/ :: AdminDataconfigAction
    +/admin/design/ :: AdminDesignAction
    +/synonym/ :: SynonymAction
    +/user/dict/ :: UserDictAction
    +/admin/failureurl/ :: AdminFailureurlAction
    +/admin/fileauthentication/ :: AdminFileauthenticationAction
    +/admin/fileconfig/ :: AdminFileconfigAction
    +/admin/group/ :: AdminGroupAction
    +/admin/joblog/ :: AdminJoblogAction
    +/admin/keymatch/ :: AdminKeymatchAction
    +/admin/labeltype/ :: AdminLabeltypeAction
    +/admin/log/ :: AdminLogAction
    +/admin/overlappinghost/ :: AdminOverlappinghostAction
    +/admin/pathmapping/ :: AdminPathmappingAction
    +/admin/requestheader/ :: AdminRequestheaderAction
    +/admin/role/ :: AdminRoleAction
    +/admin/roletype/ :: AdminRoletypeAction
    +/admin/scheduledjob/ :: AdminScheduledjobAction
    +/admin/searchlist/ :: AdminSearchlistAction
    +/admin/suggestbadword/ :: AdminSuggestbadwordAction
    +/admin/suggestelevateword/ :: AdminSuggestelevatewordAction
    +/admin/system/ :: AdminSystemAction
    +/admin/systeminfo/ :: AdminSysteminfoAction
    +/admin/user/ :: AdminUserAction
    +/admin/webauthentication/ :: AdminWebauthenticationAction
    +/admin/webconfig/ :: AdminWebconfigAction
    +/admin/wizard/ :: AdminWizardAction
    +/fess/admin/ :: FessAdminAction
    +/fess/base/ :: FessBaseAction
    +/fess/search/ :: FessSearchAction
    +/cache/ :: CacheAction
    +/error/ :: ErrorAction
    +/go/ :: GoAction
    +/help/ :: HelpAction
    +/login/ :: LoginAction
    +/logout/ :: LogoutAction
    +/osdd/ :: OsddAction
    +/screenshot/ :: ScreenshotAction
    +/search/ :: SearchAction
    + + diff --git a/dbflute_fess/playsql/replace-schema.sql b/dbflute_fess/playsql/replace-schema.sql index 0519ecba6..ba119345d 100644 --- a/dbflute_fess/playsql/replace-schema.sql +++ b/dbflute_fess/playsql/replace-schema.sql @@ -1 +1,14 @@ - \ No newline at end of file + +create table DUMMY_MEMBER( + MEMBER_ID INTEGER IDENTITY NOT NULL PRIMARY KEY, + MEMBER_NAME VARCHAR(200) NOT NULL, + MEMBER_ACCOUNT VARCHAR(50) NOT NULL, + MEMBER_STATUS_CODE CHAR(3) NOT NULL, + FORMALIZED_DATETIME DATETIME, + BIRTHDATE DATE, + REGISTER_DATETIME DATETIME NOT NULL, + REGISTER_USER VARCHAR(200) NOT NULL, + UPDATE_DATETIME DATETIME NOT NULL, + UPDATE_USER VARCHAR(200) NOT NULL, + VERSION_NO BIGINT NOT NULL +); \ No newline at end of file diff --git a/dbflute_fess/schema/project-schema-fess.xml b/dbflute_fess/schema/project-schema-fess.xml new file mode 100644 index 000000000..7aee07788 --- /dev/null +++ b/dbflute_fess/schema/project-schema-fess.xml @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + +
    + + + +
    diff --git a/pom.xml b/pom.xml index fa2c267d3..377f93e3e 100644 --- a/pom.xml +++ b/pom.xml @@ -1,707 +1,654 @@ - - 4.0.0 - org.codelibs.fess - fess - 10.0.0-SNAPSHOT - war - Fess - Fess is Full tExt Search System. - http://fess.codelibs.org/ - 2009 - - - The Apache Software License, Version 2.0 - http://www.apache.org/licenses/LICENSE-2.0.txt - repo - - - - CodeLibs - http://www.codelibs.org/ - - - https://github.com/codelibs/fess/issues - - - scm:git:git@github.com:codelibs/fess.git - scm:git:git@github.com:codelibs/fess.git - https://github.com/codelibs/fess - - - org.sonatype.oss - oss-parent - 9 - - - UTF-8 - 1.1.0-sp1 - 0.8.0 - 1.7.7 - 1.6 - 3.11-beta2 - 1.8.7 - 1.0.0-SNAPSHOT - 1.6.0 - 1.6.0.0 - - true - true - UTF-8 - ${basedir}/src/test/resources/tomcat-users.xml - https://oss.sonatype.org/content/repositories/snapshots - http://central.maven.org/maven2 - - - fess - - - src/main/resources - - - - - maven-compiler-plugin - 3.2 - - 1.8 - 1.8 - UTF-8 - - - - maven-source-plugin - 2.4 - - - source-jar - package - - jar - - - - - - maven-war-plugin - 2.6 - - - - ${project.build.directory}/${project.build.finalName}-compress - - - WEB-INF/classes/**/*.*,WEB-INF/lib/*.jar - - - - com.mycila.maven-license-plugin - maven-license-plugin - 1.10.b1 - - - - format - - - - -
    ${basedir}/src/etc/header.txt
    - - src/**/*.java - - UTF-8 - - ${basedir}/src/etc/header-definition.xml - -
    -
    - - net.revelc.code - formatter-maven-plugin - 0.5.2 - - - - format - - - - - ${basedir}/src/config/eclipse/formatter/java.xml - - - - maven-javadoc-plugin - 2.10.1 - - UTF-8 - UTF-8 - UTF-8 - - http://docs.oracle.com/javase/7/docs/api/ - http://docs.oracle.com/javaee/6/api/ - http://aopalliance.sourceforge.net/doc/ - http://www.csg.is.titech.ac.jp/~chiba/javassist/html/ - http://s2container.seasar.org/2.4/s2-framework/ja/apidocs/ - http://s2container.seasar.org/2.4/s2-extension/ja/apidocs/ - http://s2container.seasar.org/2.4/s2-tiger/ja/apidocs/ - http://s2robot.sandbox.seasar.org/apidocs/ - - - - - net.alchim31.maven - yuicompressor-maven-plugin - 1.5.1 - - - compile - - compress - jslint - - - - - true - ${project.build.directory}/${project.build.finalName}-compress - - **/*min.js - - - - - org.codelibs - tomcat8-maven-plugin - 3.0-SNAPSHOT - - - org.dbflute - dbflute-maven-plugin - 1.1.0 - - ${dbflute.version} - org.codelibs.fess.db - fess - ${basedir}/dbflute_fess - - - - maven-antrun-plugin - 1.8 - - - org.apache.ant - ant - 1.9.6 - - - - - - - - - - - - - - - - - run - - -
    -
    - - - codelibs.org - CodeLibs Repository - http://maven.codelibs.org/ - - - maven.seasar.org - The Seasar Foundation Maven2 Repository - http://maven.seasar.org/maven2/ - - - maven-snapshot.seasar.org - The Seasar Foundation Maven2 Repository - http://maven.seasar.org/maven2-snapshot/ - - - oss.sonatype.org - oss.sonatype.org - http://oss.sonatype.org/content/groups/public/ - - - - - codelibs.org - CodeLibs Repository - http://maven.codelibs.org/ - - - oss.sonatype.org - oss.sonatype.org - http://oss.sonatype.org/content/groups/public/ - - - - maven.seasar.org - The Seasar Foundation Maven2 Repository - http://maven.seasar.org/maven2/ - - - maven-snapshot.seasar.org - The Seasar Foundation Maven2 Repository - http://maven.seasar.org/maven2-snapshot/ - - - java.net - Repository hosting the jee6 artifacts - http://download.java.net/maven/2 - - - orangesignal.sourceforge.jp - OrangeSignal Repository - http://orangesignal.sourceforge.jp/maven2/ - - - - - jstl - jstl - 1.1.2 - - - taglibs - standard - 1.1.2 - - - com.google.guava - guava - 17.0 - - - commons-codec - commons-codec - 1.9 - - - commons-collections - commons-collections - 3.2.1 - - - commons-beanutils - commons-beanutils - 1.8.3 - - - commons-el - commons-el - 1.0 - - - commons-fileupload - commons-fileupload - 1.2.2.1 - - - commons-httpclient - commons-httpclient - 3.1 - test - - - commons-io - commons-io - 2.4 - - - commons-lang - commons-lang - 2.6 - - - commons-logging - commons-logging - 1.1.1 - provided - - - commons-validator - commons-validator - 1.2.0 - - - xml-apis - xml-apis - - - - - org.slf4j - jcl-over-slf4j - ${slf4j.version} - - - org.slf4j - slf4j-api - ${slf4j.version} - - - org.slf4j - slf4j-log4j12 - ${slf4j.version} - - - org.elasticsearch - elasticsearch - ${elasticsearch.version} - - - org.codelibs - elasticsearch-cluster-runner - ${cluster.runner.version} - - - xalan - xalan - 2.7.1 - - - xml-apis - xml-apis - - - - - - org.seasar.container - s2-tiger - 2.4.46 - - - jboss - javassist - - - - - org.seasar.cms.s2-classbuilder - s2-classbuilder - 0.0.11 - - - org.seasar.container - s2-framework - - - org.seasar.container - s2-extension - - - - - org.codelibs.struts - cl-struts - 1.2.9.1 - - - org.dbflute.saflute - saflute - ${saflute.version} - - - s2chronos-extension - org.seasar.chronos - - - s2chronos-core - org.seasar.chronos - - - dbflute-runtime - org.dbflute - - - struts - struts - - - javassist - jboss - - - - - org.codelibs - corelib - 0.3.0 - - - org.codelibs.sastruts - sastruts-html5 - 0.1.0 - - - org.codelibs.robot - s2-robot-db-h2 - ${s2robot.version} - - - xml-apis - xml-apis - - - - - org.codelibs.robot - s2-robot-db - ${s2robot.version} - - - org.dbflute - dbflute-runtime - ${dbflute.version} - - - org.quartz-scheduler - quartz - 2.2.1 - - - - org.apache.geronimo.specs - geronimo-annotation_1.0_spec - 1.0 - - - org.apache.geronimo.specs - geronimo-ejb_3.0_spec - 1.0 - - - org.apache.geronimo.specs - geronimo-interceptor_3.0_spec - 1.0 - - - org.apache.geronimo.specs - geronimo-jta_1.1_spec - 1.0 - - - org.apache.geronimo.specs - geronimo-jpa_3.0_spec - 1.0 - - - - javax.servlet - javax.servlet-api - 3.0.1 - provided - - - javax.servlet.jsp - jsp-api - 2.2 - provided - - - com.sun.mail - javax.mail - 1.5.2 - - - javax.activation - activation - 1.1.1 - - - jp.sf.orangesignal - orangesignal-csv - 1.3.1 - - - - org.mortbay.jetty - jetty - 6.1.20 - test - - - org.mortbay.jetty - servlet-api - - - - - xerces - xercesImpl - 2.8.1 - - - xml-apis - xml-apis - - - - - org.bouncycastle - bcprov-jdk15on - 1.51 - - - org.bouncycastle - bcmail-jdk15on - 1.51 - - - args4j - args4j - 2.0.29 - - - org.apache.tika - tika-core - ${tika.version} - - - org.apache.tika - tika-parsers - ${tika.version} - - - com.uwyn - jhighlight - - - org.bouncycastle - bcprov-jdk15 - - - org.bouncycastle - bcmail-jdk15 - - - - - org.codelibs - jhighlight - 1.0.1 - - - com.ibm.icu - icu4j - 53.1 - - - org.apache.pdfbox - pdfbox - ${pdfbox.version} - - - org.apache.poi - poi - ${poi.version} - - - org.apache.poi - poi-ooxml - ${poi.version} - - - xml-apis - xml-apis - - - - - org.apache.poi - poi-scratchpad - ${poi.version} - - - org.javassist - javassist - 3.18.2-GA - - - net.arnx - jsonic - 1.3.5 - - - com.github.jknack - handlebars - 1.3.1 - - - org.codehaus.groovy - groovy-all - 2.3.6 - - - com.github.detro - phantomjsdriver - 1.2.0 - - - selenium-chrome-driver - org.seleniumhq.selenium - - - selenium-htmlunit-driver - org.seleniumhq.selenium - - - selenium-firefox-driver - org.seleniumhq.selenium - - - selenium-ie-driver - org.seleniumhq.selenium - - - selenium-safari-driver - org.seleniumhq.selenium - - - webbit - org.webbitserver - - - org.apache.httpcomponents - httpclient - - - - - - junit - junit - 3.8.2 - test - - - org.easymock - easymock - 2.2 - test - - - org.dbflute.utflute - utflute-seasar - 0.5.0-sp1 - test - - + + 4.0.0 + org.codelibs.fess + fess + 10.0.0-SNAPSHOT + war + Fess + Fess is Full tExt Search System. + http://fess.codelibs.org/ + 2009 + + + The Apache Software License, Version 2.0 + http://www.apache.org/licenses/LICENSE-2.0.txt + repo + + + + CodeLibs + http://www.codelibs.org/ + + + https://github.com/codelibs/fess/issues + + + scm:git:git@github.com:codelibs/fess.git + scm:git:git@github.com:codelibs/fess.git + https://github.com/codelibs/fess + + + org.sonatype.oss + oss-parent + 9 + + + UTF-8 + + + 1.1.0-sp8 + 0.6.4 + 0.6.0 + 3.1.0 + 2.3.1 + + + 1.7.12 + 1.1.3 + + + 1.3.1 + + + 4.8.2 + 0.5.1-RC2 + + + 1.0.0-SNAPSHOT + 1.6 + 3.11-beta2 + 1.8.7 + + + 1.7.2 + 1.7.0.0 + + + 0.3.7 + + + https://oss.sonatype.org/content/repositories/snapshots + http://central.maven.org/maven2 + + + fess + + + src/main/resources + + + + + + org.eclipse.m2e + lifecycle-mapping + 1.0.0 + + + + + + org.apache.maven.plugins + maven-dependency-plugin + [0,) + + unpack-dependencies + + + + + + + + + + + + + + + maven-compiler-plugin + 3.2 + + 1.8 + 1.8 + UTF-8 + + + + maven-source-plugin + 2.4 + + + source-jar + package + + jar + + + + + + maven-war-plugin + 2.6 + + + + ${project.build.directory}/${project.build.finalName}-compress + + + + + + org.apache.maven.plugins + maven-dependency-plugin + + + unpack-provided + generate-resources + + unpack-dependencies + + + provided + ${project.build.directory}/tomcat-lib + **/* + true + true + + + + + + org.apache.maven.plugins + maven-assembly-plugin + 2.5.5 + + ${project.artifactId}-${project.version} + false + ${project.build.directory}/releases/ + + ${basedir}/src/main/assemblies/package.xml + + + + + package + + single + + + + + + com.mycila.maven-license-plugin + maven-license-plugin + 1.10.b1 + + + + format + + + + +
    ${basedir}/src/etc/header.txt
    + + src/**/*.java + + UTF-8 + + ${basedir}/src/etc/header-definition.xml + +
    +
    + + net.revelc.code + formatter-maven-plugin + 0.5.2 + + + + format + + + + + ${basedir}/src/config/eclipse/formatter/java.xml + + + + maven-javadoc-plugin + 2.10.1 + + UTF-8 + UTF-8 + UTF-8 + + + + net.alchim31.maven + yuicompressor-maven-plugin + 1.5.1 + + + compile + + compress + jslint + + + + + true + ${project.build.directory}/${project.build.finalName}-compress + + **/*min.js + + + + + org.dbflute + dbflute-maven-plugin + 1.1.0 + + ${dbflute.version} + org.codelibs.fess.dbflute + fess + ${basedir}/dbflute_fess + + + + maven-antrun-plugin + 1.8 + + + org.apache.ant + ant + 1.9.6 + + + + + + + + + + + + + + + + + + + + + run + + +
    +
    + + + codelibs.org + CodeLibs Repository + http://maven.codelibs.org/ + + + oss.sonatype.org + oss.sonatype.org + http://oss.sonatype.org/content/groups/public/ + + + + + codelibs.org + CodeLibs Repository + http://maven.codelibs.org/ + + + oss.sonatype.org + oss.sonatype.org + http://oss.sonatype.org/content/groups/public/ + + true + + + true + + + + + + + org.lastaflute + lastaflute + ${lastaflute.version} + + + org.lastaflute + lasta-taglib + ${lasta.taglib.version} + + + + + org.dbflute + dbflute-runtime + ${dbflute.version} + + + + + javax.transaction + javax.transaction-api + 1.2 + + + + + org.slf4j + slf4j-api + ${slf4j.version} + + + ch.qos.logback + logback-classic + ${logback.version} + + + org.codehaus.janino + janino + 2.7.8 + + + org.slf4j + jcl-over-slf4j + ${slf4j.version} + + + org.slf4j + log4j-over-slf4j + ${slf4j.version} + + + + + javax.servlet + javax.servlet-api + ${servlet.version} + provided + + + javax.servlet.jsp + javax.servlet.jsp-api + ${jsp.version} + provided + + + javax.servlet + jstl + 1.2 + + + + + + org.elasticsearch + elasticsearch + ${elasticsearch.version} + + + org.codelibs + elasticsearch-cluster-runner + ${cluster.runner.version} + + + log4j + log4j + + + + + + + org.codelibs + corelib + 0.3.0 + + + + + + commons-fileupload + commons-fileupload + ${commons.fileupload.version} + + + + + org.quartz-scheduler + quartz + 2.2.1 + + + + + + com.sun.mail + javax.mail + 1.5.2 + + + + javax.activation + activation + 1.1.1 + + + + + com.orangesignal + orangesignal-csv + 2.2.1 + + + + + org.codelibs.robot + s2robot-lasta + ${s2robot.version} + + + commons-logging + commons-logging + + + + + org.codelibs.robot + s2robot-es + ${s2robot.version} + + + org.bouncycastle + bcprov-jdk15on + 1.51 + + + org.bouncycastle + bcmail-jdk15on + 1.51 + + + args4j + args4j + 2.32 + + + org.apache.tika + tika-core + ${tika.version} + + + org.apache.tika + tika-parsers + ${tika.version} + + + com.uwyn + jhighlight + + + org.bouncycastle + bcprov-jdk15 + + + org.bouncycastle + bcmail-jdk15 + + + commons-logging + commons-logging + + + + + org.codelibs + jhighlight + 1.0.1 + + + com.ibm.icu + icu4j + 53.1 + + + org.apache.pdfbox + pdfbox + ${pdfbox.version} + + + commons-logging + commons-logging + + + + + org.apache.poi + poi + ${poi.version} + + + org.apache.poi + poi-ooxml + ${poi.version} + + + xml-apis + xml-apis + + + + + org.apache.poi + poi-scratchpad + ${poi.version} + + + + + + net.arnx + jsonic + 1.3.8 + + + + + + com.github.jknack + handlebars + 2.2.2 + + + + + org.codehaus.groovy + groovy-all + 2.4.4 + + + + + com.github.detro + phantomjsdriver + 1.2.0 + + + selenium-chrome-driver + org.seleniumhq.selenium + + + selenium-htmlunit-driver + org.seleniumhq.selenium + + + selenium-firefox-driver + org.seleniumhq.selenium + + + selenium-ie-driver + org.seleniumhq.selenium + + + selenium-safari-driver + org.seleniumhq.selenium + + + webbit + org.webbitserver + + + org.apache.httpcomponents + httpclient + + + + + + + org.dbflute.tomcat + tomcat-boot + ${tomcat.boot.version} + provided + + + + + junit + junit + ${junit.version} + test + + + org.dbflute.utflute + utflute-lastaflute + ${utflute.version} + test + +
    diff --git a/src/main/assemblies/files/fess b/src/main/assemblies/files/fess new file mode 100644 index 000000000..876a8f902 --- /dev/null +++ b/src/main/assemblies/files/fess @@ -0,0 +1,191 @@ +#!/bin/sh + +# OPTIONS: +# -d daemonize (run in background) +# -p pidfile write PID to +# -h +# --help print command line options +# -v print fess version, then exit +# -D prop set JAVA system property +# -X prop set non-standard JAVA system property +# --prop=val +# --prop val set fess property (i.e. -Des.=) + +CDPATH="" +SCRIPT="$0" + +# SCRIPT may be an arbitrarily deep series of symlinks. Loop until we have the concrete path. +while [ -h "$SCRIPT" ] ; do + ls=`ls -ld "$SCRIPT"` + # Drop everything prior to -> + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + SCRIPT="$link" + else + SCRIPT=`dirname "$SCRIPT"`/"$link" + fi +done + +# determine fess home +FESS_HOME=`dirname "$SCRIPT"`/.. + +# make ELASTICSEARCH_HOME absolute +FESS_HOME=`cd "$FESS_HOME"; pwd` + + +# If an include wasn't specified in the environment, then search for one... +if [ "x$FESS_INCLUDE" = "x" ]; then + # Locations (in order) to use when searching for an include file. + for include in /usr/share/fess/fess.in.sh \ + /usr/local/share/fess/fess.in.sh \ + /opt/fess/bin/fess.in.sh \ + ~/.fess.in.sh \ + $FESS_HOME/bin/fess.in.sh \ + "`dirname "$0"`"/fess.in.sh; do + if [ -r "$include" ]; then + . "$include" + break + fi + done +# ...otherwise, source the specified include. +elif [ -r "$FESS_INCLUDE" ]; then + . "$FESS_INCLUDE" +fi + +if [ -x "$JAVA_HOME/bin/java" ]; then + JAVA="$JAVA_HOME/bin/java" +else + JAVA=`which java` +fi + +if [ ! -x "$JAVA" ]; then + echo "Could not find any executable java binary. Please install java in your PATH or set JAVA_HOME" + exit 1 +fi + +if [ -z "$FESS_CLASSPATH" ]; then + echo "You must set the FESS_CLASSPATH var" >&2 + exit 1 +fi + +# Special-case path variables. +case `uname` in + CYGWIN*) + FESS_CLASSPATH=`cygpath -p -w "$FESS_CLASSPATH"` + FESS_HOME=`cygpath -p -w "$FESS_HOME"` + ;; +esac + +launch_service() +{ + pidpath=$1 + daemonized=$2 + props=$3 + fess_parms="-Dfess" + + if [ "x$pidpath" != "x" ]; then + fess_parms="$fess_parms -Dfess.pidfile=$pidpath" + fi + + # Make sure we dont use any predefined locale, as we check some exception message strings and rely on english language + # As those strings are created by the OS, they are dependant on the configured locale + LANG=en_US.UTF-8 + LC_ALL=en_US.UTF-8 + + export HOSTNAME=`hostname -s` + + if [ "x$daemonized" = "x" ]; then + fess_parms="$fess_parms -Dfess.foreground=yes" + exec "$JAVA" $JAVA_OPTS $FESS_JAVA_OPTS $fess_parms -Dfess.es.dir="$ES_HOME" -cp "$FESS_CLASSPATH" $props \ + org.codelibs.fess.FessBoot $FESS_OPTS + else + exec "$JAVA" $JAVA_OPTS $FESS_JAVA_OPTS $fess_parms -Dfess.es.dir="$ES_HOME" -cp "$FESS_CLASSPATH" $props \ + org.codelibs.fess.FessBoot $FESS_OPTS <&- & + return $? + fi +} + +# Print command line usage / help +usage() { + echo "Usage: $0 [-vdh] [-p pidfile] [-D prop] [-X prop]" + echo "Start fess." + echo " -d daemonize (run in background)" + echo " -p pidfile write PID to " + echo " -h" + echo " --help print command line options" + echo " -v print fess version, then exit" + echo " -D prop set JAVA system property" + echo " -X prop set non-standard JAVA system property" + echo " --prop=val" + echo " --prop val set fess property (i.e. -Des.=)" +} + +# Parse any long getopt options and put them into properties before calling getopt below +# Be dash compatible to make sure running under ubuntu works +ARGV="" +while [ $# -gt 0 ] +do + case $1 in + --help) ARGV="$ARGV -h"; shift;; + --*=*) properties="$properties -Dfess.${1#--}" + shift 1 + ;; + --*) [ $# -le 1 ] && { + echo "Option requires an argument: '$1'." + shift + continue + } + properties="$properties -Dfess.${1#--}=$2" + shift 2 + ;; + *) ARGV="$ARGV $1" ; shift + esac +done + +# Parse any command line options. +args=`getopt vdhp:D:X: $ARGV` +eval set -- "$args" + +while true; do + case $1 in + -v) + "$JAVA" $JAVA_OPTS $FESS_JAVA_OPTS $fess_parms -cp "$FESS_CLASSPATH" $props \ + org.codelibs.fess.Version + exit 0 + ;; + -p) + pidfile="$2" + shift 2 + ;; + -d) + daemonized="yes" + shift + ;; + -h) + usage + exit 0 + ;; + -D) + properties="$properties -D$2" + shift 2 + ;; + -X) + properties="$properties -X$2" + shift 2 + ;; + --) + shift + break + ;; + *) + echo "Error parsing argument $1!" >&2 + usage + exit 1 + ;; + esac +done + +# Start up the service +launch_service "$pidfile" "$daemonized" "$properties" + +exit $? diff --git a/src/main/assemblies/files/fess.in.sh b/src/main/assemblies/files/fess.in.sh new file mode 100755 index 000000000..0749e8292 --- /dev/null +++ b/src/main/assemblies/files/fess.in.sh @@ -0,0 +1,83 @@ +#!/bin/sh + +FESS_CLASSPATH=$FESS_HOME/lib/classes + +if [ "x$FESS_MIN_MEM" = "x" ]; then + FESS_MIN_MEM=256m +fi +if [ "x$FESS_MAX_MEM" = "x" ]; then + FESS_MAX_MEM=2g +fi +if [ "x$FESS_HEAP_SIZE" != "x" ]; then + FESS_MIN_MEM=$FESS_HEAP_SIZE + FESS_MAX_MEM=$FESS_HEAP_SIZE +fi + +# min and max heap sizes should be set to the same value to avoid +# stop-the-world GC pauses during resize, and so that we can lock the +# heap in memory on startup to prevent any of it from being swapped +# out. +JAVA_OPTS="$JAVA_OPTS -Xms${FESS_MIN_MEM}" +JAVA_OPTS="$JAVA_OPTS -Xmx${FESS_MAX_MEM}" + +# new generation +if [ "x$FESS_HEAP_NEWSIZE" != "x" ]; then + JAVA_OPTS="$JAVA_OPTS -Xmn${FESS_HEAP_NEWSIZE}" +fi + +# max direct memory +if [ "x$FESS_DIRECT_SIZE" != "x" ]; then + JAVA_OPTS="$JAVA_OPTS -XX:MaxDirectMemorySize=${FESS_DIRECT_SIZE}" +fi + +# set to headless, just in case +JAVA_OPTS="$JAVA_OPTS -Djava.awt.headless=true" + +# Force the JVM to use IPv4 stack +if [ "x$FESS_USE_IPV4" != "x" ]; then + JAVA_OPTS="$JAVA_OPTS -Djava.net.preferIPv4Stack=true" +fi + +JAVA_OPTS="$JAVA_OPTS -XX:+UseParNewGC" +JAVA_OPTS="$JAVA_OPTS -XX:+UseConcMarkSweepGC" + +JAVA_OPTS="$JAVA_OPTS -XX:CMSInitiatingOccupancyFraction=75" +JAVA_OPTS="$JAVA_OPTS -XX:+UseCMSInitiatingOccupancyOnly" + +# GC logging options +if [ "x$FESS_USE_GC_LOGGING" != "x" ]; then + JAVA_OPTS="$JAVA_OPTS -XX:+PrintGCDetails" + JAVA_OPTS="$JAVA_OPTS -XX:+PrintGCTimeStamps" + JAVA_OPTS="$JAVA_OPTS -XX:+PrintGCDateStamps" + JAVA_OPTS="$JAVA_OPTS -XX:+PrintClassHistogram" + JAVA_OPTS="$JAVA_OPTS -XX:+PrintTenuringDistribution" + JAVA_OPTS="$JAVA_OPTS -XX:+PrintGCApplicationStoppedTime" + JAVA_OPTS="$JAVA_OPTS -Xloggc:/var/log/elasticsearch/gc.log" +fi + +# Causes the JVM to dump its heap on OutOfMemory. +JAVA_OPTS="$JAVA_OPTS -XX:+HeapDumpOnOutOfMemoryError" +# The path to the heap dump location, note directory must exists and have enough +# space for a full heap dump. +#JAVA_OPTS="$JAVA_OPTS -XX:HeapDumpPath=$FESS_HOME/logs/heapdump.hprof" + +# Disables explicit GC +JAVA_OPTS="$JAVA_OPTS -XX:+DisableExplicitGC" + +# Ensure UTF-8 encoding by default (e.g. filenames) +JAVA_OPTS="$JAVA_OPTS -Dfile.encoding=UTF-8" + +# Application Configuration +APP_NAME=fess +ES_HOME=$FESS_HOME/es +FESS_JAVA_OPTS="$FESS_JAVA_OPTS -Dfess.home=$FESS_HOME" +FESS_JAVA_OPTS="$FESS_JAVA_OPTS -Dfess.context.path=/$APP_NAME" +FESS_JAVA_OPTS="$FESS_JAVA_OPTS -Dfess.port=8080" +FESS_JAVA_OPTS="$FESS_JAVA_OPTS -Dfess.webapp.path=$FESS_HOME/app" +FESS_JAVA_OPTS="$FESS_JAVA_OPTS -Dfess.webxml.path=$FESS_HOME/app/WEB-INF/web.xml" +FESS_JAVA_OPTS="$FESS_JAVA_OPTS -Dfess.temp.path=$FESS_HOME/temp" +FESS_JAVA_OPTS="$FESS_JAVA_OPTS -Dfess.log.name=$APP_NAME" +FESS_JAVA_OPTS="$FESS_JAVA_OPTS -Dfess.log.path=$FESS_HOME/logs" +FESS_JAVA_OPTS="$FESS_JAVA_OPTS -Dfess.log.level=info" +FESS_JAVA_OPTS="$FESS_JAVA_OPTS -Dlasta.env=production" + diff --git a/src/main/assemblies/files/logging.properties b/src/main/assemblies/files/logging.properties new file mode 100644 index 000000000..87510d068 --- /dev/null +++ b/src/main/assemblies/files/logging.properties @@ -0,0 +1,10 @@ +handlers=java.util.logging.FileHandler +.level=INFO + +java.util.logging.ConsoleHandler.level=INFO +java.util.logging.ConsoleHandler.formatter=java.util.logging.SimpleFormatter + +java.util.logging.FileHandler.level=INFO +java.util.logging.FileHandler.pattern=${fess.home}/logs/server_%g.log +java.util.logging.FileHandler.formatter=java.util.logging.SimpleFormatter +java.util.logging.FileHandler.count=10 diff --git a/src/main/assemblies/package.xml b/src/main/assemblies/package.xml new file mode 100644 index 000000000..ee8074d21 --- /dev/null +++ b/src/main/assemblies/package.xml @@ -0,0 +1,93 @@ + + + package + + zip + + false + + + fess-${project.version}/app + true + true + + org.codelibs.fess:fess + + + + fess-${project.version}/app/WEB-INF/cmd/lib + false + + javax.servlet:javax.servlet-api + + provided + + + + + + ${project.build.directory}/tomcat-lib + fess-${project.version}/lib/classes + + + ${project.build.directory}/fess/WEB-INF/classes/org/codelibs/fess/ + + FessBoot** + + fess-${project.version}/lib/classes/org/codelibs/fess + + + ${project.basedir}/src/main/assemblies/files + + logging.properties + + fess-${project.version}/lib/classes + + + + ${project.basedir}/src/main/assemblies/files + 0755 + lf + + fess + fess.in.sh + + fess-${project.version}/bin + + + + src/main/assemblies/files + fess-${project.version}/logs + + * + + false + + + + src/main/assemblies/files + fess-${project.version}/temp + + * + + false + + + + ${project.basedir}/plugins + fess-${project.version}/es/plugins + + + + src/main/assemblies/files + fess-${project.version}/es/data + + * + + false + + + diff --git a/src/main/config/es/search_log.json b/src/main/config/es/fess_log.json similarity index 82% rename from src/main/config/es/search_log.json rename to src/main/config/es/fess_log.json index 85620260b..c3f0e2b9b 100644 --- a/src/main/config/es/search_log.json +++ b/src/main/config/es/fess_log.json @@ -1,11 +1,7 @@ { - "search_log" : { - "aliases" : { - "search_log_search" : {}, - "search_log_index" : {} - }, + "fess_log" : { "mappings" : { - "user_info" : { + "search_field_log" : { "_all" : { "enabled" : false }, @@ -13,10 +9,32 @@ "path" : "id" }, "properties" : { - "code" : { + "id" : { "type" : "string", "index" : "not_analyzed" }, + "name" : { + "type" : "string", + "index" : "not_analyzed" + }, + "searchLogId" : { + "type" : "string", + "index" : "not_analyzed" + }, + "value" : { + "type" : "string", + "index" : "not_analyzed" + } + } + }, + "favorite_log" : { + "_all" : { + "enabled" : false + }, + "_id" : { + "path" : "id" + }, + "properties" : { "createdTime" : { "type" : "long" }, @@ -24,8 +42,71 @@ "type" : "string", "index" : "not_analyzed" }, - "updatedTime" : { + "url" : { + "type" : "string", + "index" : "not_analyzed" + }, + "userInfoId" : { + "type" : "string", + "index" : "not_analyzed" + } + } + }, + "event_log" : { + "_all" : { + "enabled" : false + }, + "_id" : { + "path" : "id" + }, + "properties" : { + "createdAt" : { + "type" : "date", + "format" : "dateOptionalTime" + }, + "createdBy" : { + "type" : "string", + "index" : "not_analyzed" + }, + "eventType" : { + "type" : "string", + "index" : "not_analyzed" + }, + "id" : { + "type" : "string", + "index" : "not_analyzed" + }, + "message" : { + "type" : "string" + }, + "path" : { + "type" : "string", + "index" : "not_analyzed" + } + } + }, + "click_log" : { + "_all" : { + "enabled" : false + }, + "_id" : { + "path" : "id" + }, + "properties" : { + "id" : { + "type" : "string", + "index" : "not_analyzed" + }, + "requestedTime" : { "type" : "long" + }, + "searchLogId" : { + "type" : "string", + "index" : "not_analyzed" + }, + "url" : { + "type" : "string", + "index" : "not_analyzed" } } }, @@ -86,7 +167,7 @@ } } }, - "search_field_log" : { + "user_info" : { "_all" : { "enabled" : false }, @@ -94,32 +175,10 @@ "path" : "id" }, "properties" : { - "id" : { + "code" : { "type" : "string", "index" : "not_analyzed" }, - "name" : { - "type" : "string", - "index" : "not_analyzed" - }, - "searchLogId" : { - "type" : "string", - "index" : "not_analyzed" - }, - "value" : { - "type" : "string", - "index" : "not_analyzed" - } - } - }, - "favorite_log" : { - "_all" : { - "enabled" : false - }, - "_id" : { - "path" : "id" - }, - "properties" : { "createdTime" : { "type" : "long" }, @@ -127,45 +186,15 @@ "type" : "string", "index" : "not_analyzed" }, - "url" : { - "type" : "string", - "index" : "not_analyzed" - }, - "userInfoId" : { - "type" : "string", - "index" : "not_analyzed" - } - } - }, - "click_log" : { - "_all" : { - "enabled" : false - }, - "_id" : { - "path" : "id" - }, - "properties" : { - "id" : { - "type" : "string", - "index" : "not_analyzed" - }, - "requestedTime" : { + "updatedTime" : { "type" : "long" - }, - "searchLogId" : { - "type" : "string", - "index" : "not_analyzed" - }, - "url" : { - "type" : "string", - "index" : "not_analyzed" } } } }, "settings" : { "index" : { - "refresh_interval" : "1m", + "refresh_interval" : "60s", "number_of_shards" : "10", "number_of_replicas" : "0" } diff --git a/src/main/config/es/fess_user.json b/src/main/config/es/fess_user.json new file mode 100644 index 000000000..084f5eda5 --- /dev/null +++ b/src/main/config/es/fess_user.json @@ -0,0 +1,90 @@ +{ + ".fess_user" : { + "mappings" : { + "role" : { + "_all" : { + "enabled" : false + }, + "_id" : { + "path" : "id" + }, + "properties" : { + "id" : { + "type" : "string", + "index" : "not_analyzed" + }, + "name" : { + "type" : "string", + "index" : "not_analyzed" + } + } + }, + "user" : { + "_all" : { + "enabled" : false + }, + "_id" : { + "path" : "id" + }, + "properties" : { + "groups" : { + "type" : "string", + "index" : "not_analyzed" + }, + "id" : { + "type" : "string", + "index" : "not_analyzed" + }, + "name" : { + "type" : "string", + "index" : "not_analyzed" + }, + "password" : { + "type" : "string", + "index" : "not_analyzed" + }, + "roles" : { + "type" : "string", + "index" : "not_analyzed" + } + } + }, + "group" : { + "_all" : { + "enabled" : false + }, + "_id" : { + "path" : "id" + }, + "properties" : { + "id" : { + "type" : "string", + "index" : "not_analyzed" + }, + "name" : { + "type" : "string", + "index" : "not_analyzed" + } + } + } + }, + "settings" : { + "index" : { + "refresh_interval" : "1s", + "dbflute" : { + "user" : { + "properties" : { + "groups" : { + "array" : "true" + }, + "roles" : { + "array" : "true" + } + } + } + }, + "number_of_replicas" : "0" + } + } + } +} diff --git a/src/main/config/tablemeta.properties b/src/main/config/tablemeta.properties deleted file mode 100644 index b62a875e4..000000000 --- a/src/main/config/tablemeta.properties +++ /dev/null @@ -1,3239 +0,0 @@ -boostDocumentRule.ignored=false -boostDocumentRule.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.FloatRange; -boostDocumentRule.converterToSearchParams= -boostDocumentRule.converterToPager= -boostDocumentRule.converterToActionForm= -boostDocumentRule.converterToEntity= -boostDocumentRule.id.requiredParam= -boostDocumentRule.id.additionalAnnotation= -boostDocumentRule.id.annotation= -boostDocumentRule.id.enableJavaType=true -boostDocumentRule.id.longTypeParam= -boostDocumentRule.id.integerTypeParam= -boostDocumentRule.id.shortTypeParam= -boostDocumentRule.id.byteTypeParam= -boostDocumentRule.id.floatTypeParam= -boostDocumentRule.id.doubleTypeParam= -boostDocumentRule.id.dateTypeParam= -boostDocumentRule.id.defaultValue= -boostDocumentRule.urlExpr.requiredParam= -boostDocumentRule.urlExpr.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -boostDocumentRule.urlExpr.annotation= -boostDocumentRule.urlExpr.enableJavaType=true -boostDocumentRule.urlExpr.longTypeParam= -boostDocumentRule.urlExpr.integerTypeParam= -boostDocumentRule.urlExpr.shortTypeParam= -boostDocumentRule.urlExpr.byteTypeParam= -boostDocumentRule.urlExpr.floatTypeParam= -boostDocumentRule.urlExpr.doubleTypeParam= -boostDocumentRule.urlExpr.dateTypeParam= -boostDocumentRule.urlExpr.defaultValue= -boostDocumentRule.boostExpr.requiredParam= -boostDocumentRule.boostExpr.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -boostDocumentRule.boostExpr.annotation= -boostDocumentRule.boostExpr.enableJavaType=true -boostDocumentRule.boostExpr.longTypeParam= -boostDocumentRule.boostExpr.integerTypeParam= -boostDocumentRule.boostExpr.shortTypeParam= -boostDocumentRule.boostExpr.byteTypeParam= -boostDocumentRule.boostExpr.floatTypeParam= -boostDocumentRule.boostExpr.doubleTypeParam= -boostDocumentRule.boostExpr.dateTypeParam= -boostDocumentRule.boostExpr.defaultValue= -boostDocumentRule.sortOrder.requiredParam= -boostDocumentRule.sortOrder.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -boostDocumentRule.sortOrder.annotation= -boostDocumentRule.sortOrder.enableJavaType=true -boostDocumentRule.sortOrder.longTypeParam= -boostDocumentRule.sortOrder.integerTypeParam= -boostDocumentRule.sortOrder.shortTypeParam= -boostDocumentRule.sortOrder.byteTypeParam= -boostDocumentRule.sortOrder.floatTypeParam= -boostDocumentRule.sortOrder.doubleTypeParam= -boostDocumentRule.sortOrder.dateTypeParam= -boostDocumentRule.sortOrder.defaultValue= -boostDocumentRule.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -boostDocumentRule.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -boostDocumentRule.createdBy.annotation= -boostDocumentRule.createdBy.enableJavaType=true -boostDocumentRule.createdBy.longTypeParam= -boostDocumentRule.createdBy.integerTypeParam= -boostDocumentRule.createdBy.shortTypeParam= -boostDocumentRule.createdBy.byteTypeParam= -boostDocumentRule.createdBy.floatTypeParam= -boostDocumentRule.createdBy.doubleTypeParam= -boostDocumentRule.createdBy.dateTypeParam= -boostDocumentRule.createdBy.defaultValue= -boostDocumentRule.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -boostDocumentRule.createdTime.additionalAnnotation= -boostDocumentRule.createdTime.annotation= -boostDocumentRule.createdTime.enableJavaType=true -boostDocumentRule.createdTime.longTypeParam= -boostDocumentRule.createdTime.integerTypeParam= -boostDocumentRule.createdTime.shortTypeParam= -boostDocumentRule.createdTime.byteTypeParam= -boostDocumentRule.createdTime.floatTypeParam= -boostDocumentRule.createdTime.doubleTypeParam= -boostDocumentRule.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -boostDocumentRule.createdTime.defaultValue= -boostDocumentRule.updatedBy.requiredParam= -boostDocumentRule.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -boostDocumentRule.updatedBy.annotation= -boostDocumentRule.updatedBy.enableJavaType=true -boostDocumentRule.updatedBy.longTypeParam= -boostDocumentRule.updatedBy.integerTypeParam= -boostDocumentRule.updatedBy.shortTypeParam= -boostDocumentRule.updatedBy.byteTypeParam= -boostDocumentRule.updatedBy.floatTypeParam= -boostDocumentRule.updatedBy.doubleTypeParam= -boostDocumentRule.updatedBy.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -boostDocumentRule.updatedBy.defaultValue= -boostDocumentRule.updatedTime.requiredParam= -boostDocumentRule.updatedTime.additionalAnnotation= -boostDocumentRule.updatedTime.annotation= -boostDocumentRule.updatedTime.enableJavaType=true -boostDocumentRule.updatedTime.longTypeParam= -boostDocumentRule.updatedTime.integerTypeParam= -boostDocumentRule.updatedTime.shortTypeParam= -boostDocumentRule.updatedTime.byteTypeParam= -boostDocumentRule.updatedTime.floatTypeParam= -boostDocumentRule.updatedTime.doubleTypeParam= -boostDocumentRule.updatedTime.dateTypeParam= -boostDocumentRule.updatedTime.defaultValue= -boostDocumentRule.deletedBy.requiredParam= -boostDocumentRule.deletedBy.additionalAnnotation= -boostDocumentRule.deletedBy.annotation= -boostDocumentRule.deletedBy.enableJavaType=true -boostDocumentRule.deletedBy.longTypeParam= -boostDocumentRule.deletedBy.integerTypeParam= -boostDocumentRule.deletedBy.shortTypeParam= -boostDocumentRule.deletedBy.byteTypeParam= -boostDocumentRule.deletedBy.floatTypeParam= -boostDocumentRule.deletedBy.doubleTypeParam= -boostDocumentRule.deletedBy.dateTypeParam= -boostDocumentRule.deletedBy.defaultValue= -boostDocumentRule.deletedTime.requiredParam= -boostDocumentRule.deletedTime.additionalAnnotation= -boostDocumentRule.deletedTime.annotation= -boostDocumentRule.deletedTime.enableJavaType=true -boostDocumentRule.deletedTime.longTypeParam= -boostDocumentRule.deletedTime.integerTypeParam= -boostDocumentRule.deletedTime.shortTypeParam= -boostDocumentRule.deletedTime.byteTypeParam= -boostDocumentRule.deletedTime.floatTypeParam= -boostDocumentRule.deletedTime.doubleTypeParam= -boostDocumentRule.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -boostDocumentRule.deletedTime.defaultValue= -boostDocumentRule.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -boostDocumentRule.versionNo.additionalAnnotation= -boostDocumentRule.versionNo.annotation= -boostDocumentRule.versionNo.enableJavaType=true -boostDocumentRule.versionNo.longTypeParam= -boostDocumentRule.versionNo.integerTypeParam= -boostDocumentRule.versionNo.shortTypeParam= -boostDocumentRule.versionNo.byteTypeParam= -boostDocumentRule.versionNo.floatTypeParam= -boostDocumentRule.versionNo.doubleTypeParam= -boostDocumentRule.versionNo.dateTypeParam= -boostDocumentRule.versionNo.defaultValue= - -clickLog.ignored=true - -crawlingSession.ignored=false -crawlingSession.importPackages=import org.seasar.struts.annotation.Maxbytelength; -crawlingSession.converterToSearchParams= -crawlingSession.converterToPager= -crawlingSession.converterToActionForm= -crawlingSession.converterToEntity= -crawlingSession.id.requiredParam= -crawlingSession.id.additionalAnnotation= -crawlingSession.id.annotation= -crawlingSession.id.enableJavaType=true -crawlingSession.id.longTypeParam= -crawlingSession.id.integerTypeParam= -crawlingSession.id.shortTypeParam= -crawlingSession.id.byteTypeParam= -crawlingSession.id.floatTypeParam= -crawlingSession.id.doubleTypeParam= -crawlingSession.id.dateTypeParam= -crawlingSession.id.defaultValue= -crawlingSession.sessionId.requiredParam=(target = "confirmfromupdate,update,delete") -crawlingSession.sessionId.additionalAnnotation=@Maxbytelength(maxbytelength = 20) -crawlingSession.sessionId.annotation= -crawlingSession.sessionId.enableJavaType=true -crawlingSession.sessionId.longTypeParam= -crawlingSession.sessionId.integerTypeParam= -crawlingSession.sessionId.shortTypeParam= -crawlingSession.sessionId.byteTypeParam= -crawlingSession.sessionId.floatTypeParam= -crawlingSession.sessionId.doubleTypeParam= -crawlingSession.sessionId.dateTypeParam= -crawlingSession.sessionId.defaultValue= -crawlingSession.name.requiredParam= -crawlingSession.name.additionalAnnotation=@Maxbytelength(maxbytelength = 20) -crawlingSession.name.annotation= -crawlingSession.name.enableJavaType=true -crawlingSession.name.longTypeParam= -crawlingSession.name.integerTypeParam= -crawlingSession.name.shortTypeParam= -crawlingSession.name.byteTypeParam= -crawlingSession.name.floatTypeParam= -crawlingSession.name.doubleTypeParam= -crawlingSession.name.dateTypeParam= -crawlingSession.name.defaultValue= -crawlingSession.expiredTime.requiredParam=(target = "confirmfromupdate,update,delete") -crawlingSession.expiredTime.additionalAnnotation= -crawlingSession.expiredTime.annotation= -crawlingSession.expiredTime.enableJavaType=true -crawlingSession.expiredTime.longTypeParam= -crawlingSession.expiredTime.integerTypeParam= -crawlingSession.expiredTime.shortTypeParam= -crawlingSession.expiredTime.byteTypeParam= -crawlingSession.expiredTime.floatTypeParam= -crawlingSession.expiredTime.doubleTypeParam= -crawlingSession.expiredTime.dateTypeParam= -crawlingSession.expiredTime.defaultValue= -crawlingSession.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -crawlingSession.createdTime.additionalAnnotation= -crawlingSession.createdTime.annotation= -crawlingSession.createdTime.enableJavaType=true -crawlingSession.createdTime.longTypeParam= -crawlingSession.createdTime.integerTypeParam= -crawlingSession.createdTime.shortTypeParam= -crawlingSession.createdTime.byteTypeParam= -crawlingSession.createdTime.floatTypeParam= -crawlingSession.createdTime.doubleTypeParam= -crawlingSession.createdTime.dateTypeParam= -crawlingSession.createdTime.defaultValue= - -crawlingSessionInfo.ignored=true - -dataConfigToLabelTypeMapping.ignored=true - -dataConfigToRoleTypeMapping.ignored=true - -dataCrawlingConfig.ignored=false -dataCrawlingConfig.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.FloatRange; -dataCrawlingConfig.converterToSearchParams= -dataCrawlingConfig.converterToPager= -dataCrawlingConfig.converterToActionForm= -dataCrawlingConfig.converterToEntity= -dataCrawlingConfig.id.requiredParam= -dataCrawlingConfig.id.additionalAnnotation= -dataCrawlingConfig.id.annotation= -dataCrawlingConfig.id.enableJavaType=true -dataCrawlingConfig.id.longTypeParam= -dataCrawlingConfig.id.integerTypeParam= -dataCrawlingConfig.id.shortTypeParam= -dataCrawlingConfig.id.byteTypeParam= -dataCrawlingConfig.id.floatTypeParam= -dataCrawlingConfig.id.doubleTypeParam= -dataCrawlingConfig.id.dateTypeParam= -dataCrawlingConfig.id.defaultValue= -dataCrawlingConfig.name.requiredParam= -dataCrawlingConfig.name.additionalAnnotation=@Maxbytelength(maxbytelength = 200) -dataCrawlingConfig.name.annotation= -dataCrawlingConfig.name.enableJavaType=true -dataCrawlingConfig.name.longTypeParam= -dataCrawlingConfig.name.integerTypeParam= -dataCrawlingConfig.name.shortTypeParam= -dataCrawlingConfig.name.byteTypeParam= -dataCrawlingConfig.name.floatTypeParam= -dataCrawlingConfig.name.doubleTypeParam= -dataCrawlingConfig.name.dateTypeParam= -dataCrawlingConfig.name.defaultValue= -dataCrawlingConfig.handlerName.requiredParam= -dataCrawlingConfig.handlerName.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -dataCrawlingConfig.handlerName.annotation= -dataCrawlingConfig.handlerName.enableJavaType=true -dataCrawlingConfig.handlerName.longTypeParam= -dataCrawlingConfig.handlerName.integerTypeParam= -dataCrawlingConfig.handlerName.shortTypeParam= -dataCrawlingConfig.handlerName.byteTypeParam= -dataCrawlingConfig.handlerName.floatTypeParam= -dataCrawlingConfig.handlerName.doubleTypeParam= -dataCrawlingConfig.handlerName.dateTypeParam= -dataCrawlingConfig.handlerName.defaultValue= -dataCrawlingConfig.handlerParameter.requiredParam= -dataCrawlingConfig.handlerParameter.additionalAnnotation= -dataCrawlingConfig.handlerParameter.annotation= -dataCrawlingConfig.handlerParameter.enableJavaType=true -dataCrawlingConfig.handlerParameter.longTypeParam= -dataCrawlingConfig.handlerParameter.integerTypeParam= -dataCrawlingConfig.handlerParameter.shortTypeParam= -dataCrawlingConfig.handlerParameter.byteTypeParam= -dataCrawlingConfig.handlerParameter.floatTypeParam= -dataCrawlingConfig.handlerParameter.doubleTypeParam= -dataCrawlingConfig.handlerParameter.dateTypeParam= -dataCrawlingConfig.handlerParameter.defaultValue= -dataCrawlingConfig.handlerScript.requiredParam= -dataCrawlingConfig.handlerScript.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -dataCrawlingConfig.handlerScript.annotation= -dataCrawlingConfig.handlerScript.enableJavaType=true -dataCrawlingConfig.handlerScript.longTypeParam= -dataCrawlingConfig.handlerScript.integerTypeParam= -dataCrawlingConfig.handlerScript.shortTypeParam= -dataCrawlingConfig.handlerScript.byteTypeParam= -dataCrawlingConfig.handlerScript.floatTypeParam= -dataCrawlingConfig.handlerScript.doubleTypeParam= -dataCrawlingConfig.handlerScript.dateTypeParam= -dataCrawlingConfig.handlerScript.defaultValue= -dataCrawlingConfig.boost.requiredParam= -dataCrawlingConfig.boost.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -dataCrawlingConfig.boost.annotation= -dataCrawlingConfig.boost.enableJavaType=true -dataCrawlingConfig.boost.longTypeParam= -dataCrawlingConfig.boost.integerTypeParam= -dataCrawlingConfig.boost.shortTypeParam= -dataCrawlingConfig.boost.byteTypeParam= -dataCrawlingConfig.boost.floatTypeParam= -dataCrawlingConfig.boost.doubleTypeParam= -dataCrawlingConfig.boost.dateTypeParam= -dataCrawlingConfig.boost.defaultValue="1" -dataCrawlingConfig.available.requiredParam= -dataCrawlingConfig.available.additionalAnnotation=@Maxbytelength(maxbytelength = 1) -dataCrawlingConfig.available.annotation= -dataCrawlingConfig.available.enableJavaType=true -dataCrawlingConfig.available.longTypeParam= -dataCrawlingConfig.available.integerTypeParam= -dataCrawlingConfig.available.shortTypeParam= -dataCrawlingConfig.available.byteTypeParam= -dataCrawlingConfig.available.floatTypeParam= -dataCrawlingConfig.available.doubleTypeParam= -dataCrawlingConfig.available.dateTypeParam= -dataCrawlingConfig.available.defaultValue= -dataCrawlingConfig.sortOrder.requiredParam=(target = "confirmfromupdate,update,delete") -dataCrawlingConfig.sortOrder.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -dataCrawlingConfig.sortOrder.annotation= -dataCrawlingConfig.sortOrder.enableJavaType=true -dataCrawlingConfig.sortOrder.longTypeParam= -dataCrawlingConfig.sortOrder.integerTypeParam= -dataCrawlingConfig.sortOrder.shortTypeParam= -dataCrawlingConfig.sortOrder.byteTypeParam= -dataCrawlingConfig.sortOrder.floatTypeParam= -dataCrawlingConfig.sortOrder.doubleTypeParam= -dataCrawlingConfig.sortOrder.dateTypeParam= -dataCrawlingConfig.sortOrder.defaultValue= -dataCrawlingConfig.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -dataCrawlingConfig.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -dataCrawlingConfig.createdBy.annotation= -dataCrawlingConfig.createdBy.enableJavaType=true -dataCrawlingConfig.createdBy.longTypeParam= -dataCrawlingConfig.createdBy.integerTypeParam= -dataCrawlingConfig.createdBy.shortTypeParam= -dataCrawlingConfig.createdBy.byteTypeParam= -dataCrawlingConfig.createdBy.floatTypeParam= -dataCrawlingConfig.createdBy.doubleTypeParam= -dataCrawlingConfig.createdBy.dateTypeParam= -dataCrawlingConfig.createdBy.defaultValue= -dataCrawlingConfig.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -dataCrawlingConfig.createdTime.additionalAnnotation= -dataCrawlingConfig.createdTime.annotation= -dataCrawlingConfig.createdTime.enableJavaType=true -dataCrawlingConfig.createdTime.longTypeParam= -dataCrawlingConfig.createdTime.integerTypeParam= -dataCrawlingConfig.createdTime.shortTypeParam= -dataCrawlingConfig.createdTime.byteTypeParam= -dataCrawlingConfig.createdTime.floatTypeParam= -dataCrawlingConfig.createdTime.doubleTypeParam= -dataCrawlingConfig.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -dataCrawlingConfig.createdTime.defaultValue= -dataCrawlingConfig.updatedBy.requiredParam= -dataCrawlingConfig.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -dataCrawlingConfig.updatedBy.annotation= -dataCrawlingConfig.updatedBy.enableJavaType=true -dataCrawlingConfig.updatedBy.longTypeParam= -dataCrawlingConfig.updatedBy.integerTypeParam= -dataCrawlingConfig.updatedBy.shortTypeParam= -dataCrawlingConfig.updatedBy.byteTypeParam= -dataCrawlingConfig.updatedBy.floatTypeParam= -dataCrawlingConfig.updatedBy.doubleTypeParam= -dataCrawlingConfig.updatedBy.dateTypeParam= -dataCrawlingConfig.updatedBy.defaultValue= -dataCrawlingConfig.updatedTime.requiredParam= -dataCrawlingConfig.updatedTime.additionalAnnotation= -dataCrawlingConfig.updatedTime.annotation= -dataCrawlingConfig.updatedTime.enableJavaType=true -dataCrawlingConfig.updatedTime.longTypeParam= -dataCrawlingConfig.updatedTime.integerTypeParam= -dataCrawlingConfig.updatedTime.shortTypeParam= -dataCrawlingConfig.updatedTime.byteTypeParam= -dataCrawlingConfig.updatedTime.floatTypeParam= -dataCrawlingConfig.updatedTime.doubleTypeParam= -dataCrawlingConfig.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -dataCrawlingConfig.updatedTime.defaultValue= -dataCrawlingConfig.deletedBy.requiredParam= -dataCrawlingConfig.deletedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -dataCrawlingConfig.deletedBy.annotation= -dataCrawlingConfig.deletedBy.enableJavaType=true -dataCrawlingConfig.deletedBy.longTypeParam= -dataCrawlingConfig.deletedBy.integerTypeParam= -dataCrawlingConfig.deletedBy.shortTypeParam= -dataCrawlingConfig.deletedBy.byteTypeParam= -dataCrawlingConfig.deletedBy.floatTypeParam= -dataCrawlingConfig.deletedBy.doubleTypeParam= -dataCrawlingConfig.deletedBy.dateTypeParam= -dataCrawlingConfig.deletedBy.defaultValue= -dataCrawlingConfig.deletedTime.requiredParam= -dataCrawlingConfig.deletedTime.additionalAnnotation= -dataCrawlingConfig.deletedTime.annotation= -dataCrawlingConfig.deletedTime.enableJavaType=true -dataCrawlingConfig.deletedTime.longTypeParam= -dataCrawlingConfig.deletedTime.integerTypeParam= -dataCrawlingConfig.deletedTime.shortTypeParam= -dataCrawlingConfig.deletedTime.byteTypeParam= -dataCrawlingConfig.deletedTime.floatTypeParam= -dataCrawlingConfig.deletedTime.doubleTypeParam= -dataCrawlingConfig.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -dataCrawlingConfig.deletedTime.defaultValue= -dataCrawlingConfig.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -dataCrawlingConfig.versionNo.additionalAnnotation= -dataCrawlingConfig.versionNo.annotation= -dataCrawlingConfig.versionNo.enableJavaType=true -dataCrawlingConfig.versionNo.longTypeParam= -dataCrawlingConfig.versionNo.integerTypeParam= -dataCrawlingConfig.versionNo.shortTypeParam= -dataCrawlingConfig.versionNo.byteTypeParam= -dataCrawlingConfig.versionNo.floatTypeParam= -dataCrawlingConfig.versionNo.doubleTypeParam= -dataCrawlingConfig.versionNo.dateTypeParam= -dataCrawlingConfig.versionNo.defaultValue= - -failureUrl.ignored=false -failureUrl.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.FloatRange; -failureUrl.converterToSearchParams= -failureUrl.converterToPager= -failureUrl.converterToActionForm= -failureUrl.converterToEntity= -failureUrl.id.requiredParam= -failureUrl.id.additionalAnnotation= -failureUrl.id.annotation= -failureUrl.id.enableJavaType=true -failureUrl.id.longTypeParam= -failureUrl.id.integerTypeParam= -failureUrl.id.shortTypeParam= -failureUrl.id.byteTypeParam= -failureUrl.id.floatTypeParam= -failureUrl.id.doubleTypeParam= -failureUrl.id.dateTypeParam= -failureUrl.id.defaultValue= -failureUrl.url.requiredParam= -failureUrl.url.additionalAnnotation= -failureUrl.url.annotation= -failureUrl.url.enableJavaType=true -failureUrl.url.longTypeParam= -failureUrl.url.integerTypeParam= -failureUrl.url.shortTypeParam= -failureUrl.url.byteTypeParam= -failureUrl.url.floatTypeParam= -failureUrl.url.doubleTypeParam= -failureUrl.url.dateTypeParam= -failureUrl.url.defaultValue= -failureUrl.threadName.requiredParam= -failureUrl.threadName.additionalAnnotation= -failureUrl.threadName.annotation= -failureUrl.threadName.enableJavaType=true -failureUrl.threadName.longTypeParam= -failureUrl.threadName.integerTypeParam= -failureUrl.threadName.shortTypeParam= -failureUrl.threadName.byteTypeParam= -failureUrl.threadName.floatTypeParam= -failureUrl.threadName.doubleTypeParam= -failureUrl.threadName.dateTypeParam= -failureUrl.threadName.defaultValue= -failureUrl.errorName.requiredParam= -failureUrl.errorName.additionalAnnotation= -failureUrl.errorName.annotation= -failureUrl.errorName.enableJavaType=true -failureUrl.errorName.longTypeParam= -failureUrl.errorName.integerTypeParam= -failureUrl.errorName.shortTypeParam= -failureUrl.errorName.byteTypeParam= -failureUrl.errorName.floatTypeParam= -failureUrl.errorName.doubleTypeParam= -failureUrl.errorName.dateTypeParam= -failureUrl.errorName.defaultValue= -failureUrl.errorLog.requiredParam= -failureUrl.errorLog.additionalAnnotation= -failureUrl.errorLog.annotation= -failureUrl.errorLog.enableJavaType=true -failureUrl.errorLog.longTypeParam= -failureUrl.errorLog.integerTypeParam= -failureUrl.errorLog.shortTypeParam= -failureUrl.errorLog.byteTypeParam= -failureUrl.errorLog.floatTypeParam= -failureUrl.errorLog.doubleTypeParam= -failureUrl.errorLog.dateTypeParam= -failureUrl.errorLog.defaultValue= -failureUrl.errorCount.requiredParam= -failureUrl.errorCount.additionalAnnotation= -failureUrl.errorCount.annotation= -failureUrl.errorCount.enableJavaType=true -failureUrl.errorCount.longTypeParam= -failureUrl.errorCount.integerTypeParam= -failureUrl.errorCount.shortTypeParam= -failureUrl.errorCount.byteTypeParam= -failureUrl.errorCount.floatTypeParam= -failureUrl.errorCount.doubleTypeParam= -failureUrl.errorCount.dateTypeParam= -failureUrl.errorCount.defaultValue= -failureUrl.lastAccessTime.requiredParam= -failureUrl.lastAccessTime.additionalAnnotation= -failureUrl.lastAccessTime.annotation= -failureUrl.lastAccessTime.enableJavaType=true -failureUrl.lastAccessTime.longTypeParam= -failureUrl.lastAccessTime.integerTypeParam= -failureUrl.lastAccessTime.shortTypeParam= -failureUrl.lastAccessTime.byteTypeParam= -failureUrl.lastAccessTime.floatTypeParam= -failureUrl.lastAccessTime.doubleTypeParam= -failureUrl.lastAccessTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -failureUrl.lastAccessTime.defaultValue= -failureUrl.configId.requiredParam= -failureUrl.configId.additionalAnnotation= -failureUrl.configId.annotation= -failureUrl.configId.enableJavaType=true -failureUrl.configId.longTypeParam= -failureUrl.configId.integerTypeParam= -failureUrl.configId.shortTypeParam= -failureUrl.configId.byteTypeParam= -failureUrl.configId.floatTypeParam= -failureUrl.configId.doubleTypeParam= -failureUrl.configId.dateTypeParam= -failureUrl.configId.defaultValue= - -favoriteLog.ignored=false -favoriteLog.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.FloatRange; -favoriteLog.converterToSearchParams= -favoriteLog.converterToPager= -favoriteLog.converterToActionForm= -favoriteLog.converterToEntity= -favoriteLog.id.requiredParam= -favoriteLog.id.additionalAnnotation= -favoriteLog.id.annotation= -favoriteLog.id.enableJavaType=true -favoriteLog.id.longTypeParam= -favoriteLog.id.integerTypeParam= -favoriteLog.id.shortTypeParam= -favoriteLog.id.byteTypeParam= -favoriteLog.id.floatTypeParam= -favoriteLog.id.doubleTypeParam= -favoriteLog.id.dateTypeParam= -favoriteLog.id.defaultValue= -favoriteLog.userId.requiredParam= -favoriteLog.userId.additionalAnnotation= -favoriteLog.userId.annotation= -favoriteLog.userId.enableJavaType=true -favoriteLog.userId.longTypeParam= -favoriteLog.userId.integerTypeParam= -favoriteLog.userId.shortTypeParam= -favoriteLog.userId.byteTypeParam= -favoriteLog.userId.floatTypeParam= -favoriteLog.userId.doubleTypeParam= -favoriteLog.userId.dateTypeParam= -favoriteLog.userId.defaultValue= -favoriteLog.url.requiredParam= -favoriteLog.url.additionalAnnotation= -favoriteLog.url.annotation= -favoriteLog.url.enableJavaType=true -favoriteLog.url.longTypeParam= -favoriteLog.url.integerTypeParam= -favoriteLog.url.shortTypeParam= -favoriteLog.url.byteTypeParam= -favoriteLog.url.floatTypeParam= -favoriteLog.url.doubleTypeParam= -favoriteLog.url.dateTypeParam= -favoriteLog.url.defaultValue= -favoriteLog.createdTime.requiredParam= -favoriteLog.createdTime.additionalAnnotation= -favoriteLog.createdTime.annotation= -favoriteLog.createdTime.enableJavaType=true -favoriteLog.createdTime.longTypeParam= -favoriteLog.createdTime.integerTypeParam= -favoriteLog.createdTime.shortTypeParam= -favoriteLog.createdTime.byteTypeParam= -favoriteLog.createdTime.floatTypeParam= -favoriteLog.createdTime.doubleTypeParam= -favoriteLog.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -favoriteLog.createdTime.defaultValue= - -fileAuthentication.ignored=false -fileAuthentication.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange; -fileAuthentication.converterToSearchParams= -fileAuthentication.converterToPager= -fileAuthentication.converterToActionForm= -fileAuthentication.converterToEntity= -fileAuthentication.id.requiredParam= -fileAuthentication.id.additionalAnnotation= -fileAuthentication.id.annotation= -fileAuthentication.id.enableJavaType=true -fileAuthentication.id.longTypeParam= -fileAuthentication.id.integerTypeParam= -fileAuthentication.id.shortTypeParam= -fileAuthentication.id.byteTypeParam= -fileAuthentication.id.floatTypeParam= -fileAuthentication.id.doubleTypeParam= -fileAuthentication.id.dateTypeParam= -fileAuthentication.id.defaultValue= -fileAuthentication.hostname.requiredParam= -fileAuthentication.hostname.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -fileAuthentication.hostname.annotation= -fileAuthentication.hostname.enableJavaType=true -fileAuthentication.hostname.longTypeParam= -fileAuthentication.hostname.integerTypeParam= -fileAuthentication.hostname.shortTypeParam= -fileAuthentication.hostname.byteTypeParam= -fileAuthentication.hostname.floatTypeParam= -fileAuthentication.hostname.doubleTypeParam= -fileAuthentication.hostname.dateTypeParam= -fileAuthentication.hostname.defaultValue= -fileAuthentication.port.requiredParam= -fileAuthentication.port.additionalAnnotation= -fileAuthentication.port.annotation=@IntRange(min = -1, max = 2147483647) -fileAuthentication.port.enableJavaType=false -fileAuthentication.port.longTypeParam= -fileAuthentication.port.integerTypeParam= -fileAuthentication.port.shortTypeParam= -fileAuthentication.port.byteTypeParam= -fileAuthentication.port.floatTypeParam= -fileAuthentication.port.doubleTypeParam= -fileAuthentication.port.dateTypeParam= -fileAuthentication.port.defaultValue= -fileAuthentication.protocolScheme.requiredParam= -fileAuthentication.protocolScheme.additionalAnnotation=@Maxbytelength(maxbytelength = 10) -fileAuthentication.protocolScheme.annotation= -fileAuthentication.protocolScheme.enableJavaType=true -fileAuthentication.protocolScheme.longTypeParam= -fileAuthentication.protocolScheme.integerTypeParam= -fileAuthentication.protocolScheme.shortTypeParam= -fileAuthentication.protocolScheme.byteTypeParam= -fileAuthentication.protocolScheme.floatTypeParam= -fileAuthentication.protocolScheme.doubleTypeParam= -fileAuthentication.protocolScheme.dateTypeParam= -fileAuthentication.protocolScheme.defaultValue= -fileAuthentication.username.requiredParam= -fileAuthentication.username.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -fileAuthentication.username.annotation= -fileAuthentication.username.enableJavaType=true -fileAuthentication.username.longTypeParam= -fileAuthentication.username.integerTypeParam= -fileAuthentication.username.shortTypeParam= -fileAuthentication.username.byteTypeParam= -fileAuthentication.username.floatTypeParam= -fileAuthentication.username.doubleTypeParam= -fileAuthentication.username.dateTypeParam= -fileAuthentication.username.defaultValue= -fileAuthentication.password.requiredParam= -fileAuthentication.password.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -fileAuthentication.password.annotation= -fileAuthentication.password.enableJavaType=true -fileAuthentication.password.longTypeParam= -fileAuthentication.password.integerTypeParam= -fileAuthentication.password.shortTypeParam= -fileAuthentication.password.byteTypeParam= -fileAuthentication.password.floatTypeParam= -fileAuthentication.password.doubleTypeParam= -fileAuthentication.password.dateTypeParam= -fileAuthentication.password.defaultValue= -fileAuthentication.parameters.requiredParam= -fileAuthentication.parameters.additionalAnnotation=@Maxbytelength(maxbytelength = 1000) -fileAuthentication.parameters.annotation= -fileAuthentication.parameters.enableJavaType=true -fileAuthentication.parameters.longTypeParam= -fileAuthentication.parameters.integerTypeParam= -fileAuthentication.parameters.shortTypeParam= -fileAuthentication.parameters.byteTypeParam= -fileAuthentication.parameters.floatTypeParam= -fileAuthentication.parameters.doubleTypeParam= -fileAuthentication.parameters.dateTypeParam= -fileAuthentication.parameters.defaultValue= -fileAuthentication.fileCrawlingConfigId.requiredParam= -fileAuthentication.fileCrawlingConfigId.additionalAnnotation= -fileAuthentication.fileCrawlingConfigId.annotation= -fileAuthentication.fileCrawlingConfigId.enableJavaType=true -fileAuthentication.fileCrawlingConfigId.longTypeParam= -fileAuthentication.fileCrawlingConfigId.integerTypeParam= -fileAuthentication.fileCrawlingConfigId.shortTypeParam= -fileAuthentication.fileCrawlingConfigId.byteTypeParam= -fileAuthentication.fileCrawlingConfigId.floatTypeParam= -fileAuthentication.fileCrawlingConfigId.doubleTypeParam= -fileAuthentication.fileCrawlingConfigId.dateTypeParam= -fileAuthentication.fileCrawlingConfigId.defaultValue= -fileAuthentication.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -fileAuthentication.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -fileAuthentication.createdBy.annotation= -fileAuthentication.createdBy.enableJavaType=true -fileAuthentication.createdBy.longTypeParam= -fileAuthentication.createdBy.integerTypeParam= -fileAuthentication.createdBy.shortTypeParam= -fileAuthentication.createdBy.byteTypeParam= -fileAuthentication.createdBy.floatTypeParam= -fileAuthentication.createdBy.doubleTypeParam= -fileAuthentication.createdBy.dateTypeParam= -fileAuthentication.createdBy.defaultValue= -fileAuthentication.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -fileAuthentication.createdTime.additionalAnnotation= -fileAuthentication.createdTime.annotation= -fileAuthentication.createdTime.enableJavaType=true -fileAuthentication.createdTime.longTypeParam= -fileAuthentication.createdTime.integerTypeParam= -fileAuthentication.createdTime.shortTypeParam= -fileAuthentication.createdTime.byteTypeParam= -fileAuthentication.createdTime.floatTypeParam= -fileAuthentication.createdTime.doubleTypeParam= -fileAuthentication.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -fileAuthentication.createdTime.defaultValue= -fileAuthentication.updatedBy.requiredParam= -fileAuthentication.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -fileAuthentication.updatedBy.annotation= -fileAuthentication.updatedBy.enableJavaType=true -fileAuthentication.updatedBy.longTypeParam= -fileAuthentication.updatedBy.integerTypeParam= -fileAuthentication.updatedBy.shortTypeParam= -fileAuthentication.updatedBy.byteTypeParam= -fileAuthentication.updatedBy.floatTypeParam= -fileAuthentication.updatedBy.doubleTypeParam= -fileAuthentication.updatedBy.dateTypeParam= -fileAuthentication.updatedBy.defaultValue= -fileAuthentication.updatedTime.requiredParam= -fileAuthentication.updatedTime.additionalAnnotation= -fileAuthentication.updatedTime.annotation= -fileAuthentication.updatedTime.enableJavaType=true -fileAuthentication.updatedTime.longTypeParam= -fileAuthentication.updatedTime.integerTypeParam= -fileAuthentication.updatedTime.shortTypeParam= -fileAuthentication.updatedTime.byteTypeParam= -fileAuthentication.updatedTime.floatTypeParam= -fileAuthentication.updatedTime.doubleTypeParam= -fileAuthentication.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -fileAuthentication.updatedTime.defaultValue= -fileAuthentication.deletedBy.requiredParam= -fileAuthentication.deletedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -fileAuthentication.deletedBy.annotation= -fileAuthentication.deletedBy.enableJavaType=true -fileAuthentication.deletedBy.longTypeParam= -fileAuthentication.deletedBy.integerTypeParam= -fileAuthentication.deletedBy.shortTypeParam= -fileAuthentication.deletedBy.byteTypeParam= -fileAuthentication.deletedBy.floatTypeParam= -fileAuthentication.deletedBy.doubleTypeParam= -fileAuthentication.deletedBy.dateTypeParam= -fileAuthentication.deletedBy.defaultValue= -fileAuthentication.deletedTime.requiredParam= -fileAuthentication.deletedTime.additionalAnnotation= -fileAuthentication.deletedTime.annotation= -fileAuthentication.deletedTime.enableJavaType=true -fileAuthentication.deletedTime.longTypeParam= -fileAuthentication.deletedTime.integerTypeParam= -fileAuthentication.deletedTime.shortTypeParam= -fileAuthentication.deletedTime.byteTypeParam= -fileAuthentication.deletedTime.floatTypeParam= -fileAuthentication.deletedTime.doubleTypeParam= -fileAuthentication.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -fileAuthentication.deletedTime.defaultValue= -fileAuthentication.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -fileAuthentication.versionNo.additionalAnnotation= -fileAuthentication.versionNo.annotation= -fileAuthentication.versionNo.enableJavaType=true -fileAuthentication.versionNo.longTypeParam= -fileAuthentication.versionNo.integerTypeParam= -fileAuthentication.versionNo.shortTypeParam= -fileAuthentication.versionNo.byteTypeParam= -fileAuthentication.versionNo.floatTypeParam= -fileAuthentication.versionNo.doubleTypeParam= -fileAuthentication.versionNo.dateTypeParam= -fileAuthentication.versionNo.defaultValue= - -fileConfigToLabelTypeMapping.ignored=true - -fileConfigToRoleTypeMapping.ignored=true - -fileCrawlingConfig.ignored=false -fileCrawlingConfig.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.FloatRange; -fileCrawlingConfig.converterToSearchParams= -fileCrawlingConfig.converterToPager= -fileCrawlingConfig.converterToActionForm= -fileCrawlingConfig.converterToEntity= -fileCrawlingConfig.id.requiredParam= -fileCrawlingConfig.id.additionalAnnotation= -fileCrawlingConfig.id.annotation= -fileCrawlingConfig.id.enableJavaType=true -fileCrawlingConfig.id.longTypeParam= -fileCrawlingConfig.id.integerTypeParam= -fileCrawlingConfig.id.shortTypeParam= -fileCrawlingConfig.id.byteTypeParam= -fileCrawlingConfig.id.floatTypeParam= -fileCrawlingConfig.id.doubleTypeParam= -fileCrawlingConfig.id.dateTypeParam= -fileCrawlingConfig.id.defaultValue= -fileCrawlingConfig.name.requiredParam= -fileCrawlingConfig.name.additionalAnnotation=@Maxbytelength(maxbytelength = 200) -fileCrawlingConfig.name.annotation= -fileCrawlingConfig.name.enableJavaType=true -fileCrawlingConfig.name.longTypeParam= -fileCrawlingConfig.name.integerTypeParam= -fileCrawlingConfig.name.shortTypeParam= -fileCrawlingConfig.name.byteTypeParam= -fileCrawlingConfig.name.floatTypeParam= -fileCrawlingConfig.name.doubleTypeParam= -fileCrawlingConfig.name.dateTypeParam= -fileCrawlingConfig.name.defaultValue= -fileCrawlingConfig.paths.requiredParam=(target = "confirmfromcreate,create,confirmfromupdate,update,delete") -fileCrawlingConfig.paths.additionalAnnotation=@UriType(protocols = "file:,smb:")@Maxbytelength(maxbytelength = 4000) -fileCrawlingConfig.paths.annotation= -fileCrawlingConfig.paths.enableJavaType=true -fileCrawlingConfig.paths.longTypeParam= -fileCrawlingConfig.paths.integerTypeParam= -fileCrawlingConfig.paths.shortTypeParam= -fileCrawlingConfig.paths.byteTypeParam= -fileCrawlingConfig.paths.floatTypeParam= -fileCrawlingConfig.paths.doubleTypeParam= -fileCrawlingConfig.paths.dateTypeParam= -fileCrawlingConfig.paths.defaultValue= -fileCrawlingConfig.includedPaths.requiredParam= -fileCrawlingConfig.includedPaths.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -fileCrawlingConfig.includedPaths.annotation= -fileCrawlingConfig.includedPaths.enableJavaType=true -fileCrawlingConfig.includedPaths.longTypeParam= -fileCrawlingConfig.includedPaths.integerTypeParam= -fileCrawlingConfig.includedPaths.shortTypeParam= -fileCrawlingConfig.includedPaths.byteTypeParam= -fileCrawlingConfig.includedPaths.floatTypeParam= -fileCrawlingConfig.includedPaths.doubleTypeParam= -fileCrawlingConfig.includedPaths.dateTypeParam= -fileCrawlingConfig.includedPaths.defaultValue= -fileCrawlingConfig.excludedPaths.requiredParam= -fileCrawlingConfig.excludedPaths.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -fileCrawlingConfig.excludedPaths.annotation= -fileCrawlingConfig.excludedPaths.enableJavaType=true -fileCrawlingConfig.excludedPaths.longTypeParam= -fileCrawlingConfig.excludedPaths.integerTypeParam= -fileCrawlingConfig.excludedPaths.shortTypeParam= -fileCrawlingConfig.excludedPaths.byteTypeParam= -fileCrawlingConfig.excludedPaths.floatTypeParam= -fileCrawlingConfig.excludedPaths.doubleTypeParam= -fileCrawlingConfig.excludedPaths.dateTypeParam= -fileCrawlingConfig.excludedPaths.defaultValue= -fileCrawlingConfig.includedDocPaths.requiredParam= -fileCrawlingConfig.includedDocPaths.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -fileCrawlingConfig.includedDocPaths.annotation= -fileCrawlingConfig.includedDocPaths.enableJavaType=true -fileCrawlingConfig.includedDocPaths.longTypeParam= -fileCrawlingConfig.includedDocPaths.integerTypeParam= -fileCrawlingConfig.includedDocPaths.shortTypeParam= -fileCrawlingConfig.includedDocPaths.byteTypeParam= -fileCrawlingConfig.includedDocPaths.floatTypeParam= -fileCrawlingConfig.includedDocPaths.doubleTypeParam= -fileCrawlingConfig.includedDocPaths.dateTypeParam= -fileCrawlingConfig.includedDocPaths.defaultValue= -fileCrawlingConfig.excludedDocPaths.requiredParam= -fileCrawlingConfig.excludedDocPaths.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -fileCrawlingConfig.excludedDocPaths.annotation= -fileCrawlingConfig.excludedDocPaths.enableJavaType=true -fileCrawlingConfig.excludedDocPaths.longTypeParam= -fileCrawlingConfig.excludedDocPaths.integerTypeParam= -fileCrawlingConfig.excludedDocPaths.shortTypeParam= -fileCrawlingConfig.excludedDocPaths.byteTypeParam= -fileCrawlingConfig.excludedDocPaths.floatTypeParam= -fileCrawlingConfig.excludedDocPaths.doubleTypeParam= -fileCrawlingConfig.excludedDocPaths.dateTypeParam= -fileCrawlingConfig.excludedDocPaths.defaultValue= -fileCrawlingConfig.configParameter.requiredParam= -fileCrawlingConfig.configParameter.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -fileCrawlingConfig.configParameter.annotation= -fileCrawlingConfig.configParameter.enableJavaType=true -fileCrawlingConfig.configParameter.longTypeParam= -fileCrawlingConfig.configParameter.integerTypeParam= -fileCrawlingConfig.configParameter.shortTypeParam= -fileCrawlingConfig.configParameter.byteTypeParam= -fileCrawlingConfig.configParameter.floatTypeParam= -fileCrawlingConfig.configParameter.doubleTypeParam= -fileCrawlingConfig.configParameter.dateTypeParam= -fileCrawlingConfig.configParameter.defaultValue= -fileCrawlingConfig.depth.requiredParam= -fileCrawlingConfig.depth.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -fileCrawlingConfig.depth.annotation= -fileCrawlingConfig.depth.enableJavaType=false -fileCrawlingConfig.depth.longTypeParam= -fileCrawlingConfig.depth.integerTypeParam= -fileCrawlingConfig.depth.shortTypeParam= -fileCrawlingConfig.depth.byteTypeParam= -fileCrawlingConfig.depth.floatTypeParam= -fileCrawlingConfig.depth.doubleTypeParam= -fileCrawlingConfig.depth.dateTypeParam= -fileCrawlingConfig.depth.defaultValue= -fileCrawlingConfig.maxAccessCount.requiredParam= -fileCrawlingConfig.maxAccessCount.additionalAnnotation=@LongRange(min = 0, max = 9223372036854775807l) -fileCrawlingConfig.maxAccessCount.annotation= -fileCrawlingConfig.maxAccessCount.enableJavaType=false -fileCrawlingConfig.maxAccessCount.longTypeParam= -fileCrawlingConfig.maxAccessCount.integerTypeParam= -fileCrawlingConfig.maxAccessCount.shortTypeParam= -fileCrawlingConfig.maxAccessCount.byteTypeParam= -fileCrawlingConfig.maxAccessCount.floatTypeParam= -fileCrawlingConfig.maxAccessCount.doubleTypeParam= -fileCrawlingConfig.maxAccessCount.dateTypeParam= -fileCrawlingConfig.maxAccessCount.defaultValue= -fileCrawlingConfig.numOfThread.requiredParam= -fileCrawlingConfig.numOfThread.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -fileCrawlingConfig.numOfThread.annotation= -fileCrawlingConfig.numOfThread.enableJavaType=false -fileCrawlingConfig.numOfThread.longTypeParam= -fileCrawlingConfig.numOfThread.integerTypeParam= -fileCrawlingConfig.numOfThread.shortTypeParam= -fileCrawlingConfig.numOfThread.byteTypeParam= -fileCrawlingConfig.numOfThread.floatTypeParam= -fileCrawlingConfig.numOfThread.doubleTypeParam= -fileCrawlingConfig.numOfThread.dateTypeParam= -fileCrawlingConfig.numOfThread.defaultValue= -fileCrawlingConfig.intervalTime.requiredParam= -fileCrawlingConfig.intervalTime.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -fileCrawlingConfig.intervalTime.annotation= -fileCrawlingConfig.intervalTime.enableJavaType=false -fileCrawlingConfig.intervalTime.longTypeParam= -fileCrawlingConfig.intervalTime.integerTypeParam= -fileCrawlingConfig.intervalTime.shortTypeParam= -fileCrawlingConfig.intervalTime.byteTypeParam= -fileCrawlingConfig.intervalTime.floatTypeParam= -fileCrawlingConfig.intervalTime.doubleTypeParam= -fileCrawlingConfig.intervalTime.dateTypeParam= -fileCrawlingConfig.intervalTime.defaultValue= -fileCrawlingConfig.boost.requiredParam= -fileCrawlingConfig.boost.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -fileCrawlingConfig.boost.annotation= -fileCrawlingConfig.boost.enableJavaType=false -fileCrawlingConfig.boost.longTypeParam= -fileCrawlingConfig.boost.integerTypeParam= -fileCrawlingConfig.boost.shortTypeParam= -fileCrawlingConfig.boost.byteTypeParam= -fileCrawlingConfig.boost.floatTypeParam= -fileCrawlingConfig.boost.doubleTypeParam= -fileCrawlingConfig.boost.dateTypeParam= -fileCrawlingConfig.boost.defaultValue="1" -fileCrawlingConfig.available.requiredParam= -fileCrawlingConfig.available.additionalAnnotation=@Maxbytelength(maxbytelength = 1) -fileCrawlingConfig.available.annotation= -fileCrawlingConfig.available.enableJavaType=true -fileCrawlingConfig.available.longTypeParam= -fileCrawlingConfig.available.integerTypeParam= -fileCrawlingConfig.available.shortTypeParam= -fileCrawlingConfig.available.byteTypeParam= -fileCrawlingConfig.available.floatTypeParam= -fileCrawlingConfig.available.doubleTypeParam= -fileCrawlingConfig.available.dateTypeParam= -fileCrawlingConfig.available.defaultValue= -fileCrawlingConfig.sortOrder.requiredParam=(target = "confirmfromupdate,update,delete") -fileCrawlingConfig.sortOrder.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -fileCrawlingConfig.sortOrder.annotation= -fileCrawlingConfig.sortOrder.enableJavaType=true -fileCrawlingConfig.sortOrder.longTypeParam= -fileCrawlingConfig.sortOrder.integerTypeParam= -fileCrawlingConfig.sortOrder.shortTypeParam= -fileCrawlingConfig.sortOrder.byteTypeParam= -fileCrawlingConfig.sortOrder.floatTypeParam= -fileCrawlingConfig.sortOrder.doubleTypeParam= -fileCrawlingConfig.sortOrder.dateTypeParam= -fileCrawlingConfig.sortOrder.defaultValue= -fileCrawlingConfig.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -fileCrawlingConfig.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -fileCrawlingConfig.createdBy.annotation= -fileCrawlingConfig.createdBy.enableJavaType=true -fileCrawlingConfig.createdBy.longTypeParam= -fileCrawlingConfig.createdBy.integerTypeParam= -fileCrawlingConfig.createdBy.shortTypeParam= -fileCrawlingConfig.createdBy.byteTypeParam= -fileCrawlingConfig.createdBy.floatTypeParam= -fileCrawlingConfig.createdBy.doubleTypeParam= -fileCrawlingConfig.createdBy.dateTypeParam= -fileCrawlingConfig.createdBy.defaultValue= -fileCrawlingConfig.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -fileCrawlingConfig.createdTime.additionalAnnotation= -fileCrawlingConfig.createdTime.annotation= -fileCrawlingConfig.createdTime.enableJavaType=true -fileCrawlingConfig.createdTime.longTypeParam= -fileCrawlingConfig.createdTime.integerTypeParam= -fileCrawlingConfig.createdTime.shortTypeParam= -fileCrawlingConfig.createdTime.byteTypeParam= -fileCrawlingConfig.createdTime.floatTypeParam= -fileCrawlingConfig.createdTime.doubleTypeParam= -fileCrawlingConfig.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -fileCrawlingConfig.createdTime.defaultValue= -fileCrawlingConfig.updatedBy.requiredParam= -fileCrawlingConfig.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -fileCrawlingConfig.updatedBy.annotation= -fileCrawlingConfig.updatedBy.enableJavaType=true -fileCrawlingConfig.updatedBy.longTypeParam= -fileCrawlingConfig.updatedBy.integerTypeParam= -fileCrawlingConfig.updatedBy.shortTypeParam= -fileCrawlingConfig.updatedBy.byteTypeParam= -fileCrawlingConfig.updatedBy.floatTypeParam= -fileCrawlingConfig.updatedBy.doubleTypeParam= -fileCrawlingConfig.updatedBy.dateTypeParam= -fileCrawlingConfig.updatedBy.defaultValue= -fileCrawlingConfig.updatedTime.requiredParam= -fileCrawlingConfig.updatedTime.additionalAnnotation= -fileCrawlingConfig.updatedTime.annotation= -fileCrawlingConfig.updatedTime.enableJavaType=true -fileCrawlingConfig.updatedTime.longTypeParam= -fileCrawlingConfig.updatedTime.integerTypeParam= -fileCrawlingConfig.updatedTime.shortTypeParam= -fileCrawlingConfig.updatedTime.byteTypeParam= -fileCrawlingConfig.updatedTime.floatTypeParam= -fileCrawlingConfig.updatedTime.doubleTypeParam= -fileCrawlingConfig.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -fileCrawlingConfig.updatedTime.defaultValue= -fileCrawlingConfig.deletedBy.requiredParam= -fileCrawlingConfig.deletedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -fileCrawlingConfig.deletedBy.annotation= -fileCrawlingConfig.deletedBy.enableJavaType=true -fileCrawlingConfig.deletedBy.longTypeParam= -fileCrawlingConfig.deletedBy.integerTypeParam= -fileCrawlingConfig.deletedBy.shortTypeParam= -fileCrawlingConfig.deletedBy.byteTypeParam= -fileCrawlingConfig.deletedBy.floatTypeParam= -fileCrawlingConfig.deletedBy.doubleTypeParam= -fileCrawlingConfig.deletedBy.dateTypeParam= -fileCrawlingConfig.deletedBy.defaultValue= -fileCrawlingConfig.deletedTime.requiredParam= -fileCrawlingConfig.deletedTime.additionalAnnotation= -fileCrawlingConfig.deletedTime.annotation= -fileCrawlingConfig.deletedTime.enableJavaType=true -fileCrawlingConfig.deletedTime.longTypeParam= -fileCrawlingConfig.deletedTime.integerTypeParam= -fileCrawlingConfig.deletedTime.shortTypeParam= -fileCrawlingConfig.deletedTime.byteTypeParam= -fileCrawlingConfig.deletedTime.floatTypeParam= -fileCrawlingConfig.deletedTime.doubleTypeParam= -fileCrawlingConfig.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -fileCrawlingConfig.deletedTime.defaultValue= -fileCrawlingConfig.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -fileCrawlingConfig.versionNo.additionalAnnotation= -fileCrawlingConfig.versionNo.annotation= -fileCrawlingConfig.versionNo.enableJavaType=true -fileCrawlingConfig.versionNo.longTypeParam= -fileCrawlingConfig.versionNo.integerTypeParam= -fileCrawlingConfig.versionNo.shortTypeParam= -fileCrawlingConfig.versionNo.byteTypeParam= -fileCrawlingConfig.versionNo.floatTypeParam= -fileCrawlingConfig.versionNo.doubleTypeParam= -fileCrawlingConfig.versionNo.dateTypeParam= -fileCrawlingConfig.versionNo.defaultValue= - -jobLog.ignored=false -jobLog.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.Mask;import org.seasar.struts.annotation.Msg; -jobLog.converterToSearchParams= -jobLog.converterToPager= -jobLog.converterToActionForm= -jobLog.converterToEntity= -jobLog.id.requiredParam= -jobLog.id.additionalAnnotation= -jobLog.id.annotation= -jobLog.id.enableJavaType=true -jobLog.id.longTypeParam= -jobLog.id.integerTypeParam= -jobLog.id.shortTypeParam= -jobLog.id.byteTypeParam= -jobLog.id.floatTypeParam= -jobLog.id.doubleTypeParam= -jobLog.id.dateTypeParam= -jobLog.id.defaultValue= -jobLog.jobName.requiredParam= -jobLog.jobName.additionalAnnotation= -jobLog.jobName.annotation= -jobLog.jobName.enableJavaType=true -jobLog.jobName.longTypeParam= -jobLog.jobName.integerTypeParam= -jobLog.jobName.shortTypeParam= -jobLog.jobName.byteTypeParam= -jobLog.jobName.floatTypeParam= -jobLog.jobName.doubleTypeParam= -jobLog.jobName.dateTypeParam= -jobLog.jobName.defaultValue= -jobLog.jobStatus.requiredParam= -jobLog.jobStatus.additionalAnnotation= -jobLog.jobStatus.annotation= -jobLog.jobStatus.enableJavaType=true -jobLog.jobStatus.longTypeParam= -jobLog.jobStatus.integerTypeParam= -jobLog.jobStatus.shortTypeParam= -jobLog.jobStatus.byteTypeParam= -jobLog.jobStatus.floatTypeParam= -jobLog.jobStatus.doubleTypeParam= -jobLog.jobStatus.dateTypeParam= -jobLog.jobStatus.defaultValue= -jobLog.target.requiredParam= -jobLog.target.additionalAnnotation= -jobLog.target.annotation= -jobLog.target.enableJavaType=true -jobLog.target.longTypeParam= -jobLog.target.integerTypeParam= -jobLog.target.shortTypeParam= -jobLog.target.byteTypeParam= -jobLog.target.floatTypeParam= -jobLog.target.doubleTypeParam= -jobLog.target.dateTypeParam= -jobLog.target.defaultValue= -jobLog.scriptType.requiredParam= -jobLog.scriptType.additionalAnnotation= -jobLog.scriptType.annotation= -jobLog.scriptType.enableJavaType=true -jobLog.scriptType.longTypeParam= -jobLog.scriptType.integerTypeParam= -jobLog.scriptType.shortTypeParam= -jobLog.scriptType.byteTypeParam= -jobLog.scriptType.floatTypeParam= -jobLog.scriptType.doubleTypeParam= -jobLog.scriptType.dateTypeParam= -jobLog.scriptType.defaultValue= -jobLog.scriptData.requiredParam= -jobLog.scriptData.additionalAnnotation= -jobLog.scriptData.annotation= -jobLog.scriptData.enableJavaType=true -jobLog.scriptData.longTypeParam= -jobLog.scriptData.integerTypeParam= -jobLog.scriptData.shortTypeParam= -jobLog.scriptData.byteTypeParam= -jobLog.scriptData.floatTypeParam= -jobLog.scriptData.doubleTypeParam= -jobLog.scriptData.dateTypeParam= -jobLog.scriptData.defaultValue= -jobLog.scriptResult.requiredParam= -jobLog.scriptResult.additionalAnnotation= -jobLog.scriptResult.annotation= -jobLog.scriptResult.enableJavaType=true -jobLog.scriptResult.longTypeParam= -jobLog.scriptResult.integerTypeParam= -jobLog.scriptResult.shortTypeParam= -jobLog.scriptResult.byteTypeParam= -jobLog.scriptResult.floatTypeParam= -jobLog.scriptResult.doubleTypeParam= -jobLog.scriptResult.dateTypeParam= -jobLog.scriptResult.defaultValue= -jobLog.startTime.requiredParam= -jobLog.startTime.additionalAnnotation= -jobLog.startTime.annotation= -jobLog.startTime.enableJavaType=true -jobLog.startTime.longTypeParam= -jobLog.startTime.integerTypeParam= -jobLog.startTime.shortTypeParam= -jobLog.startTime.byteTypeParam= -jobLog.startTime.floatTypeParam= -jobLog.startTime.doubleTypeParam= -jobLog.startTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -jobLog.startTime.defaultValue= -jobLog.endTime.requiredParam= -jobLog.endTime.additionalAnnotation= -jobLog.endTime.annotation= -jobLog.endTime.enableJavaType=true -jobLog.endTime.longTypeParam= -jobLog.endTime.integerTypeParam= -jobLog.endTime.shortTypeParam= -jobLog.endTime.byteTypeParam= -jobLog.endTime.floatTypeParam= -jobLog.endTime.doubleTypeParam= -jobLog.endTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -jobLog.endTime.defaultValue= - -keyMatch.ignored=false -keyMatch.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange; -keyMatch.converterToSearchParams= -keyMatch.converterToPager= -keyMatch.converterToActionForm= -keyMatch.converterToEntity= -keyMatch.id.requiredParam= -keyMatch.id.additionalAnnotation= -keyMatch.id.annotation= -keyMatch.id.enableJavaType=true -keyMatch.id.longTypeParam= -keyMatch.id.integerTypeParam= -keyMatch.id.shortTypeParam= -keyMatch.id.byteTypeParam= -keyMatch.id.floatTypeParam= -keyMatch.id.doubleTypeParam= -keyMatch.id.dateTypeParam= -keyMatch.id.defaultValue= -keyMatch.term.requiredParam= -keyMatch.term.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -keyMatch.term.annotation= -keyMatch.term.enableJavaType=true -keyMatch.term.longTypeParam= -keyMatch.term.integerTypeParam= -keyMatch.term.shortTypeParam= -keyMatch.term.byteTypeParam= -keyMatch.term.floatTypeParam= -keyMatch.term.doubleTypeParam= -keyMatch.term.dateTypeParam= -keyMatch.term.defaultValue= -keyMatch.query.requiredParam= -keyMatch.query.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -keyMatch.query.annotation= -keyMatch.query.enableJavaType=true -keyMatch.query.longTypeParam= -keyMatch.query.integerTypeParam= -keyMatch.query.shortTypeParam= -keyMatch.query.byteTypeParam= -keyMatch.query.floatTypeParam= -keyMatch.query.doubleTypeParam= -keyMatch.query.dateTypeParam= -keyMatch.query.defaultValue= -keyMatch.maxSize.requiredParam= -keyMatch.maxSize.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -keyMatch.maxSize.annotation= -keyMatch.maxSize.enableJavaType=true -keyMatch.maxSize.longTypeParam= -keyMatch.maxSize.integerTypeParam= -keyMatch.maxSize.shortTypeParam= -keyMatch.maxSize.byteTypeParam= -keyMatch.maxSize.floatTypeParam= -keyMatch.maxSize.doubleTypeParam= -keyMatch.maxSize.dateTypeParam= -keyMatch.maxSize.defaultValue= -keyMatch.boost.requiredParam= -keyMatch.boost.additionalAnnotation= -keyMatch.boost.annotation= -keyMatch.boost.enableJavaType=true -keyMatch.boost.longTypeParam= -keyMatch.boost.integerTypeParam= -keyMatch.boost.shortTypeParam= -keyMatch.boost.byteTypeParam= -keyMatch.boost.floatTypeParam= -keyMatch.boost.doubleTypeParam= -keyMatch.boost.dateTypeParam= -keyMatch.boost.defaultValue= -keyMatch.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -keyMatch.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -keyMatch.createdBy.annotation= -keyMatch.createdBy.enableJavaType=true -keyMatch.createdBy.longTypeParam= -keyMatch.createdBy.integerTypeParam= -keyMatch.createdBy.shortTypeParam= -keyMatch.createdBy.byteTypeParam= -keyMatch.createdBy.floatTypeParam= -keyMatch.createdBy.doubleTypeParam= -keyMatch.createdBy.dateTypeParam= -keyMatch.createdBy.defaultValue= -keyMatch.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -keyMatch.createdTime.additionalAnnotation= -keyMatch.createdTime.annotation= -keyMatch.createdTime.enableJavaType=true -keyMatch.createdTime.longTypeParam= -keyMatch.createdTime.integerTypeParam= -keyMatch.createdTime.shortTypeParam= -keyMatch.createdTime.byteTypeParam= -keyMatch.createdTime.floatTypeParam= -keyMatch.createdTime.doubleTypeParam= -keyMatch.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -keyMatch.createdTime.defaultValue= -keyMatch.updatedBy.requiredParam= -keyMatch.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -keyMatch.updatedBy.annotation= -keyMatch.updatedBy.enableJavaType=true -keyMatch.updatedBy.longTypeParam= -keyMatch.updatedBy.integerTypeParam= -keyMatch.updatedBy.shortTypeParam= -keyMatch.updatedBy.byteTypeParam= -keyMatch.updatedBy.floatTypeParam= -keyMatch.updatedBy.doubleTypeParam= -keyMatch.updatedBy.dateTypeParam= -keyMatch.updatedBy.defaultValue= -keyMatch.updatedTime.requiredParam= -keyMatch.updatedTime.additionalAnnotation= -keyMatch.updatedTime.annotation= -keyMatch.updatedTime.enableJavaType=true -keyMatch.updatedTime.longTypeParam= -keyMatch.updatedTime.integerTypeParam= -keyMatch.updatedTime.shortTypeParam= -keyMatch.updatedTime.byteTypeParam= -keyMatch.updatedTime.floatTypeParam= -keyMatch.updatedTime.doubleTypeParam= -keyMatch.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -keyMatch.updatedTime.defaultValue= -keyMatch.deletedBy.requiredParam= -keyMatch.deletedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -keyMatch.deletedBy.annotation= -keyMatch.deletedBy.enableJavaType=true -keyMatch.deletedBy.longTypeParam= -keyMatch.deletedBy.integerTypeParam= -keyMatch.deletedBy.shortTypeParam= -keyMatch.deletedBy.byteTypeParam= -keyMatch.deletedBy.floatTypeParam= -keyMatch.deletedBy.doubleTypeParam= -keyMatch.deletedBy.dateTypeParam= -keyMatch.deletedBy.defaultValue= -keyMatch.deletedTime.requiredParam= -keyMatch.deletedTime.additionalAnnotation= -keyMatch.deletedTime.annotation= -keyMatch.deletedTime.enableJavaType=true -keyMatch.deletedTime.longTypeParam= -keyMatch.deletedTime.integerTypeParam= -keyMatch.deletedTime.shortTypeParam= -keyMatch.deletedTime.byteTypeParam= -keyMatch.deletedTime.floatTypeParam= -keyMatch.deletedTime.doubleTypeParam= -keyMatch.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -keyMatch.deletedTime.defaultValue= -keyMatch.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -keyMatch.versionNo.additionalAnnotation= -keyMatch.versionNo.annotation= -keyMatch.versionNo.enableJavaType=true -keyMatch.versionNo.longTypeParam= -keyMatch.versionNo.integerTypeParam= -keyMatch.versionNo.shortTypeParam= -keyMatch.versionNo.byteTypeParam= -keyMatch.versionNo.floatTypeParam= -keyMatch.versionNo.doubleTypeParam= -keyMatch.versionNo.dateTypeParam= -keyMatch.versionNo.defaultValue= - -labelType.ignored=false -labelType.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.Mask;import org.seasar.struts.annotation.Msg; -labelType.converterToSearchParams= -labelType.converterToPager= -labelType.converterToActionForm= -labelType.converterToEntity= -labelType.id.requiredParam= -labelType.id.additionalAnnotation= -labelType.id.annotation= -labelType.id.enableJavaType=true -labelType.id.longTypeParam= -labelType.id.integerTypeParam= -labelType.id.shortTypeParam= -labelType.id.byteTypeParam= -labelType.id.floatTypeParam= -labelType.id.doubleTypeParam= -labelType.id.dateTypeParam= -labelType.id.defaultValue= -labelType.name.requiredParam= -labelType.name.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -labelType.name.annotation= -labelType.name.enableJavaType=true -labelType.name.longTypeParam= -labelType.name.integerTypeParam= -labelType.name.shortTypeParam= -labelType.name.byteTypeParam= -labelType.name.floatTypeParam= -labelType.name.doubleTypeParam= -labelType.name.dateTypeParam= -labelType.name.defaultValue= -labelType.value.requiredParam= -labelType.value.additionalAnnotation=@Maxbytelength(maxbytelength = 20)@Mask(mask="^[a-zA-Z0-9_-]+$", msg = @Msg(key="errors.alphaDigitOnly")) -labelType.value.annotation= -labelType.value.enableJavaType=true -labelType.value.longTypeParam= -labelType.value.integerTypeParam= -labelType.value.shortTypeParam= -labelType.value.byteTypeParam= -labelType.value.floatTypeParam= -labelType.value.doubleTypeParam= -labelType.value.dateTypeParam= -labelType.value.defaultValue= -labelType.includedPaths.requiredParam= -labelType.includedPaths.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -labelType.includedPaths.annotation= -labelType.includedPaths.enableJavaType=true -labelType.includedPaths.longTypeParam= -labelType.includedPaths.integerTypeParam= -labelType.includedPaths.shortTypeParam= -labelType.includedPaths.byteTypeParam= -labelType.includedPaths.floatTypeParam= -labelType.includedPaths.doubleTypeParam= -labelType.includedPaths.dateTypeParam= -labelType.includedPaths.defaultValue= -labelType.excludedPaths.requiredParam= -labelType.excludedPaths.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -labelType.excludedPaths.annotation= -labelType.excludedPaths.enableJavaType=true -labelType.excludedPaths.longTypeParam= -labelType.excludedPaths.integerTypeParam= -labelType.excludedPaths.shortTypeParam= -labelType.excludedPaths.byteTypeParam= -labelType.excludedPaths.floatTypeParam= -labelType.excludedPaths.doubleTypeParam= -labelType.excludedPaths.dateTypeParam= -labelType.excludedPaths.defaultValue= -labelType.sortOrder.requiredParam=(target = "confirmfromupdate,update,delete") -labelType.sortOrder.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -labelType.sortOrder.annotation= -labelType.sortOrder.enableJavaType=false -labelType.sortOrder.longTypeParam= -labelType.sortOrder.integerTypeParam= -labelType.sortOrder.shortTypeParam= -labelType.sortOrder.byteTypeParam= -labelType.sortOrder.floatTypeParam= -labelType.sortOrder.doubleTypeParam= -labelType.sortOrder.dateTypeParam= -labelType.sortOrder.defaultValue= -labelType.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -labelType.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -labelType.createdBy.annotation= -labelType.createdBy.enableJavaType=true -labelType.createdBy.longTypeParam= -labelType.createdBy.integerTypeParam= -labelType.createdBy.shortTypeParam= -labelType.createdBy.byteTypeParam= -labelType.createdBy.floatTypeParam= -labelType.createdBy.doubleTypeParam= -labelType.createdBy.dateTypeParam= -labelType.createdBy.defaultValue= -labelType.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -labelType.createdTime.additionalAnnotation= -labelType.createdTime.annotation= -labelType.createdTime.enableJavaType=true -labelType.createdTime.longTypeParam= -labelType.createdTime.integerTypeParam= -labelType.createdTime.shortTypeParam= -labelType.createdTime.byteTypeParam= -labelType.createdTime.floatTypeParam= -labelType.createdTime.doubleTypeParam= -labelType.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -labelType.createdTime.defaultValue= -labelType.updatedBy.requiredParam= -labelType.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -labelType.updatedBy.annotation= -labelType.updatedBy.enableJavaType=true -labelType.updatedBy.longTypeParam= -labelType.updatedBy.integerTypeParam= -labelType.updatedBy.shortTypeParam= -labelType.updatedBy.byteTypeParam= -labelType.updatedBy.floatTypeParam= -labelType.updatedBy.doubleTypeParam= -labelType.updatedBy.dateTypeParam= -labelType.updatedBy.defaultValue= -labelType.updatedTime.requiredParam= -labelType.updatedTime.additionalAnnotation= -labelType.updatedTime.annotation= -labelType.updatedTime.enableJavaType=true -labelType.updatedTime.longTypeParam= -labelType.updatedTime.integerTypeParam= -labelType.updatedTime.shortTypeParam= -labelType.updatedTime.byteTypeParam= -labelType.updatedTime.floatTypeParam= -labelType.updatedTime.doubleTypeParam= -labelType.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -labelType.updatedTime.defaultValue= -labelType.deletedBy.requiredParam= -labelType.deletedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -labelType.deletedBy.annotation= -labelType.deletedBy.enableJavaType=true -labelType.deletedBy.longTypeParam= -labelType.deletedBy.integerTypeParam= -labelType.deletedBy.shortTypeParam= -labelType.deletedBy.byteTypeParam= -labelType.deletedBy.floatTypeParam= -labelType.deletedBy.doubleTypeParam= -labelType.deletedBy.dateTypeParam= -labelType.deletedBy.defaultValue= -labelType.deletedTime.requiredParam= -labelType.deletedTime.additionalAnnotation= -labelType.deletedTime.annotation= -labelType.deletedTime.enableJavaType=true -labelType.deletedTime.longTypeParam= -labelType.deletedTime.integerTypeParam= -labelType.deletedTime.shortTypeParam= -labelType.deletedTime.byteTypeParam= -labelType.deletedTime.floatTypeParam= -labelType.deletedTime.doubleTypeParam= -labelType.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -labelType.deletedTime.defaultValue= -labelType.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -labelType.versionNo.additionalAnnotation= -labelType.versionNo.annotation= -labelType.versionNo.enableJavaType=true -labelType.versionNo.longTypeParam= -labelType.versionNo.integerTypeParam= -labelType.versionNo.shortTypeParam= -labelType.versionNo.byteTypeParam= -labelType.versionNo.floatTypeParam= -labelType.versionNo.doubleTypeParam= -labelType.versionNo.dateTypeParam= -labelType.versionNo.defaultValue= - -labelTypeToRoleTypeMapping.ignored=true - -overlappingHost.ignored=false -overlappingHost.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange; -overlappingHost.converterToSearchParams= -overlappingHost.converterToPager= -overlappingHost.converterToActionForm= -overlappingHost.converterToEntity= -overlappingHost.id.requiredParam= -overlappingHost.id.additionalAnnotation= -overlappingHost.id.annotation= -overlappingHost.id.enableJavaType=true -overlappingHost.id.longTypeParam= -overlappingHost.id.integerTypeParam= -overlappingHost.id.shortTypeParam= -overlappingHost.id.byteTypeParam= -overlappingHost.id.floatTypeParam= -overlappingHost.id.doubleTypeParam= -overlappingHost.id.dateTypeParam= -overlappingHost.id.defaultValue= -overlappingHost.regularName.requiredParam= -overlappingHost.regularName.additionalAnnotation=@Maxbytelength(maxbytelength = 1000) -overlappingHost.regularName.annotation= -overlappingHost.regularName.enableJavaType=true -overlappingHost.regularName.longTypeParam= -overlappingHost.regularName.integerTypeParam= -overlappingHost.regularName.shortTypeParam= -overlappingHost.regularName.byteTypeParam= -overlappingHost.regularName.floatTypeParam= -overlappingHost.regularName.doubleTypeParam= -overlappingHost.regularName.dateTypeParam= -overlappingHost.regularName.defaultValue= -overlappingHost.overlappingName.requiredParam= -overlappingHost.overlappingName.additionalAnnotation=@Maxbytelength(maxbytelength = 1000) -overlappingHost.overlappingName.annotation= -overlappingHost.overlappingName.enableJavaType=true -overlappingHost.overlappingName.longTypeParam= -overlappingHost.overlappingName.integerTypeParam= -overlappingHost.overlappingName.shortTypeParam= -overlappingHost.overlappingName.byteTypeParam= -overlappingHost.overlappingName.floatTypeParam= -overlappingHost.overlappingName.doubleTypeParam= -overlappingHost.overlappingName.dateTypeParam= -overlappingHost.overlappingName.defaultValue= -overlappingHost.sortOrder.requiredParam=(target = "confirmfromupdate,update,delete") -overlappingHost.sortOrder.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -overlappingHost.sortOrder.annotation= -overlappingHost.sortOrder.enableJavaType=false -overlappingHost.sortOrder.longTypeParam= -overlappingHost.sortOrder.integerTypeParam= -overlappingHost.sortOrder.shortTypeParam= -overlappingHost.sortOrder.byteTypeParam= -overlappingHost.sortOrder.floatTypeParam= -overlappingHost.sortOrder.doubleTypeParam= -overlappingHost.sortOrder.dateTypeParam= -overlappingHost.sortOrder.defaultValue= -overlappingHost.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -overlappingHost.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -overlappingHost.createdBy.annotation= -overlappingHost.createdBy.enableJavaType=true -overlappingHost.createdBy.longTypeParam= -overlappingHost.createdBy.integerTypeParam= -overlappingHost.createdBy.shortTypeParam= -overlappingHost.createdBy.byteTypeParam= -overlappingHost.createdBy.floatTypeParam= -overlappingHost.createdBy.doubleTypeParam= -overlappingHost.createdBy.dateTypeParam= -overlappingHost.createdBy.defaultValue= -overlappingHost.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -overlappingHost.createdTime.additionalAnnotation= -overlappingHost.createdTime.annotation= -overlappingHost.createdTime.enableJavaType=true -overlappingHost.createdTime.longTypeParam= -overlappingHost.createdTime.integerTypeParam= -overlappingHost.createdTime.shortTypeParam= -overlappingHost.createdTime.byteTypeParam= -overlappingHost.createdTime.floatTypeParam= -overlappingHost.createdTime.doubleTypeParam= -overlappingHost.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -overlappingHost.createdTime.defaultValue= -overlappingHost.updatedBy.requiredParam= -overlappingHost.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -overlappingHost.updatedBy.annotation= -overlappingHost.updatedBy.enableJavaType=true -overlappingHost.updatedBy.longTypeParam= -overlappingHost.updatedBy.integerTypeParam= -overlappingHost.updatedBy.shortTypeParam= -overlappingHost.updatedBy.byteTypeParam= -overlappingHost.updatedBy.floatTypeParam= -overlappingHost.updatedBy.doubleTypeParam= -overlappingHost.updatedBy.dateTypeParam= -overlappingHost.updatedBy.defaultValue= -overlappingHost.updatedTime.requiredParam= -overlappingHost.updatedTime.additionalAnnotation= -overlappingHost.updatedTime.annotation= -overlappingHost.updatedTime.enableJavaType=true -overlappingHost.updatedTime.longTypeParam= -overlappingHost.updatedTime.integerTypeParam= -overlappingHost.updatedTime.shortTypeParam= -overlappingHost.updatedTime.byteTypeParam= -overlappingHost.updatedTime.floatTypeParam= -overlappingHost.updatedTime.doubleTypeParam= -overlappingHost.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -overlappingHost.updatedTime.defaultValue= -overlappingHost.deletedBy.requiredParam= -overlappingHost.deletedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -overlappingHost.deletedBy.annotation= -overlappingHost.deletedBy.enableJavaType=true -overlappingHost.deletedBy.longTypeParam= -overlappingHost.deletedBy.integerTypeParam= -overlappingHost.deletedBy.shortTypeParam= -overlappingHost.deletedBy.byteTypeParam= -overlappingHost.deletedBy.floatTypeParam= -overlappingHost.deletedBy.doubleTypeParam= -overlappingHost.deletedBy.dateTypeParam= -overlappingHost.deletedBy.defaultValue= -overlappingHost.deletedTime.requiredParam= -overlappingHost.deletedTime.additionalAnnotation= -overlappingHost.deletedTime.annotation= -overlappingHost.deletedTime.enableJavaType=true -overlappingHost.deletedTime.longTypeParam= -overlappingHost.deletedTime.integerTypeParam= -overlappingHost.deletedTime.shortTypeParam= -overlappingHost.deletedTime.byteTypeParam= -overlappingHost.deletedTime.floatTypeParam= -overlappingHost.deletedTime.doubleTypeParam= -overlappingHost.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -overlappingHost.deletedTime.defaultValue= -overlappingHost.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -overlappingHost.versionNo.additionalAnnotation= -overlappingHost.versionNo.annotation= -overlappingHost.versionNo.enableJavaType=true -overlappingHost.versionNo.longTypeParam= -overlappingHost.versionNo.integerTypeParam= -overlappingHost.versionNo.shortTypeParam= -overlappingHost.versionNo.byteTypeParam= -overlappingHost.versionNo.floatTypeParam= -overlappingHost.versionNo.doubleTypeParam= -overlappingHost.versionNo.dateTypeParam= -overlappingHost.versionNo.defaultValue= - -pathMapping.ignored=false -pathMapping.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange; -pathMapping.converterToSearchParams= -pathMapping.converterToPager= -pathMapping.converterToActionForm= -pathMapping.converterToEntity= -pathMapping.id.requiredParam= -pathMapping.id.additionalAnnotation= -pathMapping.id.annotation= -pathMapping.id.enableJavaType=true -pathMapping.id.longTypeParam= -pathMapping.id.integerTypeParam= -pathMapping.id.shortTypeParam= -pathMapping.id.byteTypeParam= -pathMapping.id.floatTypeParam= -pathMapping.id.doubleTypeParam= -pathMapping.id.dateTypeParam= -pathMapping.id.defaultValue= -pathMapping.regex.requiredParam= -pathMapping.regex.additionalAnnotation=@Maxbytelength(maxbytelength = 1000) -pathMapping.regex.annotation= -pathMapping.regex.enableJavaType=true -pathMapping.regex.longTypeParam= -pathMapping.regex.integerTypeParam= -pathMapping.regex.shortTypeParam= -pathMapping.regex.byteTypeParam= -pathMapping.regex.floatTypeParam= -pathMapping.regex.doubleTypeParam= -pathMapping.regex.dateTypeParam= -pathMapping.regex.defaultValue= -pathMapping.replacement.requiredParam= -pathMapping.replacement.additionalAnnotation=@Maxbytelength(maxbytelength = 1000) -pathMapping.replacement.annotation= -pathMapping.replacement.enableJavaType=true -pathMapping.replacement.longTypeParam= -pathMapping.replacement.integerTypeParam= -pathMapping.replacement.shortTypeParam= -pathMapping.replacement.byteTypeParam= -pathMapping.replacement.floatTypeParam= -pathMapping.replacement.doubleTypeParam= -pathMapping.replacement.dateTypeParam= -pathMapping.replacement.defaultValue= -pathMapping.processType.requiredParam= -pathMapping.processType.additionalAnnotation= -pathMapping.processType.annotation= -pathMapping.processType.enableJavaType=true -pathMapping.processType.longTypeParam= -pathMapping.processType.integerTypeParam= -pathMapping.processType.shortTypeParam= -pathMapping.processType.byteTypeParam= -pathMapping.processType.floatTypeParam= -pathMapping.processType.doubleTypeParam= -pathMapping.processType.dateTypeParam= -pathMapping.processType.defaultValue= -pathMapping.sortOrder.requiredParam=(target = "confirmfromupdate,update,delete") -pathMapping.sortOrder.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -pathMapping.sortOrder.annotation= -pathMapping.sortOrder.enableJavaType=false -pathMapping.sortOrder.longTypeParam= -pathMapping.sortOrder.integerTypeParam= -pathMapping.sortOrder.shortTypeParam= -pathMapping.sortOrder.byteTypeParam= -pathMapping.sortOrder.floatTypeParam= -pathMapping.sortOrder.doubleTypeParam= -pathMapping.sortOrder.dateTypeParam= -pathMapping.sortOrder.defaultValue= -pathMapping.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -pathMapping.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -pathMapping.createdBy.annotation= -pathMapping.createdBy.enableJavaType=true -pathMapping.createdBy.longTypeParam= -pathMapping.createdBy.integerTypeParam= -pathMapping.createdBy.shortTypeParam= -pathMapping.createdBy.byteTypeParam= -pathMapping.createdBy.floatTypeParam= -pathMapping.createdBy.doubleTypeParam= -pathMapping.createdBy.dateTypeParam= -pathMapping.createdBy.defaultValue= -pathMapping.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -pathMapping.createdTime.additionalAnnotation= -pathMapping.createdTime.annotation= -pathMapping.createdTime.enableJavaType=true -pathMapping.createdTime.longTypeParam= -pathMapping.createdTime.integerTypeParam= -pathMapping.createdTime.shortTypeParam= -pathMapping.createdTime.byteTypeParam= -pathMapping.createdTime.floatTypeParam= -pathMapping.createdTime.doubleTypeParam= -pathMapping.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -pathMapping.createdTime.defaultValue= -pathMapping.updatedBy.requiredParam= -pathMapping.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -pathMapping.updatedBy.annotation= -pathMapping.updatedBy.enableJavaType=true -pathMapping.updatedBy.longTypeParam= -pathMapping.updatedBy.integerTypeParam= -pathMapping.updatedBy.shortTypeParam= -pathMapping.updatedBy.byteTypeParam= -pathMapping.updatedBy.floatTypeParam= -pathMapping.updatedBy.doubleTypeParam= -pathMapping.updatedBy.dateTypeParam= -pathMapping.updatedBy.defaultValue= -pathMapping.updatedTime.requiredParam= -pathMapping.updatedTime.additionalAnnotation= -pathMapping.updatedTime.annotation= -pathMapping.updatedTime.enableJavaType=true -pathMapping.updatedTime.longTypeParam= -pathMapping.updatedTime.integerTypeParam= -pathMapping.updatedTime.shortTypeParam= -pathMapping.updatedTime.byteTypeParam= -pathMapping.updatedTime.floatTypeParam= -pathMapping.updatedTime.doubleTypeParam= -pathMapping.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -pathMapping.updatedTime.defaultValue= -pathMapping.deletedBy.requiredParam= -pathMapping.deletedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -pathMapping.deletedBy.annotation= -pathMapping.deletedBy.enableJavaType=true -pathMapping.deletedBy.longTypeParam= -pathMapping.deletedBy.integerTypeParam= -pathMapping.deletedBy.shortTypeParam= -pathMapping.deletedBy.byteTypeParam= -pathMapping.deletedBy.floatTypeParam= -pathMapping.deletedBy.doubleTypeParam= -pathMapping.deletedBy.dateTypeParam= -pathMapping.deletedBy.defaultValue= -pathMapping.deletedTime.requiredParam= -pathMapping.deletedTime.additionalAnnotation= -pathMapping.deletedTime.annotation= -pathMapping.deletedTime.enableJavaType=true -pathMapping.deletedTime.longTypeParam= -pathMapping.deletedTime.integerTypeParam= -pathMapping.deletedTime.shortTypeParam= -pathMapping.deletedTime.byteTypeParam= -pathMapping.deletedTime.floatTypeParam= -pathMapping.deletedTime.doubleTypeParam= -pathMapping.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -pathMapping.deletedTime.defaultValue= -pathMapping.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -pathMapping.versionNo.additionalAnnotation= -pathMapping.versionNo.annotation= -pathMapping.versionNo.enableJavaType=true -pathMapping.versionNo.longTypeParam= -pathMapping.versionNo.integerTypeParam= -pathMapping.versionNo.shortTypeParam= -pathMapping.versionNo.byteTypeParam= -pathMapping.versionNo.floatTypeParam= -pathMapping.versionNo.doubleTypeParam= -pathMapping.versionNo.dateTypeParam= -pathMapping.versionNo.defaultValue= - -requestHeader.ignored=false -requestHeader.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange; -requestHeader.converterToSearchParams= -requestHeader.converterToPager= -requestHeader.converterToActionForm= -requestHeader.converterToEntity= -requestHeader.id.requiredParam= -requestHeader.id.additionalAnnotation= -requestHeader.id.annotation= -requestHeader.id.enableJavaType=true -requestHeader.id.longTypeParam= -requestHeader.id.integerTypeParam= -requestHeader.id.shortTypeParam= -requestHeader.id.byteTypeParam= -requestHeader.id.floatTypeParam= -requestHeader.id.doubleTypeParam= -requestHeader.id.dateTypeParam= -requestHeader.id.defaultValue= -requestHeader.name.requiredParam= -requestHeader.name.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -requestHeader.name.annotation= -requestHeader.name.enableJavaType=true -requestHeader.name.longTypeParam= -requestHeader.name.integerTypeParam= -requestHeader.name.shortTypeParam= -requestHeader.name.byteTypeParam= -requestHeader.name.floatTypeParam= -requestHeader.name.doubleTypeParam= -requestHeader.name.dateTypeParam= -requestHeader.name.defaultValue= -requestHeader.value.requiredParam= -requestHeader.value.additionalAnnotation=@Maxbytelength(maxbytelength = 1000) -requestHeader.value.annotation= -requestHeader.value.enableJavaType=true -requestHeader.value.longTypeParam= -requestHeader.value.integerTypeParam= -requestHeader.value.shortTypeParam= -requestHeader.value.byteTypeParam= -requestHeader.value.floatTypeParam= -requestHeader.value.doubleTypeParam= -requestHeader.value.dateTypeParam= -requestHeader.value.defaultValue= -requestHeader.webCrawlingConfigId.requiredParam= -requestHeader.webCrawlingConfigId.additionalAnnotation= -requestHeader.webCrawlingConfigId.annotation= -requestHeader.webCrawlingConfigId.enableJavaType=true -requestHeader.webCrawlingConfigId.longTypeParam= -requestHeader.webCrawlingConfigId.integerTypeParam= -requestHeader.webCrawlingConfigId.shortTypeParam= -requestHeader.webCrawlingConfigId.byteTypeParam= -requestHeader.webCrawlingConfigId.floatTypeParam= -requestHeader.webCrawlingConfigId.doubleTypeParam= -requestHeader.webCrawlingConfigId.dateTypeParam= -requestHeader.webCrawlingConfigId.defaultValue= -requestHeader.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -requestHeader.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -requestHeader.createdBy.annotation= -requestHeader.createdBy.enableJavaType=true -requestHeader.createdBy.longTypeParam= -requestHeader.createdBy.integerTypeParam= -requestHeader.createdBy.shortTypeParam= -requestHeader.createdBy.byteTypeParam= -requestHeader.createdBy.floatTypeParam= -requestHeader.createdBy.doubleTypeParam= -requestHeader.createdBy.dateTypeParam= -requestHeader.createdBy.defaultValue= -requestHeader.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -requestHeader.createdTime.additionalAnnotation= -requestHeader.createdTime.annotation= -requestHeader.createdTime.enableJavaType=true -requestHeader.createdTime.longTypeParam= -requestHeader.createdTime.integerTypeParam= -requestHeader.createdTime.shortTypeParam= -requestHeader.createdTime.byteTypeParam= -requestHeader.createdTime.floatTypeParam= -requestHeader.createdTime.doubleTypeParam= -requestHeader.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -requestHeader.createdTime.defaultValue= -requestHeader.updatedBy.requiredParam= -requestHeader.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -requestHeader.updatedBy.annotation= -requestHeader.updatedBy.enableJavaType=true -requestHeader.updatedBy.longTypeParam= -requestHeader.updatedBy.integerTypeParam= -requestHeader.updatedBy.shortTypeParam= -requestHeader.updatedBy.byteTypeParam= -requestHeader.updatedBy.floatTypeParam= -requestHeader.updatedBy.doubleTypeParam= -requestHeader.updatedBy.dateTypeParam= -requestHeader.updatedBy.defaultValue= -requestHeader.updatedTime.requiredParam= -requestHeader.updatedTime.additionalAnnotation= -requestHeader.updatedTime.annotation= -requestHeader.updatedTime.enableJavaType=true -requestHeader.updatedTime.longTypeParam= -requestHeader.updatedTime.integerTypeParam= -requestHeader.updatedTime.shortTypeParam= -requestHeader.updatedTime.byteTypeParam= -requestHeader.updatedTime.floatTypeParam= -requestHeader.updatedTime.doubleTypeParam= -requestHeader.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -requestHeader.updatedTime.defaultValue= -requestHeader.deletedBy.requiredParam= -requestHeader.deletedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -requestHeader.deletedBy.annotation= -requestHeader.deletedBy.enableJavaType=true -requestHeader.deletedBy.longTypeParam= -requestHeader.deletedBy.integerTypeParam= -requestHeader.deletedBy.shortTypeParam= -requestHeader.deletedBy.byteTypeParam= -requestHeader.deletedBy.floatTypeParam= -requestHeader.deletedBy.doubleTypeParam= -requestHeader.deletedBy.dateTypeParam= -requestHeader.deletedBy.defaultValue= -requestHeader.deletedTime.requiredParam= -requestHeader.deletedTime.additionalAnnotation= -requestHeader.deletedTime.annotation= -requestHeader.deletedTime.enableJavaType=true -requestHeader.deletedTime.longTypeParam= -requestHeader.deletedTime.integerTypeParam= -requestHeader.deletedTime.shortTypeParam= -requestHeader.deletedTime.byteTypeParam= -requestHeader.deletedTime.floatTypeParam= -requestHeader.deletedTime.doubleTypeParam= -requestHeader.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -requestHeader.deletedTime.defaultValue= -requestHeader.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -requestHeader.versionNo.additionalAnnotation= -requestHeader.versionNo.annotation= -requestHeader.versionNo.enableJavaType=true -requestHeader.versionNo.longTypeParam= -requestHeader.versionNo.integerTypeParam= -requestHeader.versionNo.shortTypeParam= -requestHeader.versionNo.byteTypeParam= -requestHeader.versionNo.floatTypeParam= -requestHeader.versionNo.doubleTypeParam= -requestHeader.versionNo.dateTypeParam= -requestHeader.versionNo.defaultValue= - -roleType.ignored=false -roleType.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.Mask;import org.seasar.struts.annotation.Msg; -roleType.converterToSearchParams= -roleType.converterToPager= -roleType.converterToActionForm= -roleType.converterToEntity= -roleType.id.requiredParam= -roleType.id.additionalAnnotation= -roleType.id.annotation= -roleType.id.enableJavaType=true -roleType.id.longTypeParam= -roleType.id.integerTypeParam= -roleType.id.shortTypeParam= -roleType.id.byteTypeParam= -roleType.id.floatTypeParam= -roleType.id.doubleTypeParam= -roleType.id.dateTypeParam= -roleType.id.defaultValue= -roleType.name.requiredParam= -roleType.name.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -roleType.name.annotation= -roleType.name.enableJavaType=true -roleType.name.longTypeParam= -roleType.name.integerTypeParam= -roleType.name.shortTypeParam= -roleType.name.byteTypeParam= -roleType.name.floatTypeParam= -roleType.name.doubleTypeParam= -roleType.name.dateTypeParam= -roleType.name.defaultValue= -roleType.value.requiredParam= -roleType.value.additionalAnnotation=@Maxbytelength(maxbytelength = 20)@Mask(mask="^[a-zA-Z0-9_-| ]+$", msg = @Msg(key="errors.alphaDigitSpaceOnly")) -roleType.value.annotation= -roleType.value.enableJavaType=true -roleType.value.longTypeParam= -roleType.value.integerTypeParam= -roleType.value.shortTypeParam= -roleType.value.byteTypeParam= -roleType.value.floatTypeParam= -roleType.value.doubleTypeParam= -roleType.value.dateTypeParam= -roleType.value.defaultValue= -roleType.sortOrder.requiredParam=(target = "confirmfromupdate,update,delete") -roleType.sortOrder.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -roleType.sortOrder.annotation= -roleType.sortOrder.enableJavaType=false -roleType.sortOrder.longTypeParam= -roleType.sortOrder.integerTypeParam= -roleType.sortOrder.shortTypeParam= -roleType.sortOrder.byteTypeParam= -roleType.sortOrder.floatTypeParam= -roleType.sortOrder.doubleTypeParam= -roleType.sortOrder.dateTypeParam= -roleType.sortOrder.defaultValue= -roleType.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -roleType.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -roleType.createdBy.annotation= -roleType.createdBy.enableJavaType=true -roleType.createdBy.longTypeParam= -roleType.createdBy.integerTypeParam= -roleType.createdBy.shortTypeParam= -roleType.createdBy.byteTypeParam= -roleType.createdBy.floatTypeParam= -roleType.createdBy.doubleTypeParam= -roleType.createdBy.dateTypeParam= -roleType.createdBy.defaultValue= -roleType.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -roleType.createdTime.additionalAnnotation= -roleType.createdTime.annotation= -roleType.createdTime.enableJavaType=true -roleType.createdTime.longTypeParam= -roleType.createdTime.integerTypeParam= -roleType.createdTime.shortTypeParam= -roleType.createdTime.byteTypeParam= -roleType.createdTime.floatTypeParam= -roleType.createdTime.doubleTypeParam= -roleType.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -roleType.createdTime.defaultValue= -roleType.updatedBy.requiredParam= -roleType.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -roleType.updatedBy.annotation= -roleType.updatedBy.enableJavaType=true -roleType.updatedBy.longTypeParam= -roleType.updatedBy.integerTypeParam= -roleType.updatedBy.shortTypeParam= -roleType.updatedBy.byteTypeParam= -roleType.updatedBy.floatTypeParam= -roleType.updatedBy.doubleTypeParam= -roleType.updatedBy.dateTypeParam= -roleType.updatedBy.defaultValue= -roleType.updatedTime.requiredParam= -roleType.updatedTime.additionalAnnotation= -roleType.updatedTime.annotation= -roleType.updatedTime.enableJavaType=true -roleType.updatedTime.longTypeParam= -roleType.updatedTime.integerTypeParam= -roleType.updatedTime.shortTypeParam= -roleType.updatedTime.byteTypeParam= -roleType.updatedTime.floatTypeParam= -roleType.updatedTime.doubleTypeParam= -roleType.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -roleType.updatedTime.defaultValue= -roleType.deletedBy.requiredParam= -roleType.deletedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -roleType.deletedBy.annotation= -roleType.deletedBy.enableJavaType=true -roleType.deletedBy.longTypeParam= -roleType.deletedBy.integerTypeParam= -roleType.deletedBy.shortTypeParam= -roleType.deletedBy.byteTypeParam= -roleType.deletedBy.floatTypeParam= -roleType.deletedBy.doubleTypeParam= -roleType.deletedBy.dateTypeParam= -roleType.deletedBy.defaultValue= -roleType.deletedTime.requiredParam= -roleType.deletedTime.additionalAnnotation= -roleType.deletedTime.annotation= -roleType.deletedTime.enableJavaType=true -roleType.deletedTime.longTypeParam= -roleType.deletedTime.integerTypeParam= -roleType.deletedTime.shortTypeParam= -roleType.deletedTime.byteTypeParam= -roleType.deletedTime.floatTypeParam= -roleType.deletedTime.doubleTypeParam= -roleType.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -roleType.deletedTime.defaultValue= -roleType.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -roleType.versionNo.additionalAnnotation= -roleType.versionNo.annotation= -roleType.versionNo.enableJavaType=true -roleType.versionNo.longTypeParam= -roleType.versionNo.integerTypeParam= -roleType.versionNo.shortTypeParam= -roleType.versionNo.byteTypeParam= -roleType.versionNo.floatTypeParam= -roleType.versionNo.doubleTypeParam= -roleType.versionNo.dateTypeParam= -roleType.versionNo.defaultValue= - -scheduledJob.ignored=false -scheduledJob.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.Mask;import org.seasar.struts.annotation.Msg;import org.codelibs.fess.annotation.CronExpression; -scheduledJob.converterToSearchParams= -scheduledJob.converterToPager= -scheduledJob.converterToActionForm= -scheduledJob.converterToEntity= -scheduledJob.id.requiredParam= -scheduledJob.id.additionalAnnotation= -scheduledJob.id.annotation= -scheduledJob.id.enableJavaType=true -scheduledJob.id.longTypeParam= -scheduledJob.id.integerTypeParam= -scheduledJob.id.shortTypeParam= -scheduledJob.id.byteTypeParam= -scheduledJob.id.floatTypeParam= -scheduledJob.id.doubleTypeParam= -scheduledJob.id.dateTypeParam= -scheduledJob.id.defaultValue= -scheduledJob.name.requiredParam= -scheduledJob.name.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -scheduledJob.name.annotation= -scheduledJob.name.enableJavaType=true -scheduledJob.name.longTypeParam= -scheduledJob.name.integerTypeParam= -scheduledJob.name.shortTypeParam= -scheduledJob.name.byteTypeParam= -scheduledJob.name.floatTypeParam= -scheduledJob.name.doubleTypeParam= -scheduledJob.name.dateTypeParam= -scheduledJob.name.defaultValue= -scheduledJob.target.requiredParam= -scheduledJob.target.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -scheduledJob.target.annotation= -scheduledJob.target.enableJavaType=true -scheduledJob.target.longTypeParam= -scheduledJob.target.integerTypeParam= -scheduledJob.target.shortTypeParam= -scheduledJob.target.byteTypeParam= -scheduledJob.target.floatTypeParam= -scheduledJob.target.doubleTypeParam= -scheduledJob.target.dateTypeParam= -scheduledJob.target.defaultValue= -scheduledJob.cronExpression.requiredParam= -scheduledJob.cronExpression.additionalAnnotation=@Maxbytelength(maxbytelength = 100)@CronExpression -scheduledJob.cronExpression.annotation= -scheduledJob.cronExpression.enableJavaType=true -scheduledJob.cronExpression.longTypeParam= -scheduledJob.cronExpression.integerTypeParam= -scheduledJob.cronExpression.shortTypeParam= -scheduledJob.cronExpression.byteTypeParam= -scheduledJob.cronExpression.floatTypeParam= -scheduledJob.cronExpression.doubleTypeParam= -scheduledJob.cronExpression.dateTypeParam= -scheduledJob.cronExpression.defaultValue= -scheduledJob.scriptType.requiredParam= -scheduledJob.scriptType.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -scheduledJob.scriptType.annotation= -scheduledJob.scriptType.enableJavaType=true -scheduledJob.scriptType.longTypeParam= -scheduledJob.scriptType.integerTypeParam= -scheduledJob.scriptType.shortTypeParam= -scheduledJob.scriptType.byteTypeParam= -scheduledJob.scriptType.floatTypeParam= -scheduledJob.scriptType.doubleTypeParam= -scheduledJob.scriptType.dateTypeParam= -scheduledJob.scriptType.defaultValue= -scheduledJob.scriptData.requiredParam= -scheduledJob.scriptData.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -scheduledJob.scriptData.annotation= -scheduledJob.scriptData.enableJavaType=true -scheduledJob.scriptData.longTypeParam= -scheduledJob.scriptData.integerTypeParam= -scheduledJob.scriptData.shortTypeParam= -scheduledJob.scriptData.byteTypeParam= -scheduledJob.scriptData.floatTypeParam= -scheduledJob.scriptData.doubleTypeParam= -scheduledJob.scriptData.dateTypeParam= -scheduledJob.scriptData.defaultValue= -scheduledJob.crawler.requiredParam= -scheduledJob.crawler.additionalAnnotation= -scheduledJob.crawler.annotation=// ignore -scheduledJob.crawler.enableJavaType=true -scheduledJob.crawler.longTypeParam= -scheduledJob.crawler.integerTypeParam= -scheduledJob.crawler.shortTypeParam= -scheduledJob.crawler.byteTypeParam= -scheduledJob.crawler.floatTypeParam= -scheduledJob.crawler.doubleTypeParam= -scheduledJob.crawler.dateTypeParam= -scheduledJob.crawler.defaultValue= -scheduledJob.jobLogging.requiredParam= -scheduledJob.jobLogging.additionalAnnotation= -scheduledJob.jobLogging.annotation=// ignore -scheduledJob.jobLogging.enableJavaType=true -scheduledJob.jobLogging.longTypeParam= -scheduledJob.jobLogging.integerTypeParam= -scheduledJob.jobLogging.shortTypeParam= -scheduledJob.jobLogging.byteTypeParam= -scheduledJob.jobLogging.floatTypeParam= -scheduledJob.jobLogging.doubleTypeParam= -scheduledJob.jobLogging.dateTypeParam= -scheduledJob.jobLogging.defaultValue= -scheduledJob.available.requiredParam= -scheduledJob.available.additionalAnnotation= -scheduledJob.available.annotation=// ignore -scheduledJob.available.enableJavaType=true -scheduledJob.available.longTypeParam= -scheduledJob.available.integerTypeParam= -scheduledJob.available.shortTypeParam= -scheduledJob.available.byteTypeParam= -scheduledJob.available.floatTypeParam= -scheduledJob.available.doubleTypeParam= -scheduledJob.available.dateTypeParam= -scheduledJob.available.defaultValue= -scheduledJob.sortOrder.requiredParam= -scheduledJob.sortOrder.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -scheduledJob.sortOrder.annotation= -scheduledJob.sortOrder.enableJavaType=true -scheduledJob.sortOrder.longTypeParam= -scheduledJob.sortOrder.integerTypeParam= -scheduledJob.sortOrder.shortTypeParam= -scheduledJob.sortOrder.byteTypeParam= -scheduledJob.sortOrder.floatTypeParam= -scheduledJob.sortOrder.doubleTypeParam= -scheduledJob.sortOrder.dateTypeParam= -scheduledJob.sortOrder.defaultValue= -scheduledJob.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -scheduledJob.createdBy.additionalAnnotation= -scheduledJob.createdBy.annotation= -scheduledJob.createdBy.enableJavaType=true -scheduledJob.createdBy.longTypeParam= -scheduledJob.createdBy.integerTypeParam= -scheduledJob.createdBy.shortTypeParam= -scheduledJob.createdBy.byteTypeParam= -scheduledJob.createdBy.floatTypeParam= -scheduledJob.createdBy.doubleTypeParam= -scheduledJob.createdBy.dateTypeParam= -scheduledJob.createdBy.defaultValue= -scheduledJob.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -scheduledJob.createdTime.additionalAnnotation= -scheduledJob.createdTime.annotation= -scheduledJob.createdTime.enableJavaType=true -scheduledJob.createdTime.longTypeParam= -scheduledJob.createdTime.integerTypeParam= -scheduledJob.createdTime.shortTypeParam= -scheduledJob.createdTime.byteTypeParam= -scheduledJob.createdTime.floatTypeParam= -scheduledJob.createdTime.doubleTypeParam= -scheduledJob.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -scheduledJob.createdTime.defaultValue= -scheduledJob.updatedBy.requiredParam=(target = "confirmfromupdate,update,delete") -scheduledJob.updatedBy.additionalAnnotation= -scheduledJob.updatedBy.annotation= -scheduledJob.updatedBy.enableJavaType=true -scheduledJob.updatedBy.longTypeParam= -scheduledJob.updatedBy.integerTypeParam= -scheduledJob.updatedBy.shortTypeParam= -scheduledJob.updatedBy.byteTypeParam= -scheduledJob.updatedBy.floatTypeParam= -scheduledJob.updatedBy.doubleTypeParam= -scheduledJob.updatedBy.dateTypeParam= -scheduledJob.updatedBy.defaultValue= -scheduledJob.updatedTime.requiredParam=(target = "confirmfromupdate,update,delete") -scheduledJob.updatedTime.additionalAnnotation= -scheduledJob.updatedTime.annotation= -scheduledJob.updatedTime.enableJavaType=true -scheduledJob.updatedTime.longTypeParam= -scheduledJob.updatedTime.integerTypeParam= -scheduledJob.updatedTime.shortTypeParam= -scheduledJob.updatedTime.byteTypeParam= -scheduledJob.updatedTime.floatTypeParam= -scheduledJob.updatedTime.doubleTypeParam= -scheduledJob.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -scheduledJob.updatedTime.defaultValue= -scheduledJob.deletedBy.requiredParam= -scheduledJob.deletedBy.additionalAnnotation= -scheduledJob.deletedBy.annotation= -scheduledJob.deletedBy.enableJavaType=true -scheduledJob.deletedBy.longTypeParam= -scheduledJob.deletedBy.integerTypeParam= -scheduledJob.deletedBy.shortTypeParam= -scheduledJob.deletedBy.byteTypeParam= -scheduledJob.deletedBy.floatTypeParam= -scheduledJob.deletedBy.doubleTypeParam= -scheduledJob.deletedBy.dateTypeParam= -scheduledJob.deletedBy.defaultValue= -scheduledJob.deletedTime.requiredParam= -scheduledJob.deletedTime.additionalAnnotation= -scheduledJob.deletedTime.annotation= -scheduledJob.deletedTime.enableJavaType=true -scheduledJob.deletedTime.longTypeParam= -scheduledJob.deletedTime.integerTypeParam= -scheduledJob.deletedTime.shortTypeParam= -scheduledJob.deletedTime.byteTypeParam= -scheduledJob.deletedTime.floatTypeParam= -scheduledJob.deletedTime.doubleTypeParam= -scheduledJob.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -scheduledJob.deletedTime.defaultValue= -scheduledJob.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -scheduledJob.versionNo.additionalAnnotation= -scheduledJob.versionNo.annotation= -scheduledJob.versionNo.enableJavaType=true -scheduledJob.versionNo.longTypeParam= -scheduledJob.versionNo.integerTypeParam= -scheduledJob.versionNo.shortTypeParam= -scheduledJob.versionNo.byteTypeParam= -scheduledJob.versionNo.floatTypeParam= -scheduledJob.versionNo.doubleTypeParam= -scheduledJob.versionNo.dateTypeParam= -scheduledJob.versionNo.defaultValue= - -searchFieldLog.ignored=true - -searchLog.ignored=false -searchLog.importPackages= -searchLog.converterToSearchParams= -searchLog.converterToPager= -searchLog.converterToActionForm= -searchLog.converterToEntity= -searchLog.id.requiredParam= -searchLog.id.additionalAnnotation= -searchLog.id.annotation= -searchLog.id.enableJavaType=true -searchLog.id.longTypeParam= -searchLog.id.integerTypeParam= -searchLog.id.shortTypeParam= -searchLog.id.byteTypeParam= -searchLog.id.floatTypeParam= -searchLog.id.doubleTypeParam= -searchLog.id.dateTypeParam= -searchLog.id.defaultValue= -searchLog.searchWord.requiredParam= -searchLog.searchWord.additionalAnnotation= -searchLog.searchWord.annotation= -searchLog.searchWord.enableJavaType=true -searchLog.searchWord.longTypeParam= -searchLog.searchWord.integerTypeParam= -searchLog.searchWord.shortTypeParam= -searchLog.searchWord.byteTypeParam= -searchLog.searchWord.floatTypeParam= -searchLog.searchWord.doubleTypeParam= -searchLog.searchWord.dateTypeParam= -searchLog.searchWord.defaultValue= -searchLog.requestedTime.requiredParam= -searchLog.requestedTime.additionalAnnotation= -searchLog.requestedTime.annotation= -searchLog.requestedTime.enableJavaType=true -searchLog.requestedTime.longTypeParam= -searchLog.requestedTime.integerTypeParam= -searchLog.requestedTime.shortTypeParam= -searchLog.requestedTime.byteTypeParam= -searchLog.requestedTime.floatTypeParam= -searchLog.requestedTime.doubleTypeParam= -searchLog.requestedTime.dateTypeParam= -searchLog.requestedTime.defaultValue= -searchLog.responseTime.requiredParam= -searchLog.responseTime.additionalAnnotation= -searchLog.responseTime.annotation= -searchLog.responseTime.enableJavaType=true -searchLog.responseTime.longTypeParam= -searchLog.responseTime.integerTypeParam= -searchLog.responseTime.shortTypeParam= -searchLog.responseTime.byteTypeParam= -searchLog.responseTime.floatTypeParam= -searchLog.responseTime.doubleTypeParam= -searchLog.responseTime.dateTypeParam= -searchLog.responseTime.defaultValue= -searchLog.hitCount.requiredParam= -searchLog.hitCount.additionalAnnotation= -searchLog.hitCount.annotation= -searchLog.hitCount.enableJavaType=true -searchLog.hitCount.longTypeParam= -searchLog.hitCount.integerTypeParam= -searchLog.hitCount.shortTypeParam= -searchLog.hitCount.byteTypeParam= -searchLog.hitCount.floatTypeParam= -searchLog.hitCount.doubleTypeParam= -searchLog.hitCount.dateTypeParam= -searchLog.hitCount.defaultValue= -searchLog.queryOffset.requiredParam= -searchLog.queryOffset.additionalAnnotation= -searchLog.queryOffset.annotation= -searchLog.queryOffset.enableJavaType=true -searchLog.queryOffset.longTypeParam= -searchLog.queryOffset.integerTypeParam= -searchLog.queryOffset.shortTypeParam= -searchLog.queryOffset.byteTypeParam= -searchLog.queryOffset.floatTypeParam= -searchLog.queryOffset.doubleTypeParam= -searchLog.queryOffset.dateTypeParam= -searchLog.queryOffset.defaultValue= -searchLog.queryPageSize.requiredParam= -searchLog.queryPageSize.additionalAnnotation= -searchLog.queryPageSize.annotation= -searchLog.queryPageSize.enableJavaType=true -searchLog.queryPageSize.longTypeParam= -searchLog.queryPageSize.integerTypeParam= -searchLog.queryPageSize.shortTypeParam= -searchLog.queryPageSize.byteTypeParam= -searchLog.queryPageSize.floatTypeParam= -searchLog.queryPageSize.doubleTypeParam= -searchLog.queryPageSize.dateTypeParam= -searchLog.queryPageSize.defaultValue= -searchLog.userAgent.requiredParam= -searchLog.userAgent.additionalAnnotation= -searchLog.userAgent.annotation= -searchLog.userAgent.enableJavaType=true -searchLog.userAgent.longTypeParam= -searchLog.userAgent.integerTypeParam= -searchLog.userAgent.shortTypeParam= -searchLog.userAgent.byteTypeParam= -searchLog.userAgent.floatTypeParam= -searchLog.userAgent.doubleTypeParam= -searchLog.userAgent.dateTypeParam= -searchLog.userAgent.defaultValue= -searchLog.referer.requiredParam= -searchLog.referer.additionalAnnotation= -searchLog.referer.annotation= -searchLog.referer.enableJavaType=true -searchLog.referer.longTypeParam= -searchLog.referer.integerTypeParam= -searchLog.referer.shortTypeParam= -searchLog.referer.byteTypeParam= -searchLog.referer.floatTypeParam= -searchLog.referer.doubleTypeParam= -searchLog.referer.dateTypeParam= -searchLog.referer.defaultValue= -searchLog.clientIp.requiredParam= -searchLog.clientIp.additionalAnnotation= -searchLog.clientIp.annotation= -searchLog.clientIp.enableJavaType=true -searchLog.clientIp.longTypeParam= -searchLog.clientIp.integerTypeParam= -searchLog.clientIp.shortTypeParam= -searchLog.clientIp.byteTypeParam= -searchLog.clientIp.floatTypeParam= -searchLog.clientIp.doubleTypeParam= -searchLog.clientIp.dateTypeParam= -searchLog.clientIp.defaultValue= -searchLog.userSessionId.requiredParam= -searchLog.userSessionId.additionalAnnotation= -searchLog.userSessionId.annotation= -searchLog.userSessionId.enableJavaType=true -searchLog.userSessionId.longTypeParam= -searchLog.userSessionId.integerTypeParam= -searchLog.userSessionId.shortTypeParam= -searchLog.userSessionId.byteTypeParam= -searchLog.userSessionId.floatTypeParam= -searchLog.userSessionId.doubleTypeParam= -searchLog.userSessionId.dateTypeParam= -searchLog.userSessionId.defaultValue= -searchLog.accessType.requiredParam= -searchLog.accessType.additionalAnnotation= -searchLog.accessType.annotation= -searchLog.accessType.enableJavaType=true -searchLog.accessType.longTypeParam= -searchLog.accessType.integerTypeParam= -searchLog.accessType.shortTypeParam= -searchLog.accessType.byteTypeParam= -searchLog.accessType.floatTypeParam= -searchLog.accessType.doubleTypeParam= -searchLog.accessType.dateTypeParam= -searchLog.accessType.defaultValue= -searchLog.userId.requiredParam= -searchLog.userId.additionalAnnotation= -searchLog.userId.annotation= -searchLog.userId.enableJavaType=true -searchLog.userId.longTypeParam= -searchLog.userId.integerTypeParam= -searchLog.userId.shortTypeParam= -searchLog.userId.byteTypeParam= -searchLog.userId.floatTypeParam= -searchLog.userId.doubleTypeParam= -searchLog.userId.dateTypeParam= -searchLog.userId.defaultValue= - -suggestBadWord.ignored=false -suggestBadWord.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.FloatRange; -suggestBadWord.converterToSearchParams= -suggestBadWord.converterToPager= -suggestBadWord.converterToActionForm= -suggestBadWord.converterToEntity= -suggestBadWord.id.requiredParam= -suggestBadWord.id.additionalAnnotation= -suggestBadWord.id.annotation= -suggestBadWord.id.enableJavaType=true -suggestBadWord.id.longTypeParam= -suggestBadWord.id.integerTypeParam= -suggestBadWord.id.shortTypeParam= -suggestBadWord.id.byteTypeParam= -suggestBadWord.id.floatTypeParam= -suggestBadWord.id.doubleTypeParam= -suggestBadWord.id.dateTypeParam= -suggestBadWord.id.defaultValue= -suggestBadWord.suggestWord.requiredParam= -suggestBadWord.suggestWord.additionalAnnotation= -suggestBadWord.suggestWord.annotation= -suggestBadWord.suggestWord.enableJavaType=true -suggestBadWord.suggestWord.longTypeParam= -suggestBadWord.suggestWord.integerTypeParam= -suggestBadWord.suggestWord.shortTypeParam= -suggestBadWord.suggestWord.byteTypeParam= -suggestBadWord.suggestWord.floatTypeParam= -suggestBadWord.suggestWord.doubleTypeParam= -suggestBadWord.suggestWord.dateTypeParam= -suggestBadWord.suggestWord.defaultValue= -suggestBadWord.targetRole.requiredParam= -suggestBadWord.targetRole.additionalAnnotation= -suggestBadWord.targetRole.annotation= -suggestBadWord.targetRole.enableJavaType=true -suggestBadWord.targetRole.longTypeParam= -suggestBadWord.targetRole.integerTypeParam= -suggestBadWord.targetRole.shortTypeParam= -suggestBadWord.targetRole.byteTypeParam= -suggestBadWord.targetRole.floatTypeParam= -suggestBadWord.targetRole.doubleTypeParam= -suggestBadWord.targetRole.dateTypeParam= -suggestBadWord.targetRole.defaultValue= -suggestBadWord.targetLabel.requiredParam= -suggestBadWord.targetLabel.additionalAnnotation= -suggestBadWord.targetLabel.annotation= -suggestBadWord.targetLabel.enableJavaType=true -suggestBadWord.targetLabel.longTypeParam= -suggestBadWord.targetLabel.integerTypeParam= -suggestBadWord.targetLabel.shortTypeParam= -suggestBadWord.targetLabel.byteTypeParam= -suggestBadWord.targetLabel.floatTypeParam= -suggestBadWord.targetLabel.doubleTypeParam= -suggestBadWord.targetLabel.dateTypeParam= -suggestBadWord.targetLabel.defaultValue= -suggestBadWord.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -suggestBadWord.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -suggestBadWord.createdBy.annotation= -suggestBadWord.createdBy.enableJavaType=true -suggestBadWord.createdBy.longTypeParam= -suggestBadWord.createdBy.integerTypeParam= -suggestBadWord.createdBy.shortTypeParam= -suggestBadWord.createdBy.byteTypeParam= -suggestBadWord.createdBy.floatTypeParam= -suggestBadWord.createdBy.doubleTypeParam= -suggestBadWord.createdBy.dateTypeParam= -suggestBadWord.createdBy.defaultValue= -suggestBadWord.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -suggestBadWord.createdTime.additionalAnnotation= -suggestBadWord.createdTime.annotation= -suggestBadWord.createdTime.enableJavaType=true -suggestBadWord.createdTime.longTypeParam= -suggestBadWord.createdTime.integerTypeParam= -suggestBadWord.createdTime.shortTypeParam= -suggestBadWord.createdTime.byteTypeParam= -suggestBadWord.createdTime.floatTypeParam= -suggestBadWord.createdTime.doubleTypeParam= -suggestBadWord.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -suggestBadWord.createdTime.defaultValue= -suggestBadWord.updatedBy.requiredParam= -suggestBadWord.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -suggestBadWord.updatedBy.annotation= -suggestBadWord.updatedBy.enableJavaType=true -suggestBadWord.updatedBy.longTypeParam= -suggestBadWord.updatedBy.integerTypeParam= -suggestBadWord.updatedBy.shortTypeParam= -suggestBadWord.updatedBy.byteTypeParam= -suggestBadWord.updatedBy.floatTypeParam= -suggestBadWord.updatedBy.doubleTypeParam= -suggestBadWord.updatedBy.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -suggestBadWord.updatedBy.defaultValue= -suggestBadWord.updatedTime.requiredParam= -suggestBadWord.updatedTime.additionalAnnotation= -suggestBadWord.updatedTime.annotation= -suggestBadWord.updatedTime.enableJavaType=true -suggestBadWord.updatedTime.longTypeParam= -suggestBadWord.updatedTime.integerTypeParam= -suggestBadWord.updatedTime.shortTypeParam= -suggestBadWord.updatedTime.byteTypeParam= -suggestBadWord.updatedTime.floatTypeParam= -suggestBadWord.updatedTime.doubleTypeParam= -suggestBadWord.updatedTime.dateTypeParam= -suggestBadWord.updatedTime.defaultValue= -suggestBadWord.deletedBy.requiredParam= -suggestBadWord.deletedBy.additionalAnnotation= -suggestBadWord.deletedBy.annotation= -suggestBadWord.deletedBy.enableJavaType=true -suggestBadWord.deletedBy.longTypeParam= -suggestBadWord.deletedBy.integerTypeParam= -suggestBadWord.deletedBy.shortTypeParam= -suggestBadWord.deletedBy.byteTypeParam= -suggestBadWord.deletedBy.floatTypeParam= -suggestBadWord.deletedBy.doubleTypeParam= -suggestBadWord.deletedBy.dateTypeParam= -suggestBadWord.deletedBy.defaultValue= -suggestBadWord.deletedTime.requiredParam= -suggestBadWord.deletedTime.additionalAnnotation= -suggestBadWord.deletedTime.annotation= -suggestBadWord.deletedTime.enableJavaType=true -suggestBadWord.deletedTime.longTypeParam= -suggestBadWord.deletedTime.integerTypeParam= -suggestBadWord.deletedTime.shortTypeParam= -suggestBadWord.deletedTime.byteTypeParam= -suggestBadWord.deletedTime.floatTypeParam= -suggestBadWord.deletedTime.doubleTypeParam= -suggestBadWord.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -suggestBadWord.deletedTime.defaultValue= -suggestBadWord.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -suggestBadWord.versionNo.additionalAnnotation= -suggestBadWord.versionNo.annotation= -suggestBadWord.versionNo.enableJavaType=true -suggestBadWord.versionNo.longTypeParam= -suggestBadWord.versionNo.integerTypeParam= -suggestBadWord.versionNo.shortTypeParam= -suggestBadWord.versionNo.byteTypeParam= -suggestBadWord.versionNo.floatTypeParam= -suggestBadWord.versionNo.doubleTypeParam= -suggestBadWord.versionNo.dateTypeParam= -suggestBadWord.versionNo.defaultValue= - -suggestElevateWord.ignored=false -suggestElevateWord.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.FloatRange; -suggestElevateWord.converterToSearchParams= -suggestElevateWord.converterToPager= -suggestElevateWord.converterToActionForm= -suggestElevateWord.converterToEntity= -suggestElevateWord.id.requiredParam= -suggestElevateWord.id.additionalAnnotation= -suggestElevateWord.id.annotation= -suggestElevateWord.id.enableJavaType=true -suggestElevateWord.id.longTypeParam= -suggestElevateWord.id.integerTypeParam= -suggestElevateWord.id.shortTypeParam= -suggestElevateWord.id.byteTypeParam= -suggestElevateWord.id.floatTypeParam= -suggestElevateWord.id.doubleTypeParam= -suggestElevateWord.id.dateTypeParam= -suggestElevateWord.id.defaultValue= -suggestElevateWord.suggestWord.requiredParam= -suggestElevateWord.suggestWord.additionalAnnotation= -suggestElevateWord.suggestWord.annotation= -suggestElevateWord.suggestWord.enableJavaType=true -suggestElevateWord.suggestWord.longTypeParam= -suggestElevateWord.suggestWord.integerTypeParam= -suggestElevateWord.suggestWord.shortTypeParam= -suggestElevateWord.suggestWord.byteTypeParam= -suggestElevateWord.suggestWord.floatTypeParam= -suggestElevateWord.suggestWord.doubleTypeParam= -suggestElevateWord.suggestWord.dateTypeParam= -suggestElevateWord.suggestWord.defaultValue= -suggestElevateWord.reading.requiredParam= -suggestElevateWord.reading.additionalAnnotation= -suggestElevateWord.reading.annotation= -suggestElevateWord.reading.enableJavaType=true -suggestElevateWord.reading.longTypeParam= -suggestElevateWord.reading.integerTypeParam= -suggestElevateWord.reading.shortTypeParam= -suggestElevateWord.reading.byteTypeParam= -suggestElevateWord.reading.floatTypeParam= -suggestElevateWord.reading.doubleTypeParam= -suggestElevateWord.reading.dateTypeParam= -suggestElevateWord.reading.defaultValue= -suggestElevateWord.targetRole.requiredParam= -suggestElevateWord.targetRole.additionalAnnotation= -suggestElevateWord.targetRole.annotation= -suggestElevateWord.targetRole.enableJavaType=true -suggestElevateWord.targetRole.longTypeParam= -suggestElevateWord.targetRole.integerTypeParam= -suggestElevateWord.targetRole.shortTypeParam= -suggestElevateWord.targetRole.byteTypeParam= -suggestElevateWord.targetRole.floatTypeParam= -suggestElevateWord.targetRole.doubleTypeParam= -suggestElevateWord.targetRole.dateTypeParam= -suggestElevateWord.targetRole.defaultValue= -suggestElevateWord.targetLabel.requiredParam= -suggestElevateWord.targetLabel.additionalAnnotation= -suggestElevateWord.targetLabel.annotation= -suggestElevateWord.targetLabel.enableJavaType=true -suggestElevateWord.targetLabel.longTypeParam= -suggestElevateWord.targetLabel.integerTypeParam= -suggestElevateWord.targetLabel.shortTypeParam= -suggestElevateWord.targetLabel.byteTypeParam= -suggestElevateWord.targetLabel.floatTypeParam= -suggestElevateWord.targetLabel.doubleTypeParam= -suggestElevateWord.targetLabel.dateTypeParam= -suggestElevateWord.targetLabel.defaultValue= -suggestElevateWord.boost.requiredParam= -suggestElevateWord.boost.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -suggestElevateWord.boost.annotation= -suggestElevateWord.boost.enableJavaType=true -suggestElevateWord.boost.longTypeParam= -suggestElevateWord.boost.integerTypeParam= -suggestElevateWord.boost.shortTypeParam= -suggestElevateWord.boost.byteTypeParam= -suggestElevateWord.boost.floatTypeParam= -suggestElevateWord.boost.doubleTypeParam= -suggestElevateWord.boost.dateTypeParam= -suggestElevateWord.boost.defaultValue= -suggestElevateWord.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -suggestElevateWord.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -suggestElevateWord.createdBy.annotation= -suggestElevateWord.createdBy.enableJavaType=true -suggestElevateWord.createdBy.longTypeParam= -suggestElevateWord.createdBy.integerTypeParam= -suggestElevateWord.createdBy.shortTypeParam= -suggestElevateWord.createdBy.byteTypeParam= -suggestElevateWord.createdBy.floatTypeParam= -suggestElevateWord.createdBy.doubleTypeParam= -suggestElevateWord.createdBy.dateTypeParam= -suggestElevateWord.createdBy.defaultValue= -suggestElevateWord.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -suggestElevateWord.createdTime.additionalAnnotation= -suggestElevateWord.createdTime.annotation= -suggestElevateWord.createdTime.enableJavaType=true -suggestElevateWord.createdTime.longTypeParam= -suggestElevateWord.createdTime.integerTypeParam= -suggestElevateWord.createdTime.shortTypeParam= -suggestElevateWord.createdTime.byteTypeParam= -suggestElevateWord.createdTime.floatTypeParam= -suggestElevateWord.createdTime.doubleTypeParam= -suggestElevateWord.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -suggestElevateWord.createdTime.defaultValue= -suggestElevateWord.updatedBy.requiredParam= -suggestElevateWord.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -suggestElevateWord.updatedBy.annotation= -suggestElevateWord.updatedBy.enableJavaType=true -suggestElevateWord.updatedBy.longTypeParam= -suggestElevateWord.updatedBy.integerTypeParam= -suggestElevateWord.updatedBy.shortTypeParam= -suggestElevateWord.updatedBy.byteTypeParam= -suggestElevateWord.updatedBy.floatTypeParam= -suggestElevateWord.updatedBy.doubleTypeParam= -suggestElevateWord.updatedBy.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -suggestElevateWord.updatedBy.defaultValue= -suggestElevateWord.updatedTime.requiredParam= -suggestElevateWord.updatedTime.additionalAnnotation= -suggestElevateWord.updatedTime.annotation= -suggestElevateWord.updatedTime.enableJavaType=true -suggestElevateWord.updatedTime.longTypeParam= -suggestElevateWord.updatedTime.integerTypeParam= -suggestElevateWord.updatedTime.shortTypeParam= -suggestElevateWord.updatedTime.byteTypeParam= -suggestElevateWord.updatedTime.floatTypeParam= -suggestElevateWord.updatedTime.doubleTypeParam= -suggestElevateWord.updatedTime.dateTypeParam= -suggestElevateWord.updatedTime.defaultValue= -suggestElevateWord.deletedBy.requiredParam= -suggestElevateWord.deletedBy.additionalAnnotation= -suggestElevateWord.deletedBy.annotation= -suggestElevateWord.deletedBy.enableJavaType=true -suggestElevateWord.deletedBy.longTypeParam= -suggestElevateWord.deletedBy.integerTypeParam= -suggestElevateWord.deletedBy.shortTypeParam= -suggestElevateWord.deletedBy.byteTypeParam= -suggestElevateWord.deletedBy.floatTypeParam= -suggestElevateWord.deletedBy.doubleTypeParam= -suggestElevateWord.deletedBy.dateTypeParam= -suggestElevateWord.deletedBy.defaultValue= -suggestElevateWord.deletedTime.requiredParam= -suggestElevateWord.deletedTime.additionalAnnotation= -suggestElevateWord.deletedTime.annotation= -suggestElevateWord.deletedTime.enableJavaType=true -suggestElevateWord.deletedTime.longTypeParam= -suggestElevateWord.deletedTime.integerTypeParam= -suggestElevateWord.deletedTime.shortTypeParam= -suggestElevateWord.deletedTime.byteTypeParam= -suggestElevateWord.deletedTime.floatTypeParam= -suggestElevateWord.deletedTime.doubleTypeParam= -suggestElevateWord.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -suggestElevateWord.deletedTime.defaultValue= -suggestElevateWord.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -suggestElevateWord.versionNo.additionalAnnotation= -suggestElevateWord.versionNo.annotation= -suggestElevateWord.versionNo.enableJavaType=true -suggestElevateWord.versionNo.longTypeParam= -suggestElevateWord.versionNo.integerTypeParam= -suggestElevateWord.versionNo.shortTypeParam= -suggestElevateWord.versionNo.byteTypeParam= -suggestElevateWord.versionNo.floatTypeParam= -suggestElevateWord.versionNo.doubleTypeParam= -suggestElevateWord.versionNo.dateTypeParam= -suggestElevateWord.versionNo.defaultValue= - -userInfo.ignored=false -userInfo.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.FloatRange; -userInfo.converterToSearchParams= -userInfo.converterToPager= -userInfo.converterToActionForm=.timestampConverter(Constants.DEFAULT_DATETIME_FORMAT, "createdTime", "updatedTime") -userInfo.converterToEntity=.timestampConverter(Constants.DEFAULT_DATETIME_FORMAT, "createdTime", "updatedTime") -userInfo.id.requiredParam= -userInfo.id.additionalAnnotation= -userInfo.id.annotation= -userInfo.id.enableJavaType=true -userInfo.id.longTypeParam= -userInfo.id.integerTypeParam= -userInfo.id.shortTypeParam= -userInfo.id.byteTypeParam= -userInfo.id.floatTypeParam= -userInfo.id.doubleTypeParam= -userInfo.id.dateTypeParam= -userInfo.id.defaultValue= -userInfo.code.requiredParam= -userInfo.code.additionalAnnotation= -userInfo.code.annotation= -userInfo.code.enableJavaType=true -userInfo.code.longTypeParam= -userInfo.code.integerTypeParam= -userInfo.code.shortTypeParam= -userInfo.code.byteTypeParam= -userInfo.code.floatTypeParam= -userInfo.code.doubleTypeParam= -userInfo.code.dateTypeParam= -userInfo.code.defaultValue= -userInfo.createdTime.requiredParam= -userInfo.createdTime.additionalAnnotation= -userInfo.createdTime.annotation= -userInfo.createdTime.enableJavaType=true -userInfo.createdTime.longTypeParam= -userInfo.createdTime.integerTypeParam= -userInfo.createdTime.shortTypeParam= -userInfo.createdTime.byteTypeParam= -userInfo.createdTime.floatTypeParam= -userInfo.createdTime.doubleTypeParam= -userInfo.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -userInfo.createdTime.defaultValue= -userInfo.updatedTime.requiredParam= -userInfo.updatedTime.additionalAnnotation= -userInfo.updatedTime.annotation= -userInfo.updatedTime.enableJavaType=true -userInfo.updatedTime.longTypeParam= -userInfo.updatedTime.integerTypeParam= -userInfo.updatedTime.shortTypeParam= -userInfo.updatedTime.byteTypeParam= -userInfo.updatedTime.floatTypeParam= -userInfo.updatedTime.doubleTypeParam= -userInfo.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -userInfo.updatedTime.defaultValue= - -webAuthentication.ignored=false -webAuthentication.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange; -webAuthentication.converterToSearchParams= -webAuthentication.converterToPager= -webAuthentication.converterToActionForm= -webAuthentication.converterToEntity= -webAuthentication.id.requiredParam= -webAuthentication.id.additionalAnnotation= -webAuthentication.id.annotation= -webAuthentication.id.enableJavaType=true -webAuthentication.id.longTypeParam= -webAuthentication.id.integerTypeParam= -webAuthentication.id.shortTypeParam= -webAuthentication.id.byteTypeParam= -webAuthentication.id.floatTypeParam= -webAuthentication.id.doubleTypeParam= -webAuthentication.id.dateTypeParam= -webAuthentication.id.defaultValue= -webAuthentication.hostname.requiredParam= -webAuthentication.hostname.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -webAuthentication.hostname.annotation= -webAuthentication.hostname.enableJavaType=true -webAuthentication.hostname.longTypeParam= -webAuthentication.hostname.integerTypeParam= -webAuthentication.hostname.shortTypeParam= -webAuthentication.hostname.byteTypeParam= -webAuthentication.hostname.floatTypeParam= -webAuthentication.hostname.doubleTypeParam= -webAuthentication.hostname.dateTypeParam= -webAuthentication.hostname.defaultValue= -webAuthentication.port.requiredParam= -webAuthentication.port.additionalAnnotation= -webAuthentication.port.annotation=@IntRange(min = -1, max = 2147483647) -webAuthentication.port.enableJavaType=false -webAuthentication.port.longTypeParam= -webAuthentication.port.integerTypeParam= -webAuthentication.port.shortTypeParam= -webAuthentication.port.byteTypeParam= -webAuthentication.port.floatTypeParam= -webAuthentication.port.doubleTypeParam= -webAuthentication.port.dateTypeParam= -webAuthentication.port.defaultValue= -webAuthentication.authRealm.requiredParam= -webAuthentication.authRealm.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -webAuthentication.authRealm.annotation= -webAuthentication.authRealm.enableJavaType=true -webAuthentication.authRealm.longTypeParam= -webAuthentication.authRealm.integerTypeParam= -webAuthentication.authRealm.shortTypeParam= -webAuthentication.authRealm.byteTypeParam= -webAuthentication.authRealm.floatTypeParam= -webAuthentication.authRealm.doubleTypeParam= -webAuthentication.authRealm.dateTypeParam= -webAuthentication.authRealm.defaultValue= -webAuthentication.protocolScheme.requiredParam= -webAuthentication.protocolScheme.additionalAnnotation=@Maxbytelength(maxbytelength = 10) -webAuthentication.protocolScheme.annotation= -webAuthentication.protocolScheme.enableJavaType=true -webAuthentication.protocolScheme.longTypeParam= -webAuthentication.protocolScheme.integerTypeParam= -webAuthentication.protocolScheme.shortTypeParam= -webAuthentication.protocolScheme.byteTypeParam= -webAuthentication.protocolScheme.floatTypeParam= -webAuthentication.protocolScheme.doubleTypeParam= -webAuthentication.protocolScheme.dateTypeParam= -webAuthentication.protocolScheme.defaultValue= -webAuthentication.username.requiredParam= -webAuthentication.username.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -webAuthentication.username.annotation= -webAuthentication.username.enableJavaType=true -webAuthentication.username.longTypeParam= -webAuthentication.username.integerTypeParam= -webAuthentication.username.shortTypeParam= -webAuthentication.username.byteTypeParam= -webAuthentication.username.floatTypeParam= -webAuthentication.username.doubleTypeParam= -webAuthentication.username.dateTypeParam= -webAuthentication.username.defaultValue= -webAuthentication.password.requiredParam= -webAuthentication.password.additionalAnnotation=@Maxbytelength(maxbytelength = 100) -webAuthentication.password.annotation= -webAuthentication.password.enableJavaType=true -webAuthentication.password.longTypeParam= -webAuthentication.password.integerTypeParam= -webAuthentication.password.shortTypeParam= -webAuthentication.password.byteTypeParam= -webAuthentication.password.floatTypeParam= -webAuthentication.password.doubleTypeParam= -webAuthentication.password.dateTypeParam= -webAuthentication.password.defaultValue= -webAuthentication.parameters.requiredParam= -webAuthentication.parameters.additionalAnnotation=@Maxbytelength(maxbytelength = 1000) -webAuthentication.parameters.annotation= -webAuthentication.parameters.enableJavaType=true -webAuthentication.parameters.longTypeParam= -webAuthentication.parameters.integerTypeParam= -webAuthentication.parameters.shortTypeParam= -webAuthentication.parameters.byteTypeParam= -webAuthentication.parameters.floatTypeParam= -webAuthentication.parameters.doubleTypeParam= -webAuthentication.parameters.dateTypeParam= -webAuthentication.parameters.defaultValue= -webAuthentication.webCrawlingConfigId.requiredParam= -webAuthentication.webCrawlingConfigId.additionalAnnotation= -webAuthentication.webCrawlingConfigId.annotation= -webAuthentication.webCrawlingConfigId.enableJavaType=true -webAuthentication.webCrawlingConfigId.longTypeParam= -webAuthentication.webCrawlingConfigId.integerTypeParam= -webAuthentication.webCrawlingConfigId.shortTypeParam= -webAuthentication.webCrawlingConfigId.byteTypeParam= -webAuthentication.webCrawlingConfigId.floatTypeParam= -webAuthentication.webCrawlingConfigId.doubleTypeParam= -webAuthentication.webCrawlingConfigId.dateTypeParam= -webAuthentication.webCrawlingConfigId.defaultValue= -webAuthentication.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -webAuthentication.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -webAuthentication.createdBy.annotation= -webAuthentication.createdBy.enableJavaType=true -webAuthentication.createdBy.longTypeParam= -webAuthentication.createdBy.integerTypeParam= -webAuthentication.createdBy.shortTypeParam= -webAuthentication.createdBy.byteTypeParam= -webAuthentication.createdBy.floatTypeParam= -webAuthentication.createdBy.doubleTypeParam= -webAuthentication.createdBy.dateTypeParam= -webAuthentication.createdBy.defaultValue= -webAuthentication.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -webAuthentication.createdTime.additionalAnnotation= -webAuthentication.createdTime.annotation= -webAuthentication.createdTime.enableJavaType=true -webAuthentication.createdTime.longTypeParam= -webAuthentication.createdTime.integerTypeParam= -webAuthentication.createdTime.shortTypeParam= -webAuthentication.createdTime.byteTypeParam= -webAuthentication.createdTime.floatTypeParam= -webAuthentication.createdTime.doubleTypeParam= -webAuthentication.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -webAuthentication.createdTime.defaultValue= -webAuthentication.updatedBy.requiredParam= -webAuthentication.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -webAuthentication.updatedBy.annotation= -webAuthentication.updatedBy.enableJavaType=true -webAuthentication.updatedBy.longTypeParam= -webAuthentication.updatedBy.integerTypeParam= -webAuthentication.updatedBy.shortTypeParam= -webAuthentication.updatedBy.byteTypeParam= -webAuthentication.updatedBy.floatTypeParam= -webAuthentication.updatedBy.doubleTypeParam= -webAuthentication.updatedBy.dateTypeParam= -webAuthentication.updatedBy.defaultValue= -webAuthentication.updatedTime.requiredParam= -webAuthentication.updatedTime.additionalAnnotation= -webAuthentication.updatedTime.annotation= -webAuthentication.updatedTime.enableJavaType=true -webAuthentication.updatedTime.longTypeParam= -webAuthentication.updatedTime.integerTypeParam= -webAuthentication.updatedTime.shortTypeParam= -webAuthentication.updatedTime.byteTypeParam= -webAuthentication.updatedTime.floatTypeParam= -webAuthentication.updatedTime.doubleTypeParam= -webAuthentication.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -webAuthentication.updatedTime.defaultValue= -webAuthentication.deletedBy.requiredParam= -webAuthentication.deletedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -webAuthentication.deletedBy.annotation= -webAuthentication.deletedBy.enableJavaType=true -webAuthentication.deletedBy.longTypeParam= -webAuthentication.deletedBy.integerTypeParam= -webAuthentication.deletedBy.shortTypeParam= -webAuthentication.deletedBy.byteTypeParam= -webAuthentication.deletedBy.floatTypeParam= -webAuthentication.deletedBy.doubleTypeParam= -webAuthentication.deletedBy.dateTypeParam= -webAuthentication.deletedBy.defaultValue= -webAuthentication.deletedTime.requiredParam= -webAuthentication.deletedTime.additionalAnnotation= -webAuthentication.deletedTime.annotation= -webAuthentication.deletedTime.enableJavaType=true -webAuthentication.deletedTime.longTypeParam= -webAuthentication.deletedTime.integerTypeParam= -webAuthentication.deletedTime.shortTypeParam= -webAuthentication.deletedTime.byteTypeParam= -webAuthentication.deletedTime.floatTypeParam= -webAuthentication.deletedTime.doubleTypeParam= -webAuthentication.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -webAuthentication.deletedTime.defaultValue= -webAuthentication.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -webAuthentication.versionNo.additionalAnnotation= -webAuthentication.versionNo.annotation= -webAuthentication.versionNo.enableJavaType=true -webAuthentication.versionNo.longTypeParam= -webAuthentication.versionNo.integerTypeParam= -webAuthentication.versionNo.shortTypeParam= -webAuthentication.versionNo.byteTypeParam= -webAuthentication.versionNo.floatTypeParam= -webAuthentication.versionNo.doubleTypeParam= -webAuthentication.versionNo.dateTypeParam= -webAuthentication.versionNo.defaultValue= - -webConfigToLabelTypeMapping.ignored=true - -webConfigToRoleTypeMapping.ignored=true - -webCrawlingConfig.ignored=false -webCrawlingConfig.importPackages=import org.codelibs.fess.Constants;import org.codelibs.fess.annotation.UriType;import org.seasar.struts.annotation.Maxbytelength;import org.seasar.struts.annotation.IntRange;import org.seasar.struts.annotation.LongRange;import org.seasar.struts.annotation.FloatRange; -webCrawlingConfig.converterToSearchParams= -webCrawlingConfig.converterToPager= -webCrawlingConfig.converterToActionForm= -webCrawlingConfig.converterToEntity= -webCrawlingConfig.id.requiredParam= -webCrawlingConfig.id.additionalAnnotation= -webCrawlingConfig.id.annotation= -webCrawlingConfig.id.enableJavaType=true -webCrawlingConfig.id.longTypeParam= -webCrawlingConfig.id.integerTypeParam= -webCrawlingConfig.id.shortTypeParam= -webCrawlingConfig.id.byteTypeParam= -webCrawlingConfig.id.floatTypeParam= -webCrawlingConfig.id.doubleTypeParam= -webCrawlingConfig.id.dateTypeParam= -webCrawlingConfig.id.defaultValue= -webCrawlingConfig.name.requiredParam= -webCrawlingConfig.name.additionalAnnotation=@Maxbytelength(maxbytelength = 200) -webCrawlingConfig.name.annotation= -webCrawlingConfig.name.enableJavaType=true -webCrawlingConfig.name.longTypeParam= -webCrawlingConfig.name.integerTypeParam= -webCrawlingConfig.name.shortTypeParam= -webCrawlingConfig.name.byteTypeParam= -webCrawlingConfig.name.floatTypeParam= -webCrawlingConfig.name.doubleTypeParam= -webCrawlingConfig.name.dateTypeParam= -webCrawlingConfig.name.defaultValue= -webCrawlingConfig.urls.requiredParam= -webCrawlingConfig.urls.additionalAnnotation= -webCrawlingConfig.urls.annotation=@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete")@UriType(protocols = "http:,https:")@Maxbytelength(maxbytelength = 4000) -webCrawlingConfig.urls.enableJavaType=true -webCrawlingConfig.urls.longTypeParam= -webCrawlingConfig.urls.integerTypeParam= -webCrawlingConfig.urls.shortTypeParam= -webCrawlingConfig.urls.byteTypeParam= -webCrawlingConfig.urls.floatTypeParam= -webCrawlingConfig.urls.doubleTypeParam= -webCrawlingConfig.urls.dateTypeParam= -webCrawlingConfig.urls.defaultValue= -webCrawlingConfig.includedUrls.requiredParam= -webCrawlingConfig.includedUrls.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -webCrawlingConfig.includedUrls.annotation= -webCrawlingConfig.includedUrls.enableJavaType=true -webCrawlingConfig.includedUrls.longTypeParam= -webCrawlingConfig.includedUrls.integerTypeParam= -webCrawlingConfig.includedUrls.shortTypeParam= -webCrawlingConfig.includedUrls.byteTypeParam= -webCrawlingConfig.includedUrls.floatTypeParam= -webCrawlingConfig.includedUrls.doubleTypeParam= -webCrawlingConfig.includedUrls.dateTypeParam= -webCrawlingConfig.includedUrls.defaultValue= -webCrawlingConfig.excludedUrls.requiredParam= -webCrawlingConfig.excludedUrls.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -webCrawlingConfig.excludedUrls.annotation= -webCrawlingConfig.excludedUrls.enableJavaType=true -webCrawlingConfig.excludedUrls.longTypeParam= -webCrawlingConfig.excludedUrls.integerTypeParam= -webCrawlingConfig.excludedUrls.shortTypeParam= -webCrawlingConfig.excludedUrls.byteTypeParam= -webCrawlingConfig.excludedUrls.floatTypeParam= -webCrawlingConfig.excludedUrls.doubleTypeParam= -webCrawlingConfig.excludedUrls.dateTypeParam= -webCrawlingConfig.excludedUrls.defaultValue= -webCrawlingConfig.includedDocUrls.requiredParam= -webCrawlingConfig.includedDocUrls.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -webCrawlingConfig.includedDocUrls.annotation= -webCrawlingConfig.includedDocUrls.enableJavaType=true -webCrawlingConfig.includedDocUrls.longTypeParam= -webCrawlingConfig.includedDocUrls.integerTypeParam= -webCrawlingConfig.includedDocUrls.shortTypeParam= -webCrawlingConfig.includedDocUrls.byteTypeParam= -webCrawlingConfig.includedDocUrls.floatTypeParam= -webCrawlingConfig.includedDocUrls.doubleTypeParam= -webCrawlingConfig.includedDocUrls.dateTypeParam= -webCrawlingConfig.includedDocUrls.defaultValue= -webCrawlingConfig.excludedDocUrls.requiredParam= -webCrawlingConfig.excludedDocUrls.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -webCrawlingConfig.excludedDocUrls.annotation= -webCrawlingConfig.excludedDocUrls.enableJavaType=true -webCrawlingConfig.excludedDocUrls.longTypeParam= -webCrawlingConfig.excludedDocUrls.integerTypeParam= -webCrawlingConfig.excludedDocUrls.shortTypeParam= -webCrawlingConfig.excludedDocUrls.byteTypeParam= -webCrawlingConfig.excludedDocUrls.floatTypeParam= -webCrawlingConfig.excludedDocUrls.doubleTypeParam= -webCrawlingConfig.excludedDocUrls.dateTypeParam= -webCrawlingConfig.excludedDocUrls.defaultValue= -webCrawlingConfig.configParameter.requiredParam= -webCrawlingConfig.configParameter.additionalAnnotation=@Maxbytelength(maxbytelength = 4000) -webCrawlingConfig.configParameter.annotation= -webCrawlingConfig.configParameter.enableJavaType=true -webCrawlingConfig.configParameter.longTypeParam= -webCrawlingConfig.configParameter.integerTypeParam= -webCrawlingConfig.configParameter.shortTypeParam= -webCrawlingConfig.configParameter.byteTypeParam= -webCrawlingConfig.configParameter.floatTypeParam= -webCrawlingConfig.configParameter.doubleTypeParam= -webCrawlingConfig.configParameter.dateTypeParam= -webCrawlingConfig.configParameter.defaultValue= -webCrawlingConfig.depth.requiredParam= -webCrawlingConfig.depth.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -webCrawlingConfig.depth.annotation= -webCrawlingConfig.depth.enableJavaType=false -webCrawlingConfig.depth.longTypeParam= -webCrawlingConfig.depth.integerTypeParam= -webCrawlingConfig.depth.shortTypeParam= -webCrawlingConfig.depth.byteTypeParam= -webCrawlingConfig.depth.floatTypeParam= -webCrawlingConfig.depth.doubleTypeParam= -webCrawlingConfig.depth.dateTypeParam= -webCrawlingConfig.depth.defaultValue= -webCrawlingConfig.maxAccessCount.requiredParam= -webCrawlingConfig.maxAccessCount.additionalAnnotation=@LongRange(min = 0, max = 9223372036854775807l) -webCrawlingConfig.maxAccessCount.annotation= -webCrawlingConfig.maxAccessCount.enableJavaType=false -webCrawlingConfig.maxAccessCount.longTypeParam= -webCrawlingConfig.maxAccessCount.integerTypeParam= -webCrawlingConfig.maxAccessCount.shortTypeParam= -webCrawlingConfig.maxAccessCount.byteTypeParam= -webCrawlingConfig.maxAccessCount.floatTypeParam= -webCrawlingConfig.maxAccessCount.doubleTypeParam= -webCrawlingConfig.maxAccessCount.dateTypeParam= -webCrawlingConfig.maxAccessCount.defaultValue= -webCrawlingConfig.userAgent.requiredParam= -webCrawlingConfig.userAgent.additionalAnnotation=@Maxbytelength(maxbytelength = 200) -webCrawlingConfig.userAgent.annotation= -webCrawlingConfig.userAgent.enableJavaType=true -webCrawlingConfig.userAgent.longTypeParam= -webCrawlingConfig.userAgent.integerTypeParam= -webCrawlingConfig.userAgent.shortTypeParam= -webCrawlingConfig.userAgent.byteTypeParam= -webCrawlingConfig.userAgent.floatTypeParam= -webCrawlingConfig.userAgent.doubleTypeParam= -webCrawlingConfig.userAgent.dateTypeParam= -webCrawlingConfig.userAgent.defaultValue= -webCrawlingConfig.numOfThread.requiredParam= -webCrawlingConfig.numOfThread.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -webCrawlingConfig.numOfThread.annotation= -webCrawlingConfig.numOfThread.enableJavaType=false -webCrawlingConfig.numOfThread.longTypeParam= -webCrawlingConfig.numOfThread.integerTypeParam= -webCrawlingConfig.numOfThread.shortTypeParam= -webCrawlingConfig.numOfThread.byteTypeParam= -webCrawlingConfig.numOfThread.floatTypeParam= -webCrawlingConfig.numOfThread.doubleTypeParam= -webCrawlingConfig.numOfThread.dateTypeParam= -webCrawlingConfig.numOfThread.defaultValue= -webCrawlingConfig.intervalTime.requiredParam= -webCrawlingConfig.intervalTime.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -webCrawlingConfig.intervalTime.annotation= -webCrawlingConfig.intervalTime.enableJavaType=false -webCrawlingConfig.intervalTime.longTypeParam= -webCrawlingConfig.intervalTime.integerTypeParam= -webCrawlingConfig.intervalTime.shortTypeParam= -webCrawlingConfig.intervalTime.byteTypeParam= -webCrawlingConfig.intervalTime.floatTypeParam= -webCrawlingConfig.intervalTime.doubleTypeParam= -webCrawlingConfig.intervalTime.dateTypeParam= -webCrawlingConfig.intervalTime.defaultValue= -webCrawlingConfig.boost.requiredParam= -webCrawlingConfig.boost.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -webCrawlingConfig.boost.annotation= -webCrawlingConfig.boost.enableJavaType=false -webCrawlingConfig.boost.longTypeParam= -webCrawlingConfig.boost.integerTypeParam= -webCrawlingConfig.boost.shortTypeParam= -webCrawlingConfig.boost.byteTypeParam= -webCrawlingConfig.boost.floatTypeParam= -webCrawlingConfig.boost.doubleTypeParam= -webCrawlingConfig.boost.dateTypeParam= -webCrawlingConfig.boost.defaultValue="1" -webCrawlingConfig.available.requiredParam= -webCrawlingConfig.available.additionalAnnotation=@Maxbytelength(maxbytelength = 1) -webCrawlingConfig.available.annotation= -webCrawlingConfig.available.enableJavaType=true -webCrawlingConfig.available.longTypeParam= -webCrawlingConfig.available.integerTypeParam= -webCrawlingConfig.available.shortTypeParam= -webCrawlingConfig.available.byteTypeParam= -webCrawlingConfig.available.floatTypeParam= -webCrawlingConfig.available.doubleTypeParam= -webCrawlingConfig.available.dateTypeParam= -webCrawlingConfig.available.defaultValue= -webCrawlingConfig.sortOrder.requiredParam=(target = "confirmfromupdate,update,delete") -webCrawlingConfig.sortOrder.additionalAnnotation=@IntRange(min = 0, max = 2147483647) -webCrawlingConfig.sortOrder.annotation= -webCrawlingConfig.sortOrder.enableJavaType=false -webCrawlingConfig.sortOrder.longTypeParam= -webCrawlingConfig.sortOrder.integerTypeParam= -webCrawlingConfig.sortOrder.shortTypeParam= -webCrawlingConfig.sortOrder.byteTypeParam= -webCrawlingConfig.sortOrder.floatTypeParam= -webCrawlingConfig.sortOrder.doubleTypeParam= -webCrawlingConfig.sortOrder.dateTypeParam= -webCrawlingConfig.sortOrder.defaultValue= -webCrawlingConfig.createdBy.requiredParam=(target = "confirmfromupdate,update,delete") -webCrawlingConfig.createdBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -webCrawlingConfig.createdBy.annotation= -webCrawlingConfig.createdBy.enableJavaType=true -webCrawlingConfig.createdBy.longTypeParam= -webCrawlingConfig.createdBy.integerTypeParam= -webCrawlingConfig.createdBy.shortTypeParam= -webCrawlingConfig.createdBy.byteTypeParam= -webCrawlingConfig.createdBy.floatTypeParam= -webCrawlingConfig.createdBy.doubleTypeParam= -webCrawlingConfig.createdBy.dateTypeParam= -webCrawlingConfig.createdBy.defaultValue= -webCrawlingConfig.createdTime.requiredParam=(target = "confirmfromupdate,update,delete") -webCrawlingConfig.createdTime.additionalAnnotation= -webCrawlingConfig.createdTime.annotation= -webCrawlingConfig.createdTime.enableJavaType=true -webCrawlingConfig.createdTime.longTypeParam= -webCrawlingConfig.createdTime.integerTypeParam= -webCrawlingConfig.createdTime.shortTypeParam= -webCrawlingConfig.createdTime.byteTypeParam= -webCrawlingConfig.createdTime.floatTypeParam= -webCrawlingConfig.createdTime.doubleTypeParam= -webCrawlingConfig.createdTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -webCrawlingConfig.createdTime.defaultValue= -webCrawlingConfig.updatedBy.requiredParam= -webCrawlingConfig.updatedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -webCrawlingConfig.updatedBy.annotation= -webCrawlingConfig.updatedBy.enableJavaType=true -webCrawlingConfig.updatedBy.longTypeParam= -webCrawlingConfig.updatedBy.integerTypeParam= -webCrawlingConfig.updatedBy.shortTypeParam= -webCrawlingConfig.updatedBy.byteTypeParam= -webCrawlingConfig.updatedBy.floatTypeParam= -webCrawlingConfig.updatedBy.doubleTypeParam= -webCrawlingConfig.updatedBy.dateTypeParam= -webCrawlingConfig.updatedBy.defaultValue= -webCrawlingConfig.updatedTime.requiredParam= -webCrawlingConfig.updatedTime.additionalAnnotation= -webCrawlingConfig.updatedTime.annotation= -webCrawlingConfig.updatedTime.enableJavaType=true -webCrawlingConfig.updatedTime.longTypeParam= -webCrawlingConfig.updatedTime.integerTypeParam= -webCrawlingConfig.updatedTime.shortTypeParam= -webCrawlingConfig.updatedTime.byteTypeParam= -webCrawlingConfig.updatedTime.floatTypeParam= -webCrawlingConfig.updatedTime.doubleTypeParam= -webCrawlingConfig.updatedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -webCrawlingConfig.updatedTime.defaultValue= -webCrawlingConfig.deletedBy.requiredParam= -webCrawlingConfig.deletedBy.additionalAnnotation=@Maxbytelength(maxbytelength = 255) -webCrawlingConfig.deletedBy.annotation= -webCrawlingConfig.deletedBy.enableJavaType=true -webCrawlingConfig.deletedBy.longTypeParam= -webCrawlingConfig.deletedBy.integerTypeParam= -webCrawlingConfig.deletedBy.shortTypeParam= -webCrawlingConfig.deletedBy.byteTypeParam= -webCrawlingConfig.deletedBy.floatTypeParam= -webCrawlingConfig.deletedBy.doubleTypeParam= -webCrawlingConfig.deletedBy.dateTypeParam= -webCrawlingConfig.deletedBy.defaultValue= -webCrawlingConfig.deletedTime.requiredParam= -webCrawlingConfig.deletedTime.additionalAnnotation= -webCrawlingConfig.deletedTime.annotation= -webCrawlingConfig.deletedTime.enableJavaType=true -webCrawlingConfig.deletedTime.longTypeParam= -webCrawlingConfig.deletedTime.integerTypeParam= -webCrawlingConfig.deletedTime.shortTypeParam= -webCrawlingConfig.deletedTime.byteTypeParam= -webCrawlingConfig.deletedTime.floatTypeParam= -webCrawlingConfig.deletedTime.doubleTypeParam= -webCrawlingConfig.deletedTime.dateTypeParam=(datePattern = Constants.DEFAULT_DATETIME_FORMAT) -webCrawlingConfig.deletedTime.defaultValue= -webCrawlingConfig.versionNo.requiredParam=(target = "confirmfromupdate,update,delete") -webCrawlingConfig.versionNo.additionalAnnotation= -webCrawlingConfig.versionNo.annotation= -webCrawlingConfig.versionNo.enableJavaType=true -webCrawlingConfig.versionNo.longTypeParam= -webCrawlingConfig.versionNo.integerTypeParam= -webCrawlingConfig.versionNo.shortTypeParam= -webCrawlingConfig.versionNo.byteTypeParam= -webCrawlingConfig.versionNo.floatTypeParam= -webCrawlingConfig.versionNo.doubleTypeParam= -webCrawlingConfig.versionNo.dateTypeParam= -webCrawlingConfig.versionNo.defaultValue= - diff --git a/src/main/java/org/codelibs/fess/Constants.java b/src/main/java/org/codelibs/fess/Constants.java index 89a994a34..9b2dced9b 100644 --- a/src/main/java/org/codelibs/fess/Constants.java +++ b/src/main/java/org/codelibs/fess/Constants.java @@ -88,12 +88,6 @@ public class Constants extends CoreLibConstants { public static final long DEFAULT_CRAWLING_EXECUTION_INTERVAL = 5000L; - /** Solr Status: Active */ - public static final String ACTIVE = "ACTIVE"; - - /** Solr Status: Inactive */ - public static final String INACTIVE = "INACTIVE"; - // fess properties public static final String USER_INFO_PROPERTY = "user.info"; @@ -232,9 +226,9 @@ public class Constants extends CoreLibConstants { public static final String[] RESERVED = { "+", "-", "&&", "||", "!", "(", ")", "{", "}", "[", "]", "^", "~", "*", "?", "\\", ";", ":", "/" }; - public static final Pattern SOLR_FIELD_RESERVED_PATTERN = Pattern.compile("([+\\-!\\(\\){}\\[\\]^\"~\\\\:\\p{Zs}]|(&&)|(\\|\\|))"); // "*", "?", + public static final Pattern LUCENE_FIELD_RESERVED_PATTERN = Pattern.compile("([+\\-!\\(\\){}\\[\\]^\"~\\\\:\\p{Zs}]|(&&)|(\\|\\|))"); // "*", "?", - public static final Pattern SOLR_RANGE_FIELD_RESERVED_PATTERN = Pattern.compile("([!\\(\\){}\\[\\]\"~\\\\:\\p{Zs}]|(&&)|(\\|\\|))"); + public static final Pattern LUCENE_RANGE_FIELD_RESERVED_PATTERN = Pattern.compile("([!\\(\\){}\\[\\]\"~\\\\:\\p{Zs}]|(&&)|(\\|\\|))"); public static final String SEARCH_LOG_ACCESS_TYPE = "searchLogAccessType"; @@ -252,8 +246,6 @@ public class Constants extends CoreLibConstants { public static final String SEARCH_FIELD_LOG_SEARCH_QUERY = "query"; - public static final String SEARCH_FIELD_LOG_SOLR_QUERY = "solrQuery"; - public static final String STATS_REPORT_TYPE = "reportType"; public static final String RESULT_DOC_ID_CACHE = "resultDocIds"; @@ -305,14 +297,14 @@ public class Constants extends CoreLibConstants { public static final String INVALID_NUMERIC_PARAMETER = "-1"; - public static final String NOW = "NOW"; - public static final String FACET_FIELD_PREFIX = "field:"; public static final String FACET_QUERY_PREFIX = "query:"; public static final String FESS_ES_TRANSPORT_ADDRESSES = "fess.es.transport_addresses"; + public static final String FESS_ES_CLUSTER_NAME = "fess.es.cluster_name"; + public static final int DEFAULT_PAGE_SIZE = 20; public static final int DEFAULT_START_COUNT = 0; @@ -325,4 +317,14 @@ public class Constants extends CoreLibConstants { public static final long ONE_DAY_IN_MILLIS = 24L * 60L * 60L * 1000L; + public static final String GUEST_USER = "guest"; + + public static final String[] PAGER_CONVERSION_RULE = { "allRecordCount", "pageSize", "currentPageNumber", "allPageCount", + "existPrePage", "existNextPage" }; + + // TODO remove searchParams + public static final String[] COMMON_CONVERSION_RULE = new String[] { "searchParams", "crudMode", "createdBy", "createdTime", + "updatedBy", "updatedTime" }; + + public static final String USER_INFO = "LoginInfo"; } diff --git a/src/main/java/org/codelibs/fess/FessBoot.java b/src/main/java/org/codelibs/fess/FessBoot.java new file mode 100644 index 000000000..593bc2784 --- /dev/null +++ b/src/main/java/org/codelibs/fess/FessBoot.java @@ -0,0 +1,128 @@ +package org.codelibs.fess; + +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.nio.ByteBuffer; +import java.util.logging.Level; +import java.util.logging.LogManager; +import java.util.logging.Logger; +import java.util.regex.Pattern; + +import org.dbflute.tomcat.TomcatBoot; + +public class FessBoot extends TomcatBoot { + + private static final Logger logger = Logger.getLogger(FessBoot.class.getPackage().getName()); + + private static final String LOGGING_PROPERTIES = "/logging.properties"; + + private static final String FESS_CONTEXT_PATH = "fess.context.path"; + + private static final String FESS_PORT = "fess.port"; + + private static final String FESS_TEMP_PATH = "fess.temp.path"; + + private static final String FESS_WEBXML_PATH = "fess.webxml.path"; + + private static final String FESS_WEBAPP_PATH = "fess.webapp.path"; + + private static final String JAVA_IO_TMPDIR = "java.io.tmpdir"; + + private static final int DEFAULT_BUF_SIZE = 4096; + + private static final String UTF_8 = "UTF-8"; + + public FessBoot(final int port, final String contextPath) { + super(port, contextPath); + } + + @Override + protected String prepareWebappPath() { + final String value = System.getProperty(FESS_WEBAPP_PATH); + if (value != null) { + return value; + } + return super.prepareWebappPath(); + } + + @Override + protected String prepareWebXmlPath() { + final String value = System.getProperty(FESS_WEBXML_PATH); + if (value != null) { + return value; + } + return super.prepareWebXmlPath(); + } + + @Override + protected String getMarkDir() { + return new File(System.getProperty(JAVA_IO_TMPDIR), "fessboot").getAbsolutePath(); + } + + @Override + protected void info(final String msg) { + logger.info(msg); + } + + // =================================================================================== + // main + // ============ + + public static void main(final String[] args) { + // load logging.properties + try (InputStream is = FessBoot.class.getResourceAsStream(LOGGING_PROPERTIES)) { + if (is != null) { + try (ByteArrayOutputStream out = new ByteArrayOutputStream()) { + final ByteBuffer buffer = ByteBuffer.allocate(DEFAULT_BUF_SIZE); + final byte[] buf = buffer.array(); + int len; + while ((len = is.read(buf)) != -1) { + out.write(buf, 0, len); + } + + String configContent = out.toString(UTF_8); + final String fessHomeDir = System.getProperty("fess.home"); + if (fessHomeDir != null) { + configContent = configContent.replaceAll(Pattern.quote("${fess.home}"), fessHomeDir); + } + + LogManager.getLogManager().readConfiguration(new ByteArrayInputStream(configContent.getBytes(UTF_8))); + logger.info(LOGGING_PROPERTIES + " is loaded."); + } + } + } catch (final IOException e) { + logger.log(Level.WARNING, "Failed to load " + LOGGING_PROPERTIES, e); + } + + // update java.io.tmpdir + final String value = System.getProperty(FESS_TEMP_PATH); + if (value != null) { + System.setProperty(JAVA_IO_TMPDIR, value); + } + + new FessBoot(getPort(), getContextPath()).useTldDetect().asDevelopment(isNoneEnv()).bootAwait(); + } + + private static boolean isNoneEnv() { + return System.getProperty("lasta.env") == null; + } + + protected static int getPort() { + final String value = System.getProperty(FESS_PORT); + if (value != null) { + return Integer.parseInt(value); + } + return 8080; + } + + protected static String getContextPath() { + final String value = System.getProperty(FESS_CONTEXT_PATH); + if (value != null) { + return value; + } + return "/fess"; + } +} diff --git a/src/main/java/org/codelibs/fess/annotation/CronExpression.java b/src/main/java/org/codelibs/fess/annotation/CronExpression.java index 6a98500fa..2ee243fb1 100644 --- a/src/main/java/org/codelibs/fess/annotation/CronExpression.java +++ b/src/main/java/org/codelibs/fess/annotation/CronExpression.java @@ -22,27 +22,24 @@ import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; import org.codelibs.core.lang.StringUtil; -import org.seasar.struts.annotation.Arg; -import org.seasar.struts.annotation.Msg; -import org.seasar.struts.annotation.Validator; @Retention(RetentionPolicy.RUNTIME) @Target(ElementType.FIELD) -@Validator("cronExpression") +//@Validator("cronExpression") public @interface CronExpression { /** * A validation message. * * @return */ - Msg msg() default @Msg(key = "errors.cronexpression"); + //Msg msg() default @Msg(key = "errors.cronexpression"); /** * Argument for a message * * @return */ - Arg arg0() default @Arg(key = StringUtil.EMPTY); + //Arg arg0() default @Arg(key = StringUtil.EMPTY); /** * a target name for this validation diff --git a/src/main/java/org/codelibs/sastruts/core/annotation/Token.java b/src/main/java/org/codelibs/fess/annotation/Token.java similarity index 95% rename from src/main/java/org/codelibs/sastruts/core/annotation/Token.java rename to src/main/java/org/codelibs/fess/annotation/Token.java index bb55cbdc0..eec20dde8 100644 --- a/src/main/java/org/codelibs/sastruts/core/annotation/Token.java +++ b/src/main/java/org/codelibs/fess/annotation/Token.java @@ -13,7 +13,7 @@ * either express or implied. See the License for the specific language * governing permissions and limitations under the License. */ -package org.codelibs.sastruts.core.annotation; +package org.codelibs.fess.annotation; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; @@ -22,7 +22,7 @@ import java.lang.annotation.Target; /** * @author shinsuke - * + * */ @Target(ElementType.METHOD) @Retention(RetentionPolicy.RUNTIME) diff --git a/src/main/java/org/codelibs/fess/annotation/UriType.java b/src/main/java/org/codelibs/fess/annotation/UriType.java index a914ff842..6e0f9ef83 100644 --- a/src/main/java/org/codelibs/fess/annotation/UriType.java +++ b/src/main/java/org/codelibs/fess/annotation/UriType.java @@ -22,13 +22,10 @@ import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; import org.codelibs.core.lang.StringUtil; -import org.seasar.struts.annotation.Arg; -import org.seasar.struts.annotation.Msg; -import org.seasar.struts.annotation.Validator; @Retention(RetentionPolicy.RUNTIME) @Target(ElementType.FIELD) -@Validator("uriType") +//@Validator("uriType") public @interface UriType { String protocols(); @@ -38,14 +35,14 @@ public @interface UriType { * * @return */ - Msg msg() default @Msg(key = "errors.cronexpression"); + //Msg msg() default @Msg(key = "errors.cronexpression"); /** * Argument for a message * * @return */ - Arg arg0() default @Arg(key = StringUtil.EMPTY); + //Arg arg0() default @Arg(key = StringUtil.EMPTY); /** * a target name for this validation diff --git a/src/main/java/org/codelibs/sastruts/core/annotation/User.java b/src/main/java/org/codelibs/fess/annotation/User.java similarity index 94% rename from src/main/java/org/codelibs/sastruts/core/annotation/User.java rename to src/main/java/org/codelibs/fess/annotation/User.java index 182304d50..ae1347e6a 100644 --- a/src/main/java/org/codelibs/sastruts/core/annotation/User.java +++ b/src/main/java/org/codelibs/fess/annotation/User.java @@ -13,7 +13,7 @@ * either express or implied. See the License for the specific language * governing permissions and limitations under the License. */ -package org.codelibs.sastruts.core.annotation; +package org.codelibs.fess.annotation; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; @@ -22,7 +22,7 @@ import java.lang.annotation.Target; /** * @author shinsuke - * + * */ @Target({ ElementType.FIELD, ElementType.METHOD }) @Retention(RetentionPolicy.RUNTIME) diff --git a/src/main/java/org/codelibs/fess/api/BaseApiManager.java b/src/main/java/org/codelibs/fess/api/BaseApiManager.java index 535cc4f82..581249435 100644 --- a/src/main/java/org/codelibs/fess/api/BaseApiManager.java +++ b/src/main/java/org/codelibs/fess/api/BaseApiManager.java @@ -16,6 +16,16 @@ package org.codelibs.fess.api; +import java.io.IOException; +import java.io.OutputStreamWriter; +import java.io.PrintWriter; + +import javax.servlet.http.HttpServletResponse; + +import org.codelibs.core.exception.IORuntimeException; +import org.lastaflute.web.util.LaRequestUtil; +import org.lastaflute.web.util.LaResponseUtil; + public class BaseApiManager { protected static final String FAVORITES_API = "/favoritesApi"; @@ -60,4 +70,31 @@ public class BaseApiManager { } } + public static void write(final String text, String contentType, String encoding) { + if (contentType == null) { + contentType = "text/plain"; + } + if (encoding == null) { + encoding = LaRequestUtil.getRequest().getCharacterEncoding(); + if (encoding == null) { + encoding = "UTF-8"; + } + } + final HttpServletResponse response = LaResponseUtil.getResponse(); + response.setContentType(contentType + "; charset=" + encoding); + try { + PrintWriter out = null; + try { + out = new PrintWriter(new OutputStreamWriter(response.getOutputStream(), encoding)); + out.print(text); + } finally { + if (out != null) { + out.close(); + } + } + } catch (final IOException e) { + throw new IORuntimeException(e); + } + } + } \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/api/json/JsonApiManager.java b/src/main/java/org/codelibs/fess/api/json/JsonApiManager.java index b99ca7410..e0c2a75cf 100644 --- a/src/main/java/org/codelibs/fess/api/json/JsonApiManager.java +++ b/src/main/java/org/codelibs/fess/api/json/JsonApiManager.java @@ -28,24 +28,23 @@ import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; -import org.apache.commons.lang.StringEscapeUtils; +import org.apache.commons.lang3.StringEscapeUtils; import org.codelibs.core.CoreLibConstants; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.WebApiException; import org.codelibs.fess.api.BaseApiManager; import org.codelibs.fess.api.WebApiManager; import org.codelibs.fess.api.WebApiRequest; import org.codelibs.fess.api.WebApiResponse; -import org.codelibs.fess.client.FessEsClient; import org.codelibs.fess.entity.PingResponse; +import org.codelibs.fess.es.client.FessEsClient; +import org.codelibs.fess.exception.WebApiException; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.fess.util.FacetResponse; import org.codelibs.fess.util.FacetResponse.Field; import org.codelibs.fess.util.MoreLikeThisResponse; import org.codelibs.fess.util.WebApiUtil; -import org.seasar.struts.util.RequestUtil; -import org.seasar.struts.util.ResponseUtil; +import org.lastaflute.web.util.LaRequestUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -519,7 +518,7 @@ public class JsonApiManager extends BaseApiManager implements WebApiManager { } protected void writeJsonResponse(final int status, final String body, final String errMsg) { - final String callback = RequestUtil.getRequest().getParameter("callback"); + final String callback = LaRequestUtil.getRequest().getParameter("callback"); final boolean isJsonp = StringUtil.isNotBlank(callback); final StringBuilder buf = new StringBuilder(1000); @@ -548,7 +547,7 @@ public class JsonApiManager extends BaseApiManager implements WebApiManager { if (isJsonp) { buf.append(')'); } - ResponseUtil.write(buf.toString(), "text/javascript+json", Constants.UTF_8); + write(buf.toString(), "text/javascript+json", Constants.UTF_8); } diff --git a/src/main/java/org/codelibs/fess/api/xml/XmlApiManager.java b/src/main/java/org/codelibs/fess/api/xml/XmlApiManager.java index 1751b5951..0c4c5af35 100644 --- a/src/main/java/org/codelibs/fess/api/xml/XmlApiManager.java +++ b/src/main/java/org/codelibs/fess/api/xml/XmlApiManager.java @@ -27,7 +27,7 @@ import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; -import org.apache.commons.lang.StringEscapeUtils; +import org.apache.commons.lang3.StringEscapeUtils; import org.codelibs.core.CoreLibConstants; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; @@ -35,14 +35,13 @@ import org.codelibs.fess.api.BaseApiManager; import org.codelibs.fess.api.WebApiManager; import org.codelibs.fess.api.WebApiRequest; import org.codelibs.fess.api.WebApiResponse; -import org.codelibs.fess.client.FessEsClient; import org.codelibs.fess.entity.PingResponse; +import org.codelibs.fess.es.client.FessEsClient; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.fess.util.FacetResponse; import org.codelibs.fess.util.FacetResponse.Field; import org.codelibs.fess.util.MoreLikeThisResponse; import org.codelibs.fess.util.WebApiUtil; -import org.seasar.struts.util.ResponseUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -375,7 +374,7 @@ public class XmlApiManager extends BaseApiManager implements WebApiManager { buf.append(""); } buf.append(""); - ResponseUtil.write(buf.toString(), "text/xml", Constants.UTF_8); + write(buf.toString(), "text/xml", Constants.UTF_8); } diff --git a/src/main/java/org/codelibs/fess/pager/BoostDocumentRulePager.java b/src/main/java/org/codelibs/fess/app/pager/BoostDocumentRulePager.java similarity index 98% rename from src/main/java/org/codelibs/fess/pager/BoostDocumentRulePager.java rename to src/main/java/org/codelibs/fess/app/pager/BoostDocumentRulePager.java index 3c4eba929..bf5357183 100644 --- a/src/main/java/org/codelibs/fess/pager/BoostDocumentRulePager.java +++ b/src/main/java/org/codelibs/fess/app/pager/BoostDocumentRulePager.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; import java.io.Serializable; import java.util.List; diff --git a/src/main/java/org/codelibs/fess/pager/CrawlingSessionPager.java b/src/main/java/org/codelibs/fess/app/pager/CrawlingSessionPager.java similarity index 94% rename from src/main/java/org/codelibs/fess/pager/CrawlingSessionPager.java rename to src/main/java/org/codelibs/fess/app/pager/CrawlingSessionPager.java index 44037c872..f8a29297d 100644 --- a/src/main/java/org/codelibs/fess/pager/CrawlingSessionPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/CrawlingSessionPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class CrawlingSessionPager { +public class CrawlingSessionPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/DataConfigPager.java b/src/main/java/org/codelibs/fess/app/pager/DataConfigPager.java similarity index 95% rename from src/main/java/org/codelibs/fess/pager/DataConfigPager.java rename to src/main/java/org/codelibs/fess/app/pager/DataConfigPager.java index 6b1471ff7..864941579 100644 --- a/src/main/java/org/codelibs/fess/pager/DataConfigPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/DataConfigPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class DataConfigPager { +public class DataConfigPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/FailureUrlPager.java b/src/main/java/org/codelibs/fess/app/pager/FailureUrlPager.java similarity index 90% rename from src/main/java/org/codelibs/fess/pager/FailureUrlPager.java rename to src/main/java/org/codelibs/fess/app/pager/FailureUrlPager.java index a6b25286b..230ba5f9a 100644 --- a/src/main/java/org/codelibs/fess/pager/FailureUrlPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/FailureUrlPager.java @@ -14,26 +14,27 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.Maxbytelength; -public class FailureUrlPager { +public class FailureUrlPager implements Serializable { - @Maxbytelength(maxbytelength = 1000) + private static final long serialVersionUID = 1L; + + //@Maxbytelength(maxbytelength = 1000) public String url; - @IntRange(min = 0, max = 2147483647) + //@IntRange(min = 0, max = 2147483647) public String errorCountMin; - @IntRange(min = 0, max = 2147483647) + //@IntRange(min = 0, max = 2147483647) public String errorCountMax; - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String errorName; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/FileAuthenticationPager.java b/src/main/java/org/codelibs/fess/app/pager/FileAuthenticationPager.java similarity index 94% rename from src/main/java/org/codelibs/fess/pager/FileAuthenticationPager.java rename to src/main/java/org/codelibs/fess/app/pager/FileAuthenticationPager.java index dc403818b..c7fcf0637 100644 --- a/src/main/java/org/codelibs/fess/pager/FileAuthenticationPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/FileAuthenticationPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class FileAuthenticationPager { +public class FileAuthenticationPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/FileConfigPager.java b/src/main/java/org/codelibs/fess/app/pager/FileConfigPager.java similarity index 95% rename from src/main/java/org/codelibs/fess/pager/FileConfigPager.java rename to src/main/java/org/codelibs/fess/app/pager/FileConfigPager.java index 2136f7755..641c2472a 100644 --- a/src/main/java/org/codelibs/fess/pager/FileConfigPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/FileConfigPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class FileConfigPager { +public class FileConfigPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/app/pager/GroupPager.java b/src/main/java/org/codelibs/fess/app/pager/GroupPager.java new file mode 100644 index 000000000..82b323290 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/pager/GroupPager.java @@ -0,0 +1,132 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.pager; + +import java.io.Serializable; +import java.util.List; + +import org.codelibs.fess.Constants; + +public class GroupPager implements Serializable { + + private static final long serialVersionUID = 1L; + + public static final int DEFAULT_PAGE_SIZE = 20; + + public static final int DEFAULT_CURRENT_PAGE_NUMBER = 1; + + private int allRecordCount; + + private int allPageCount; + + private boolean existPrePage; + + private boolean existNextPage; + + private List pageNumberList; + + private int pageSize; + + private int currentPageNumber; + + public String id; + + public String name; + + public String versionNo; + + public void clear() { + pageSize = getDefaultPageSize(); + currentPageNumber = getDefaultCurrentPageNumber(); + + id = null; + name = null; + versionNo = null; + + } + + protected int getDefaultCurrentPageNumber() { + return DEFAULT_CURRENT_PAGE_NUMBER; + } + + public int getAllRecordCount() { + return allRecordCount; + } + + public void setAllRecordCount(final int allRecordCount) { + this.allRecordCount = allRecordCount; + } + + public int getAllPageCount() { + return allPageCount; + } + + public void setAllPageCount(final int allPageCount) { + this.allPageCount = allPageCount; + } + + public boolean isExistPrePage() { + return existPrePage; + } + + public void setExistPrePage(final boolean existPrePage) { + this.existPrePage = existPrePage; + } + + public boolean isExistNextPage() { + return existNextPage; + } + + public void setExistNextPage(final boolean existNextPage) { + this.existNextPage = existNextPage; + } + + public int getPageSize() { + if (pageSize <= 0) { + pageSize = getDefaultPageSize(); + } + return pageSize; + } + + public void setPageSize(final int pageSize) { + this.pageSize = pageSize; + } + + public int getCurrentPageNumber() { + if (currentPageNumber <= 0) { + currentPageNumber = getDefaultCurrentPageNumber(); + } + return currentPageNumber; + } + + public void setCurrentPageNumber(final int currentPageNumber) { + this.currentPageNumber = currentPageNumber; + } + + public List getPageNumberList() { + return pageNumberList; + } + + public void setPageNumberList(final List pageNumberList) { + this.pageNumberList = pageNumberList; + } + + protected int getDefaultPageSize() { + return Constants.DEFAULT_ADMIN_PAGE_SIZE; + } + +} diff --git a/src/main/java/org/codelibs/fess/pager/JobLogPager.java b/src/main/java/org/codelibs/fess/app/pager/JobLogPager.java similarity index 95% rename from src/main/java/org/codelibs/fess/pager/JobLogPager.java rename to src/main/java/org/codelibs/fess/app/pager/JobLogPager.java index 17b129422..dcfdd3299 100644 --- a/src/main/java/org/codelibs/fess/pager/JobLogPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/JobLogPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class JobLogPager { +public class JobLogPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/KeyMatchPager.java b/src/main/java/org/codelibs/fess/app/pager/KeyMatchPager.java similarity index 95% rename from src/main/java/org/codelibs/fess/pager/KeyMatchPager.java rename to src/main/java/org/codelibs/fess/app/pager/KeyMatchPager.java index 2fcabf9ad..9af5f3e79 100644 --- a/src/main/java/org/codelibs/fess/pager/KeyMatchPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/KeyMatchPager.java @@ -14,17 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class KeyMatchPager { +public class KeyMatchPager implements Serializable { - public KeyMatchPager() { - super(); - } + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/LabelTypePager.java b/src/main/java/org/codelibs/fess/app/pager/LabelTypePager.java similarity index 95% rename from src/main/java/org/codelibs/fess/pager/LabelTypePager.java rename to src/main/java/org/codelibs/fess/app/pager/LabelTypePager.java index 555027782..a53869023 100644 --- a/src/main/java/org/codelibs/fess/pager/LabelTypePager.java +++ b/src/main/java/org/codelibs/fess/app/pager/LabelTypePager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class LabelTypePager { +public class LabelTypePager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/OverlappingHostPager.java b/src/main/java/org/codelibs/fess/app/pager/OverlappingHostPager.java similarity index 94% rename from src/main/java/org/codelibs/fess/pager/OverlappingHostPager.java rename to src/main/java/org/codelibs/fess/app/pager/OverlappingHostPager.java index 679480510..55fca92d1 100644 --- a/src/main/java/org/codelibs/fess/pager/OverlappingHostPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/OverlappingHostPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class OverlappingHostPager { +public class OverlappingHostPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/PathMappingPager.java b/src/main/java/org/codelibs/fess/app/pager/PathMappingPager.java similarity index 95% rename from src/main/java/org/codelibs/fess/pager/PathMappingPager.java rename to src/main/java/org/codelibs/fess/app/pager/PathMappingPager.java index 9b5d8bb05..0e7caf256 100644 --- a/src/main/java/org/codelibs/fess/pager/PathMappingPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/PathMappingPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class PathMappingPager { +public class PathMappingPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/RequestHeaderPager.java b/src/main/java/org/codelibs/fess/app/pager/RequestHeaderPager.java similarity index 94% rename from src/main/java/org/codelibs/fess/pager/RequestHeaderPager.java rename to src/main/java/org/codelibs/fess/app/pager/RequestHeaderPager.java index d3b7319f3..8e3fe215a 100644 --- a/src/main/java/org/codelibs/fess/pager/RequestHeaderPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/RequestHeaderPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class RequestHeaderPager { +public class RequestHeaderPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/app/pager/RolePager.java b/src/main/java/org/codelibs/fess/app/pager/RolePager.java new file mode 100644 index 000000000..29e0ab2a1 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/pager/RolePager.java @@ -0,0 +1,132 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.pager; + +import java.io.Serializable; +import java.util.List; + +import org.codelibs.fess.Constants; + +public class RolePager implements Serializable { + + private static final long serialVersionUID = 1L; + + public static final int DEFAULT_PAGE_SIZE = 20; + + public static final int DEFAULT_CURRENT_PAGE_NUMBER = 1; + + private int allRecordCount; + + private int allPageCount; + + private boolean existPrePage; + + private boolean existNextPage; + + private List pageNumberList; + + private int pageSize; + + private int currentPageNumber; + + public String id; + + public String name; + + public String versionNo; + + public void clear() { + pageSize = getDefaultPageSize(); + currentPageNumber = getDefaultCurrentPageNumber(); + + id = null; + name = null; + versionNo = null; + + } + + protected int getDefaultCurrentPageNumber() { + return DEFAULT_CURRENT_PAGE_NUMBER; + } + + public int getAllRecordCount() { + return allRecordCount; + } + + public void setAllRecordCount(final int allRecordCount) { + this.allRecordCount = allRecordCount; + } + + public int getAllPageCount() { + return allPageCount; + } + + public void setAllPageCount(final int allPageCount) { + this.allPageCount = allPageCount; + } + + public boolean isExistPrePage() { + return existPrePage; + } + + public void setExistPrePage(final boolean existPrePage) { + this.existPrePage = existPrePage; + } + + public boolean isExistNextPage() { + return existNextPage; + } + + public void setExistNextPage(final boolean existNextPage) { + this.existNextPage = existNextPage; + } + + public int getPageSize() { + if (pageSize <= 0) { + pageSize = getDefaultPageSize(); + } + return pageSize; + } + + public void setPageSize(final int pageSize) { + this.pageSize = pageSize; + } + + public int getCurrentPageNumber() { + if (currentPageNumber <= 0) { + currentPageNumber = getDefaultCurrentPageNumber(); + } + return currentPageNumber; + } + + public void setCurrentPageNumber(final int currentPageNumber) { + this.currentPageNumber = currentPageNumber; + } + + public List getPageNumberList() { + return pageNumberList; + } + + public void setPageNumberList(final List pageNumberList) { + this.pageNumberList = pageNumberList; + } + + protected int getDefaultPageSize() { + return Constants.DEFAULT_ADMIN_PAGE_SIZE; + } + +} diff --git a/src/main/java/org/codelibs/fess/pager/RoleTypePager.java b/src/main/java/org/codelibs/fess/app/pager/RoleTypePager.java similarity index 95% rename from src/main/java/org/codelibs/fess/pager/RoleTypePager.java rename to src/main/java/org/codelibs/fess/app/pager/RoleTypePager.java index d284524c8..1f8aecda7 100644 --- a/src/main/java/org/codelibs/fess/pager/RoleTypePager.java +++ b/src/main/java/org/codelibs/fess/app/pager/RoleTypePager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class RoleTypePager { +public class RoleTypePager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/ScheduledJobPager.java b/src/main/java/org/codelibs/fess/app/pager/ScheduledJobPager.java similarity index 95% rename from src/main/java/org/codelibs/fess/pager/ScheduledJobPager.java rename to src/main/java/org/codelibs/fess/app/pager/ScheduledJobPager.java index 5704c5f76..d3a52192f 100644 --- a/src/main/java/org/codelibs/fess/pager/ScheduledJobPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/ScheduledJobPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class ScheduledJobPager { +public class ScheduledJobPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/SuggestBadWordPager.java b/src/main/java/org/codelibs/fess/app/pager/SuggestBadWordPager.java similarity index 94% rename from src/main/java/org/codelibs/fess/pager/SuggestBadWordPager.java rename to src/main/java/org/codelibs/fess/app/pager/SuggestBadWordPager.java index b51abda85..2200d9d91 100644 --- a/src/main/java/org/codelibs/fess/pager/SuggestBadWordPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/SuggestBadWordPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class SuggestBadWordPager { +public class SuggestBadWordPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/SuggestElevateWordPager.java b/src/main/java/org/codelibs/fess/app/pager/SuggestElevateWordPager.java similarity index 94% rename from src/main/java/org/codelibs/fess/pager/SuggestElevateWordPager.java rename to src/main/java/org/codelibs/fess/app/pager/SuggestElevateWordPager.java index 235a046ff..6cc63aa1f 100644 --- a/src/main/java/org/codelibs/fess/pager/SuggestElevateWordPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/SuggestElevateWordPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class SuggestElevateWordPager { +public class SuggestElevateWordPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/SynonymPager.java b/src/main/java/org/codelibs/fess/app/pager/SynonymPager.java similarity index 98% rename from src/main/java/org/codelibs/fess/pager/SynonymPager.java rename to src/main/java/org/codelibs/fess/app/pager/SynonymPager.java index e4376892b..04b01d2e1 100644 --- a/src/main/java/org/codelibs/fess/pager/SynonymPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/SynonymPager.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; import java.io.Serializable; import java.util.List; diff --git a/src/main/java/org/codelibs/fess/pager/UserDictPager.java b/src/main/java/org/codelibs/fess/app/pager/UserDictPager.java similarity index 98% rename from src/main/java/org/codelibs/fess/pager/UserDictPager.java rename to src/main/java/org/codelibs/fess/app/pager/UserDictPager.java index 9646f6348..c6a1d536d 100644 --- a/src/main/java/org/codelibs/fess/pager/UserDictPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/UserDictPager.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; import java.io.Serializable; import java.util.List; diff --git a/src/main/java/org/codelibs/fess/app/pager/UserPager.java b/src/main/java/org/codelibs/fess/app/pager/UserPager.java new file mode 100644 index 000000000..7b30f7eee --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/pager/UserPager.java @@ -0,0 +1,136 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.pager; + +import java.io.Serializable; +import java.util.List; + +import org.codelibs.fess.Constants; + +public class UserPager implements Serializable { + + private static final long serialVersionUID = 1L; + + public static final int DEFAULT_PAGE_SIZE = 20; + + public static final int DEFAULT_CURRENT_PAGE_NUMBER = 1; + + private int allRecordCount; + + private int allPageCount; + + private boolean existPrePage; + + private boolean existNextPage; + + private List pageNumberList; + + private int pageSize; + + private int currentPageNumber; + + public String id; + + public String name; + + public String[] roles; + public String[] groups; + + public String versionNo; + + public void clear() { + pageSize = getDefaultPageSize(); + currentPageNumber = getDefaultCurrentPageNumber(); + + id = null; + roles = null; + groups = null; + versionNo = null; + + } + + protected int getDefaultCurrentPageNumber() { + return DEFAULT_CURRENT_PAGE_NUMBER; + } + + public int getAllRecordCount() { + return allRecordCount; + } + + public void setAllRecordCount(final int allRecordCount) { + this.allRecordCount = allRecordCount; + } + + public int getAllPageCount() { + return allPageCount; + } + + public void setAllPageCount(final int allPageCount) { + this.allPageCount = allPageCount; + } + + public boolean isExistPrePage() { + return existPrePage; + } + + public void setExistPrePage(final boolean existPrePage) { + this.existPrePage = existPrePage; + } + + public boolean isExistNextPage() { + return existNextPage; + } + + public void setExistNextPage(final boolean existNextPage) { + this.existNextPage = existNextPage; + } + + public int getPageSize() { + if (pageSize <= 0) { + pageSize = getDefaultPageSize(); + } + return pageSize; + } + + public void setPageSize(final int pageSize) { + this.pageSize = pageSize; + } + + public int getCurrentPageNumber() { + if (currentPageNumber <= 0) { + currentPageNumber = getDefaultCurrentPageNumber(); + } + return currentPageNumber; + } + + public void setCurrentPageNumber(final int currentPageNumber) { + this.currentPageNumber = currentPageNumber; + } + + public List getPageNumberList() { + return pageNumberList; + } + + public void setPageNumberList(final List pageNumberList) { + this.pageNumberList = pageNumberList; + } + + protected int getDefaultPageSize() { + return Constants.DEFAULT_ADMIN_PAGE_SIZE; + } + +} diff --git a/src/main/java/org/codelibs/fess/pager/WebAuthenticationPager.java b/src/main/java/org/codelibs/fess/app/pager/WebAuthenticationPager.java similarity index 94% rename from src/main/java/org/codelibs/fess/pager/WebAuthenticationPager.java rename to src/main/java/org/codelibs/fess/app/pager/WebAuthenticationPager.java index 7a7e43004..1ffd15141 100644 --- a/src/main/java/org/codelibs/fess/pager/WebAuthenticationPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/WebAuthenticationPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class WebAuthenticationPager { +public class WebAuthenticationPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/pager/WebConfigPager.java b/src/main/java/org/codelibs/fess/app/pager/WebConfigPager.java similarity index 95% rename from src/main/java/org/codelibs/fess/pager/WebConfigPager.java rename to src/main/java/org/codelibs/fess/app/pager/WebConfigPager.java index b7945f0e5..9f3328d0a 100644 --- a/src/main/java/org/codelibs/fess/pager/WebConfigPager.java +++ b/src/main/java/org/codelibs/fess/app/pager/WebConfigPager.java @@ -14,13 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.pager; +package org.codelibs.fess.app.pager; +import java.io.Serializable; import java.util.List; import org.codelibs.fess.Constants; -public class WebConfigPager { +public class WebConfigPager implements Serializable { + + private static final long serialVersionUID = 1L; public static final int DEFAULT_PAGE_SIZE = 20; diff --git a/src/main/java/org/codelibs/fess/service/BoostDocumentRuleService.java b/src/main/java/org/codelibs/fess/app/service/BoostDocumentRuleService.java similarity index 78% rename from src/main/java/org/codelibs/fess/service/BoostDocumentRuleService.java rename to src/main/java/org/codelibs/fess/app/service/BoostDocumentRuleService.java index 21b035baf..8685f18e3 100644 --- a/src/main/java/org/codelibs/fess/service/BoostDocumentRuleService.java +++ b/src/main/java/org/codelibs/fess/app/service/BoostDocumentRuleService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.List; @@ -22,14 +22,14 @@ import java.util.Map; import javax.annotation.Resource; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.BoostDocumentRulePager; import org.codelibs.fess.es.cbean.BoostDocumentRuleCB; import org.codelibs.fess.es.exbhv.BoostDocumentRuleBhv; import org.codelibs.fess.es.exentity.BoostDocumentRule; -import org.codelibs.fess.pager.BoostDocumentRulePager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; +import org.dbflute.optional.OptionalEntity; public class BoostDocumentRuleService implements Serializable { @@ -50,7 +50,7 @@ public class BoostDocumentRuleService implements Serializable { }); // update pager - Beans.copy(boostDocumentRuleList, boostDocumentRulePager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(boostDocumentRuleList, boostDocumentRulePager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); boostDocumentRulePager.setPageNumberList(boostDocumentRuleList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -58,20 +58,11 @@ public class BoostDocumentRuleService implements Serializable { return boostDocumentRuleList; } - public BoostDocumentRule getBoostDocumentRule(final Map keys) { - final BoostDocumentRule boostDocumentRule = boostDocumentRuleBhv.selectEntity(cb -> { - cb.query().docMeta().setId_Equal(keys.get("id")); - setupEntityCondition(cb, keys); - }).orElse(null);//TODO - if (boostDocumentRule == null) { - // TODO exception? - return null; - } - - return boostDocumentRule; + public OptionalEntity getBoostDocumentRule(final String id) { + return boostDocumentRuleBhv.selectByPK(id); } - public void store(final BoostDocumentRule boostDocumentRule) throws CrudMessageException { + public void store(final BoostDocumentRule boostDocumentRule) { setupStoreCondition(boostDocumentRule); boostDocumentRuleBhv.insertOrUpdate(boostDocumentRule, op -> { @@ -80,7 +71,7 @@ public class BoostDocumentRuleService implements Serializable { } - public void delete(final BoostDocumentRule boostDocumentRule) throws CrudMessageException { + public void delete(final BoostDocumentRule boostDocumentRule) { setupDeleteCondition(boostDocumentRule); boostDocumentRuleBhv.delete(boostDocumentRule, op -> { diff --git a/src/main/java/org/codelibs/fess/service/CrawlingSessionService.java b/src/main/java/org/codelibs/fess/app/service/CrawlingSessionService.java similarity index 95% rename from src/main/java/org/codelibs/fess/service/CrawlingSessionService.java rename to src/main/java/org/codelibs/fess/app/service/CrawlingSessionService.java index 640d0a73f..f292a5815 100644 --- a/src/main/java/org/codelibs/fess/service/CrawlingSessionService.java +++ b/src/main/java/org/codelibs/fess/app/service/CrawlingSessionService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.IOException; import java.io.Reader; @@ -36,25 +36,24 @@ import javax.annotation.Resource; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.codelibs.core.CoreLibConstants; +import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.FessSystemException; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.CrawlingSessionPager; import org.codelibs.fess.es.cbean.CrawlingSessionCB; import org.codelibs.fess.es.exbhv.CrawlingSessionBhv; import org.codelibs.fess.es.exbhv.CrawlingSessionInfoBhv; import org.codelibs.fess.es.exentity.CrawlingSession; import org.codelibs.fess.es.exentity.CrawlingSessionInfo; -import org.codelibs.fess.pager.CrawlingSessionPager; +import org.codelibs.fess.exception.FessSystemException; import org.codelibs.fess.util.ComponentUtil; import org.dbflute.bhv.readable.EntityRowHandler; import org.dbflute.cbean.result.ListResultBean; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; -import jp.sf.orangesignal.csv.CsvConfig; -import jp.sf.orangesignal.csv.CsvReader; -import jp.sf.orangesignal.csv.CsvWriter; +import com.orangesignal.csv.CsvConfig; +import com.orangesignal.csv.CsvReader; +import com.orangesignal.csv.CsvWriter; public class CrawlingSessionService implements Serializable { @@ -80,7 +79,7 @@ public class CrawlingSessionService implements Serializable { }); // update pager - Beans.copy(crawlingSessionList, crawlingSessionPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(crawlingSessionList, crawlingSessionPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); crawlingSessionPager.setPageNumberList(crawlingSessionList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -101,14 +100,14 @@ public class CrawlingSessionService implements Serializable { return crawlingSession; } - public void store(final CrawlingSession crawlingSession) throws CrudMessageException { + public void store(final CrawlingSession crawlingSession) { setupStoreCondition(crawlingSession); crawlingSessionBhv.insertOrUpdate(crawlingSession); } - public void delete(final CrawlingSession crawlingSession) throws CrudMessageException { + public void delete(final CrawlingSession crawlingSession) { setupDeleteCondition(crawlingSession); crawlingSessionBhv.delete(crawlingSession); diff --git a/src/main/java/org/codelibs/fess/service/DataConfigService.java b/src/main/java/org/codelibs/fess/app/service/DataConfigService.java similarity index 96% rename from src/main/java/org/codelibs/fess/service/DataConfigService.java rename to src/main/java/org/codelibs/fess/app/service/DataConfigService.java index c011e3b1a..631fbaf0c 100644 --- a/src/main/java/org/codelibs/fess/service/DataConfigService.java +++ b/src/main/java/org/codelibs/fess/app/service/DataConfigService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.ArrayList; @@ -23,9 +23,9 @@ import java.util.Map; import javax.annotation.Resource; +import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.fess.app.pager.DataConfigPager; import org.codelibs.fess.es.cbean.DataConfigCB; import org.codelibs.fess.es.exbhv.DataConfigBhv; import org.codelibs.fess.es.exbhv.DataConfigToLabelBhv; @@ -33,9 +33,7 @@ import org.codelibs.fess.es.exbhv.DataConfigToRoleBhv; import org.codelibs.fess.es.exentity.DataConfig; import org.codelibs.fess.es.exentity.DataConfigToLabel; import org.codelibs.fess.es.exentity.DataConfigToRole; -import org.codelibs.fess.pager.DataConfigPager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class DataConfigService implements Serializable { @@ -63,7 +61,7 @@ public class DataConfigService implements Serializable { }); // update pager - Beans.copy(dataConfigList, dataConfigPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(dataConfigList, dataConfigPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); dataConfigPager.setPageNumberList(dataConfigList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -71,7 +69,7 @@ public class DataConfigService implements Serializable { return dataConfigList; } - public void delete(final DataConfig dataConfig) throws CrudMessageException { + public void delete(final DataConfig dataConfig) { setupDeleteCondition(dataConfig); dataConfigBhv.delete(dataConfig, op -> { diff --git a/src/main/java/org/codelibs/fess/service/FailureUrlService.java b/src/main/java/org/codelibs/fess/app/service/FailureUrlService.java similarity index 92% rename from src/main/java/org/codelibs/fess/service/FailureUrlService.java rename to src/main/java/org/codelibs/fess/app/service/FailureUrlService.java index 7eb15506e..3b7cd767e 100644 --- a/src/main/java/org/codelibs/fess/service/FailureUrlService.java +++ b/src/main/java/org/codelibs/fess/app/service/FailureUrlService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.PrintWriter; import java.io.Serializable; @@ -26,23 +26,21 @@ import java.util.regex.Pattern; import javax.annotation.Resource; -import org.apache.commons.lang.StringUtils; +import org.apache.commons.lang3.StringUtils; +import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.core.lang.StringUtil; import org.codelibs.core.misc.DynamicProperties; import org.codelibs.fess.Constants; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.fess.app.pager.FailureUrlPager; import org.codelibs.fess.es.cbean.FailureUrlCB; import org.codelibs.fess.es.exbhv.FailureUrlBhv; import org.codelibs.fess.es.exentity.CrawlingConfig; import org.codelibs.fess.es.exentity.FailureUrl; import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.FailureUrlPager; import org.codelibs.fess.util.ComponentUtil; import org.dbflute.cbean.result.ListResultBean; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.container.SingletonS2Container; +import org.lastaflute.di.core.SingletonLaContainer; public class FailureUrlService implements Serializable { @@ -66,7 +64,7 @@ public class FailureUrlService implements Serializable { }); // update pager - Beans.copy(failureUrlList, failureUrlPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(failureUrlList, failureUrlPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); failureUrlPager.setPageNumberList(failureUrlList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -87,7 +85,7 @@ public class FailureUrlService implements Serializable { return failureUrl; } - public void store(final FailureUrl failureUrl) throws CrudMessageException { + public void store(final FailureUrl failureUrl) { setupStoreCondition(failureUrl); failureUrlBhv.insertOrUpdate(failureUrl, op -> { @@ -96,7 +94,7 @@ public class FailureUrlService implements Serializable { } - public void delete(final FailureUrl failureUrl) throws CrudMessageException { + public void delete(final FailureUrl failureUrl) { setupDeleteCondition(failureUrl); failureUrlBhv.delete(failureUrl, op -> { @@ -209,7 +207,7 @@ public class FailureUrlService implements Serializable { } public void store(final CrawlingConfig crawlingConfig, final String errorName, final String url, final Throwable e) { - final FailureUrlBhv failureUrlBhv = SingletonS2Container.getComponent(FailureUrlBhv.class); + final FailureUrlBhv failureUrlBhv = SingletonLaContainer.getComponent(FailureUrlBhv.class); FailureUrl failureUrl = failureUrlBhv.selectEntity(cb -> { cb.query().setUrl_Equal(url); if (crawlingConfig != null) { diff --git a/src/main/java/org/codelibs/fess/service/FileAuthenticationService.java b/src/main/java/org/codelibs/fess/app/service/FileAuthenticationService.java similarity index 89% rename from src/main/java/org/codelibs/fess/service/FileAuthenticationService.java rename to src/main/java/org/codelibs/fess/app/service/FileAuthenticationService.java index 55574049c..9923c6f0d 100644 --- a/src/main/java/org/codelibs/fess/service/FileAuthenticationService.java +++ b/src/main/java/org/codelibs/fess/app/service/FileAuthenticationService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.List; @@ -22,14 +22,13 @@ import java.util.Map; import javax.annotation.Resource; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.FileAuthenticationPager; import org.codelibs.fess.es.cbean.FileAuthenticationCB; import org.codelibs.fess.es.exbhv.FileAuthenticationBhv; import org.codelibs.fess.es.exentity.FileAuthentication; -import org.codelibs.fess.pager.FileAuthenticationPager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class FileAuthenticationService implements Serializable { @@ -50,7 +49,7 @@ public class FileAuthenticationService implements Serializable { }); // update pager - Beans.copy(fileAuthenticationList, fileAuthenticationPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(fileAuthenticationList, fileAuthenticationPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); fileAuthenticationPager.setPageNumberList(fileAuthenticationList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -71,7 +70,7 @@ public class FileAuthenticationService implements Serializable { return fileAuthentication; } - public void store(final FileAuthentication fileAuthentication) throws CrudMessageException { + public void store(final FileAuthentication fileAuthentication) { setupStoreCondition(fileAuthentication); fileAuthenticationBhv.insertOrUpdate(fileAuthentication, op -> { @@ -80,7 +79,7 @@ public class FileAuthenticationService implements Serializable { } - public void delete(final FileAuthentication fileAuthentication) throws CrudMessageException { + public void delete(final FileAuthentication fileAuthentication) { setupDeleteCondition(fileAuthentication); fileAuthenticationBhv.delete(fileAuthentication, op -> { diff --git a/src/main/java/org/codelibs/fess/service/FileConfigService.java b/src/main/java/org/codelibs/fess/app/service/FileConfigService.java similarity index 96% rename from src/main/java/org/codelibs/fess/service/FileConfigService.java rename to src/main/java/org/codelibs/fess/app/service/FileConfigService.java index 0f9902f54..f444d002d 100644 --- a/src/main/java/org/codelibs/fess/service/FileConfigService.java +++ b/src/main/java/org/codelibs/fess/app/service/FileConfigService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.ArrayList; @@ -23,9 +23,9 @@ import java.util.Map; import javax.annotation.Resource; +import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.fess.app.pager.FileConfigPager; import org.codelibs.fess.es.cbean.FileConfigCB; import org.codelibs.fess.es.exbhv.FileConfigBhv; import org.codelibs.fess.es.exbhv.FileConfigToLabelBhv; @@ -33,9 +33,7 @@ import org.codelibs.fess.es.exbhv.FileConfigToRoleBhv; import org.codelibs.fess.es.exentity.FileConfig; import org.codelibs.fess.es.exentity.FileConfigToLabel; import org.codelibs.fess.es.exentity.FileConfigToRole; -import org.codelibs.fess.pager.FileConfigPager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class FileConfigService implements Serializable { @@ -62,7 +60,7 @@ public class FileConfigService implements Serializable { }); // update pager - Beans.copy(fileConfigList, fileConfigPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(fileConfigList, fileConfigPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); fileConfigPager.setPageNumberList(fileConfigList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -70,7 +68,7 @@ public class FileConfigService implements Serializable { return fileConfigList; } - public void delete(final FileConfig fileConfig) throws CrudMessageException { + public void delete(final FileConfig fileConfig) { setupDeleteCondition(fileConfig); fileConfigBhv.delete(fileConfig, op -> { diff --git a/src/main/java/org/codelibs/fess/app/service/GroupService.java b/src/main/java/org/codelibs/fess/app/service/GroupService.java new file mode 100644 index 000000000..3cc147ff0 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/service/GroupService.java @@ -0,0 +1,124 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.service; + +import java.io.Serializable; +import java.util.List; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.GroupPager; +import org.codelibs.fess.es.cbean.GroupCB; +import org.codelibs.fess.es.exbhv.GroupBhv; +import org.codelibs.fess.es.exentity.Group; +import org.dbflute.cbean.result.PagingResultBean; + +public class GroupService implements Serializable { + + private static final long serialVersionUID = 1L; + + @Resource + protected GroupBhv groupBhv; + + public List getGroupList(final GroupPager groupPager) { + + final PagingResultBean groupList = groupBhv.selectPage(cb -> { + cb.paging(groupPager.getPageSize(), groupPager.getCurrentPageNumber()); + setupListCondition(cb, groupPager); + }); + + // update pager + BeanUtil.copyBeanToBean(groupList, groupPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); + groupPager.setPageNumberList(groupList.pageRange(op -> { + op.rangeSize(5); + }).createPageNumberList()); + + return groupList; + } + + public Group getGroup(final Map keys) { + final Group group = groupBhv.selectEntity(cb -> { + cb.query().docMeta().setId_Equal(keys.get("id")); + setupEntityCondition(cb, keys); + }).orElse(null);//TODO + if (group == null) { + // TODO exception? + return null; + } + + return group; + } + + public void store(final Group group) { + setupStoreCondition(group); + + groupBhv.insertOrUpdate(group, op -> { + op.setRefresh(true); + }); + + } + + public void delete(final Group group) { + setupDeleteCondition(group); + + groupBhv.delete(group, op -> { + op.setRefresh(true); + }); + + } + + protected void setupListCondition(final GroupCB cb, final GroupPager groupPager) { + if (groupPager.id != null) { + cb.query().docMeta().setId_Equal(groupPager.id); + } + // TODO Long, Integer, String supported only. + + // setup condition + cb.query().addOrderBy_Name_Asc(); + + // search + + } + + protected void setupEntityCondition(final GroupCB cb, final Map keys) { + + // setup condition + + } + + protected void setupStoreCondition(final Group group) { + + // setup condition + + } + + protected void setupDeleteCondition(final Group group) { + + // setup condition + + } + + public List getAvailableGroupList() { + return groupBhv.selectList(cb -> { + cb.query().matchAll(); + }); + } + +} diff --git a/src/main/java/org/codelibs/fess/service/JobLogService.java b/src/main/java/org/codelibs/fess/app/service/JobLogService.java similarity index 88% rename from src/main/java/org/codelibs/fess/service/JobLogService.java rename to src/main/java/org/codelibs/fess/app/service/JobLogService.java index 171c4ea2e..34711a88f 100644 --- a/src/main/java/org/codelibs/fess/service/JobLogService.java +++ b/src/main/java/org/codelibs/fess/app/service/JobLogService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.List; @@ -22,15 +22,14 @@ import java.util.Map; import javax.annotation.Resource; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.JobLogPager; import org.codelibs.fess.es.cbean.JobLogCB; import org.codelibs.fess.es.exbhv.JobLogBhv; import org.codelibs.fess.es.exentity.JobLog; -import org.codelibs.fess.pager.JobLogPager; import org.codelibs.fess.util.ComponentUtil; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class JobLogService implements Serializable { @@ -51,7 +50,7 @@ public class JobLogService implements Serializable { }); // update pager - Beans.copy(jobLogList, jobLogPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(jobLogList, jobLogPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); jobLogPager.setPageNumberList(jobLogList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -72,7 +71,7 @@ public class JobLogService implements Serializable { return jobLog; } - public void store(final JobLog jobLog) throws CrudMessageException { + public void store(final JobLog jobLog) { setupStoreCondition(jobLog); jobLogBhv.insertOrUpdate(jobLog, op -> { @@ -81,7 +80,7 @@ public class JobLogService implements Serializable { } - public void delete(final JobLog jobLog) throws CrudMessageException { + public void delete(final JobLog jobLog) { setupDeleteCondition(jobLog); jobLogBhv.delete(jobLog, op -> { diff --git a/src/main/java/org/codelibs/fess/service/KeyMatchService.java b/src/main/java/org/codelibs/fess/app/service/KeyMatchService.java similarity index 86% rename from src/main/java/org/codelibs/fess/service/KeyMatchService.java rename to src/main/java/org/codelibs/fess/app/service/KeyMatchService.java index f29414404..da0d4c032 100644 --- a/src/main/java/org/codelibs/fess/service/KeyMatchService.java +++ b/src/main/java/org/codelibs/fess/app/service/KeyMatchService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.List; @@ -22,14 +22,13 @@ import java.util.Map; import javax.annotation.Resource; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.KeyMatchPager; import org.codelibs.fess.es.cbean.KeyMatchCB; import org.codelibs.fess.es.exbhv.KeyMatchBhv; import org.codelibs.fess.es.exentity.KeyMatch; -import org.codelibs.fess.pager.KeyMatchPager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class KeyMatchService implements Serializable { @@ -50,7 +49,7 @@ public class KeyMatchService implements Serializable { }); // update pager - Beans.copy(keyMatchList, keyMatchPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(keyMatchList, keyMatchPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); keyMatchPager.setPageNumberList(keyMatchList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -71,7 +70,7 @@ public class KeyMatchService implements Serializable { return keyMatch; } - public void store(final KeyMatch keyMatch) throws CrudMessageException { + public void store(final KeyMatch keyMatch) { setupStoreCondition(keyMatch); keyMatchBhv.insertOrUpdate(keyMatch, op -> { @@ -80,7 +79,7 @@ public class KeyMatchService implements Serializable { } - public void delete(final KeyMatch keyMatch) throws CrudMessageException { + public void delete(final KeyMatch keyMatch) { setupDeleteCondition(keyMatch); keyMatchBhv.delete(keyMatch, op -> { diff --git a/src/main/java/org/codelibs/fess/service/LabelTypeService.java b/src/main/java/org/codelibs/fess/app/service/LabelTypeService.java similarity index 94% rename from src/main/java/org/codelibs/fess/service/LabelTypeService.java rename to src/main/java/org/codelibs/fess/app/service/LabelTypeService.java index ee8c9f8e3..a15ce09d8 100644 --- a/src/main/java/org/codelibs/fess/service/LabelTypeService.java +++ b/src/main/java/org/codelibs/fess/app/service/LabelTypeService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.ArrayList; @@ -23,19 +23,18 @@ import java.util.Map; import javax.annotation.Resource; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.LabelTypePager; import org.codelibs.fess.es.cbean.LabelTypeCB; import org.codelibs.fess.es.exbhv.LabelToRoleBhv; import org.codelibs.fess.es.exbhv.LabelTypeBhv; import org.codelibs.fess.es.exentity.LabelToRole; import org.codelibs.fess.es.exentity.LabelType; import org.codelibs.fess.helper.LabelTypeHelper; -import org.codelibs.fess.pager.LabelTypePager; import org.codelibs.fess.util.ComponentUtil; import org.dbflute.cbean.result.ListResultBean; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class LabelTypeService implements Serializable { @@ -59,7 +58,7 @@ public class LabelTypeService implements Serializable { }); // update pager - Beans.copy(labelTypeList, labelTypePager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(labelTypeList, labelTypePager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); labelTypePager.setPageNumberList(labelTypeList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -67,7 +66,7 @@ public class LabelTypeService implements Serializable { return labelTypeList; } - public void delete(final LabelType labelType) throws CrudMessageException { + public void delete(final LabelType labelType) { setupDeleteCondition(labelType); labelTypeBhv.delete(labelType, op -> { diff --git a/src/main/java/org/codelibs/fess/service/OverlappingHostService.java b/src/main/java/org/codelibs/fess/app/service/OverlappingHostService.java similarity index 87% rename from src/main/java/org/codelibs/fess/service/OverlappingHostService.java rename to src/main/java/org/codelibs/fess/app/service/OverlappingHostService.java index 8f079dfbd..ede4a0063 100644 --- a/src/main/java/org/codelibs/fess/service/OverlappingHostService.java +++ b/src/main/java/org/codelibs/fess/app/service/OverlappingHostService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.List; @@ -22,14 +22,13 @@ import java.util.Map; import javax.annotation.Resource; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.OverlappingHostPager; import org.codelibs.fess.es.cbean.OverlappingHostCB; import org.codelibs.fess.es.exbhv.OverlappingHostBhv; import org.codelibs.fess.es.exentity.OverlappingHost; -import org.codelibs.fess.pager.OverlappingHostPager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class OverlappingHostService implements Serializable { @@ -50,7 +49,7 @@ public class OverlappingHostService implements Serializable { }); // update pager - Beans.copy(overlappingHostList, overlappingHostPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(overlappingHostList, overlappingHostPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); overlappingHostPager.setPageNumberList(overlappingHostList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -71,7 +70,7 @@ public class OverlappingHostService implements Serializable { return overlappingHost; } - public void store(final OverlappingHost overlappingHost) throws CrudMessageException { + public void store(final OverlappingHost overlappingHost) { setupStoreCondition(overlappingHost); overlappingHostBhv.insertOrUpdate(overlappingHost, op -> { @@ -80,7 +79,7 @@ public class OverlappingHostService implements Serializable { } - public void delete(final OverlappingHost overlappingHost) throws CrudMessageException { + public void delete(final OverlappingHost overlappingHost) { setupDeleteCondition(overlappingHost); overlappingHostBhv.delete(overlappingHost, op -> { diff --git a/src/main/java/org/codelibs/fess/service/PathMappingService.java b/src/main/java/org/codelibs/fess/app/service/PathMappingService.java similarity index 87% rename from src/main/java/org/codelibs/fess/service/PathMappingService.java rename to src/main/java/org/codelibs/fess/app/service/PathMappingService.java index 399baf8bf..3e810c2bd 100644 --- a/src/main/java/org/codelibs/fess/service/PathMappingService.java +++ b/src/main/java/org/codelibs/fess/app/service/PathMappingService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.Collection; @@ -23,14 +23,13 @@ import java.util.Map; import javax.annotation.Resource; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.PathMappingPager; import org.codelibs.fess.es.cbean.PathMappingCB; import org.codelibs.fess.es.exbhv.PathMappingBhv; import org.codelibs.fess.es.exentity.PathMapping; -import org.codelibs.fess.pager.PathMappingPager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class PathMappingService implements Serializable { @@ -47,7 +46,7 @@ public class PathMappingService implements Serializable { }); // update pager - Beans.copy(pathMappingList, pathMappingPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(pathMappingList, pathMappingPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); pathMappingPager.setPageNumberList(pathMappingList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -69,7 +68,7 @@ public class PathMappingService implements Serializable { return pathMapping; } - public void store(final PathMapping pathMapping) throws CrudMessageException { + public void store(final PathMapping pathMapping) { setupStoreCondition(pathMapping); pathMappingBhv.insertOrUpdate(pathMapping, op -> { @@ -78,7 +77,7 @@ public class PathMappingService implements Serializable { } - public void delete(final PathMapping pathMapping) throws CrudMessageException { + public void delete(final PathMapping pathMapping) { setupDeleteCondition(pathMapping); pathMappingBhv.delete(pathMapping, op -> { diff --git a/src/main/java/org/codelibs/fess/service/RequestHeaderService.java b/src/main/java/org/codelibs/fess/app/service/RequestHeaderService.java similarity index 86% rename from src/main/java/org/codelibs/fess/service/RequestHeaderService.java rename to src/main/java/org/codelibs/fess/app/service/RequestHeaderService.java index e956d19f3..4ea8ce523 100644 --- a/src/main/java/org/codelibs/fess/service/RequestHeaderService.java +++ b/src/main/java/org/codelibs/fess/app/service/RequestHeaderService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.List; @@ -22,14 +22,13 @@ import java.util.Map; import javax.annotation.Resource; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.RequestHeaderPager; import org.codelibs.fess.es.cbean.RequestHeaderCB; import org.codelibs.fess.es.exbhv.RequestHeaderBhv; import org.codelibs.fess.es.exentity.RequestHeader; -import org.codelibs.fess.pager.RequestHeaderPager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class RequestHeaderService implements Serializable { @@ -50,7 +49,7 @@ public class RequestHeaderService implements Serializable { }); // update pager - Beans.copy(requestHeaderList, requestHeaderPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(requestHeaderList, requestHeaderPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); requestHeaderPager.setPageNumberList(requestHeaderList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -71,7 +70,7 @@ public class RequestHeaderService implements Serializable { return requestHeader; } - public void store(final RequestHeader requestHeader) throws CrudMessageException { + public void store(final RequestHeader requestHeader) { setupStoreCondition(requestHeader); requestHeaderBhv.insertOrUpdate(requestHeader, op -> { @@ -80,7 +79,7 @@ public class RequestHeaderService implements Serializable { } - public void delete(final RequestHeader requestHeader) throws CrudMessageException { + public void delete(final RequestHeader requestHeader) { setupDeleteCondition(requestHeader); requestHeaderBhv.delete(requestHeader, op -> { diff --git a/src/main/java/org/codelibs/fess/app/service/RoleService.java b/src/main/java/org/codelibs/fess/app/service/RoleService.java new file mode 100644 index 000000000..4547578ae --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/service/RoleService.java @@ -0,0 +1,124 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.service; + +import java.io.Serializable; +import java.util.List; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.RolePager; +import org.codelibs.fess.es.cbean.RoleCB; +import org.codelibs.fess.es.exbhv.RoleBhv; +import org.codelibs.fess.es.exentity.Role; +import org.dbflute.cbean.result.PagingResultBean; + +public class RoleService implements Serializable { + + private static final long serialVersionUID = 1L; + + @Resource + protected RoleBhv roleBhv; + + public List getRoleList(final RolePager rolePager) { + + final PagingResultBean roleList = roleBhv.selectPage(cb -> { + cb.paging(rolePager.getPageSize(), rolePager.getCurrentPageNumber()); + setupListCondition(cb, rolePager); + }); + + // update pager + BeanUtil.copyBeanToBean(roleList, rolePager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); + rolePager.setPageNumberList(roleList.pageRange(op -> { + op.rangeSize(5); + }).createPageNumberList()); + + return roleList; + } + + public Role getRole(final Map keys) { + final Role role = roleBhv.selectEntity(cb -> { + cb.query().docMeta().setId_Equal(keys.get("id")); + setupEntityCondition(cb, keys); + }).orElse(null);//TODO + if (role == null) { + // TODO exception? + return null; + } + + return role; + } + + public void store(final Role role) { + setupStoreCondition(role); + + roleBhv.insertOrUpdate(role, op -> { + op.setRefresh(true); + }); + + } + + public void delete(final Role role) { + setupDeleteCondition(role); + + roleBhv.delete(role, op -> { + op.setRefresh(true); + }); + + } + + protected void setupListCondition(final RoleCB cb, final RolePager rolePager) { + if (rolePager.id != null) { + cb.query().docMeta().setId_Equal(rolePager.id); + } + // TODO Long, Integer, String supported only. + + // setup condition + cb.query().addOrderBy_Name_Asc(); + + // search + + } + + protected void setupEntityCondition(final RoleCB cb, final Map keys) { + + // setup condition + + } + + protected void setupStoreCondition(final Role role) { + + // setup condition + + } + + protected void setupDeleteCondition(final Role role) { + + // setup condition + + } + + public List getAvailableRoleList() { + return roleBhv.selectList(cb -> { + cb.query().matchAll(); + }); + } + +} diff --git a/src/main/java/org/codelibs/fess/service/RoleTypeService.java b/src/main/java/org/codelibs/fess/app/service/RoleTypeService.java similarity index 87% rename from src/main/java/org/codelibs/fess/service/RoleTypeService.java rename to src/main/java/org/codelibs/fess/app/service/RoleTypeService.java index 1a5d84b8f..a3e752cfb 100644 --- a/src/main/java/org/codelibs/fess/service/RoleTypeService.java +++ b/src/main/java/org/codelibs/fess/app/service/RoleTypeService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.List; @@ -22,14 +22,13 @@ import java.util.Map; import javax.annotation.Resource; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.RoleTypePager; import org.codelibs.fess.es.cbean.RoleTypeCB; import org.codelibs.fess.es.exbhv.RoleTypeBhv; import org.codelibs.fess.es.exentity.RoleType; -import org.codelibs.fess.pager.RoleTypePager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class RoleTypeService implements Serializable { @@ -50,7 +49,7 @@ public class RoleTypeService implements Serializable { }); // update pager - Beans.copy(roleTypeList, roleTypePager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(roleTypeList, roleTypePager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); roleTypePager.setPageNumberList(roleTypeList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -71,7 +70,7 @@ public class RoleTypeService implements Serializable { return roleType; } - public void store(final RoleType roleType) throws CrudMessageException { + public void store(final RoleType roleType) { setupStoreCondition(roleType); roleTypeBhv.insertOrUpdate(roleType, op -> { @@ -80,7 +79,7 @@ public class RoleTypeService implements Serializable { } - public void delete(final RoleType roleType) throws CrudMessageException { + public void delete(final RoleType roleType) { setupDeleteCondition(roleType); roleTypeBhv.delete(roleType, op -> { diff --git a/src/main/java/org/codelibs/fess/service/ScheduledJobService.java b/src/main/java/org/codelibs/fess/app/service/ScheduledJobService.java similarity index 89% rename from src/main/java/org/codelibs/fess/service/ScheduledJobService.java rename to src/main/java/org/codelibs/fess/app/service/ScheduledJobService.java index 396658fdc..226ffaa68 100644 --- a/src/main/java/org/codelibs/fess/service/ScheduledJobService.java +++ b/src/main/java/org/codelibs/fess/app/service/ScheduledJobService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.List; @@ -22,16 +22,14 @@ import java.util.Map; import javax.annotation.Resource; +import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.fess.app.pager.ScheduledJobPager; import org.codelibs.fess.es.cbean.ScheduledJobCB; import org.codelibs.fess.es.exbhv.ScheduledJobBhv; import org.codelibs.fess.es.exentity.ScheduledJob; import org.codelibs.fess.job.JobScheduler; -import org.codelibs.fess.pager.ScheduledJobPager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class ScheduledJobService implements Serializable { @@ -52,7 +50,7 @@ public class ScheduledJobService implements Serializable { }); // update pager - Beans.copy(scheduledJobList, scheduledJobPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(scheduledJobList, scheduledJobPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); scheduledJobPager.setPageNumberList(scheduledJobList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -73,7 +71,7 @@ public class ScheduledJobService implements Serializable { return scheduledJob; } - public void delete(final ScheduledJob scheduledJob) throws CrudMessageException { + public void delete(final ScheduledJob scheduledJob) { setupDeleteCondition(scheduledJob); scheduledJobBhv.delete(scheduledJob, op -> { @@ -137,7 +135,7 @@ public class ScheduledJobService implements Serializable { jobScheduler.register(scheduledJob); } - public List getCrawloerJobList() { + public List getCrawlerJobList() { return scheduledJobBhv.selectList(cb -> { cb.query().setCrawler_Equal(Constants.T); cb.query().addOrderBy_SortOrder_Asc(); diff --git a/src/main/java/org/codelibs/fess/service/SuggestBadWordService.java b/src/main/java/org/codelibs/fess/app/service/SuggestBadWordService.java similarity index 90% rename from src/main/java/org/codelibs/fess/service/SuggestBadWordService.java rename to src/main/java/org/codelibs/fess/app/service/SuggestBadWordService.java index 41002fc5b..871bc3747 100644 --- a/src/main/java/org/codelibs/fess/service/SuggestBadWordService.java +++ b/src/main/java/org/codelibs/fess/app/service/SuggestBadWordService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.IOException; import java.io.Reader; @@ -28,21 +28,20 @@ import javax.annotation.Resource; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; +import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.SuggestBadWordPager; import org.codelibs.fess.es.cbean.SuggestBadWordCB; import org.codelibs.fess.es.exbhv.SuggestBadWordBhv; import org.codelibs.fess.es.exentity.SuggestBadWord; -import org.codelibs.fess.pager.SuggestBadWordPager; import org.codelibs.fess.util.ComponentUtil; import org.dbflute.bhv.readable.EntityRowHandler; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; -import jp.sf.orangesignal.csv.CsvConfig; -import jp.sf.orangesignal.csv.CsvReader; -import jp.sf.orangesignal.csv.CsvWriter; +import com.orangesignal.csv.CsvConfig; +import com.orangesignal.csv.CsvReader; +import com.orangesignal.csv.CsvWriter; public class SuggestBadWordService implements Serializable { @@ -67,7 +66,7 @@ public class SuggestBadWordService implements Serializable { }); // update pager - Beans.copy(suggestBadWordList, suggestBadWordPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(suggestBadWordList, suggestBadWordPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); suggestBadWordPager.setPageNumberList(suggestBadWordList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -88,17 +87,21 @@ public class SuggestBadWordService implements Serializable { return suggestBadWord; } - public void store(final SuggestBadWord suggestBadWord) throws CrudMessageException { + public void store(final SuggestBadWord suggestBadWord) { setupStoreCondition(suggestBadWord); - suggestBadWordBhv.insertOrUpdate(suggestBadWord); + suggestBadWordBhv.insertOrUpdate(suggestBadWord, op -> { + op.setRefresh(true); + }); } - public void delete(final SuggestBadWord suggestBadWord) throws CrudMessageException { + public void delete(final SuggestBadWord suggestBadWord) { setupDeleteCondition(suggestBadWord); - suggestBadWordBhv.delete(suggestBadWord); + suggestBadWordBhv.delete(suggestBadWord, op -> { + op.setRefresh(true); + }); } diff --git a/src/main/java/org/codelibs/fess/service/SuggestElevateWordService.java b/src/main/java/org/codelibs/fess/app/service/SuggestElevateWordService.java similarity index 93% rename from src/main/java/org/codelibs/fess/service/SuggestElevateWordService.java rename to src/main/java/org/codelibs/fess/app/service/SuggestElevateWordService.java index bdede1e77..a3cb2c44c 100644 --- a/src/main/java/org/codelibs/fess/service/SuggestElevateWordService.java +++ b/src/main/java/org/codelibs/fess/app/service/SuggestElevateWordService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.IOException; import java.io.Reader; @@ -28,21 +28,20 @@ import javax.annotation.Resource; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; +import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.SuggestElevateWordPager; import org.codelibs.fess.es.cbean.SuggestElevateWordCB; import org.codelibs.fess.es.exbhv.SuggestElevateWordBhv; import org.codelibs.fess.es.exentity.SuggestElevateWord; -import org.codelibs.fess.pager.SuggestElevateWordPager; import org.codelibs.fess.util.ComponentUtil; import org.dbflute.bhv.readable.EntityRowHandler; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; -import jp.sf.orangesignal.csv.CsvConfig; -import jp.sf.orangesignal.csv.CsvReader; -import jp.sf.orangesignal.csv.CsvWriter; +import com.orangesignal.csv.CsvConfig; +import com.orangesignal.csv.CsvReader; +import com.orangesignal.csv.CsvWriter; public class SuggestElevateWordService implements Serializable { @@ -65,7 +64,7 @@ public class SuggestElevateWordService implements Serializable { }); // update pager - Beans.copy(suggestElevateWordList, suggestElevateWordPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(suggestElevateWordList, suggestElevateWordPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); suggestElevateWordPager.setPageNumberList(suggestElevateWordList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -86,17 +85,21 @@ public class SuggestElevateWordService implements Serializable { return suggestElevateWord; } - public void store(final SuggestElevateWord suggestElevateWord) throws CrudMessageException { + public void store(final SuggestElevateWord suggestElevateWord) { setupStoreCondition(suggestElevateWord); - suggestElevateWordBhv.insertOrUpdate(suggestElevateWord); + suggestElevateWordBhv.insertOrUpdate(suggestElevateWord, op -> { + op.setRefresh(true); + }); } - public void delete(final SuggestElevateWord suggestElevateWord) throws CrudMessageException { + public void delete(final SuggestElevateWord suggestElevateWord) { setupDeleteCondition(suggestElevateWord); - suggestElevateWordBhv.delete(suggestElevateWord); + suggestElevateWordBhv.delete(suggestElevateWord, op -> { + op.setRefresh(true); + }); } diff --git a/src/main/java/org/codelibs/fess/service/SynonymService.java b/src/main/java/org/codelibs/fess/app/service/SynonymService.java similarity index 91% rename from src/main/java/org/codelibs/fess/service/SynonymService.java rename to src/main/java/org/codelibs/fess/app/service/SynonymService.java index a64d11460..ddfd31438 100644 --- a/src/main/java/org/codelibs/fess/service/SynonymService.java +++ b/src/main/java/org/codelibs/fess/app/service/SynonymService.java @@ -14,23 +14,23 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.util.List; import java.util.Map; import javax.annotation.Resource; +import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.crud.CommonConstants; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.SynonymPager; import org.codelibs.fess.dict.DictionaryExpiredException; import org.codelibs.fess.dict.DictionaryFile; import org.codelibs.fess.dict.DictionaryFile.PagingList; import org.codelibs.fess.dict.DictionaryManager; import org.codelibs.fess.dict.synonym.SynonymFile; import org.codelibs.fess.dict.synonym.SynonymItem; -import org.codelibs.fess.pager.SynonymPager; -import org.seasar.framework.beans.util.Beans; public class SynonymService { @Resource @@ -43,7 +43,7 @@ public class SynonymService { final PagingList synonymList = synonymFile.selectList((synonymPager.getCurrentPageNumber() - 1) * pageSize, pageSize); // update pager - Beans.copy(synonymList, synonymPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(synonymList, synonymPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); synonymList.setPageRangeSize(5); synonymPager.setPageNumberList(synonymList.createPageNumberList()); diff --git a/src/main/java/org/codelibs/fess/service/UserDictService.java b/src/main/java/org/codelibs/fess/app/service/UserDictService.java similarity index 91% rename from src/main/java/org/codelibs/fess/service/UserDictService.java rename to src/main/java/org/codelibs/fess/app/service/UserDictService.java index 3b98deeb8..4e26cff99 100644 --- a/src/main/java/org/codelibs/fess/service/UserDictService.java +++ b/src/main/java/org/codelibs/fess/app/service/UserDictService.java @@ -14,23 +14,23 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.util.List; import java.util.Map; import javax.annotation.Resource; +import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.crud.CommonConstants; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.UserDictPager; import org.codelibs.fess.dict.DictionaryExpiredException; import org.codelibs.fess.dict.DictionaryFile; import org.codelibs.fess.dict.DictionaryFile.PagingList; import org.codelibs.fess.dict.DictionaryManager; import org.codelibs.fess.dict.userdict.UserDictFile; import org.codelibs.fess.dict.userdict.UserDictItem; -import org.codelibs.fess.pager.UserDictPager; -import org.seasar.framework.beans.util.Beans; public class UserDictService { @Resource @@ -44,7 +44,7 @@ public class UserDictService { userDictFile.selectList((userDictPager.getCurrentPageNumber() - 1) * pageSize, pageSize); // update pager - Beans.copy(userDictList, userDictPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(userDictList, userDictPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); userDictList.setPageRangeSize(5); userDictPager.setPageNumberList(userDictList.createPageNumberList()); diff --git a/src/main/java/org/codelibs/fess/app/service/UserService.java b/src/main/java/org/codelibs/fess/app/service/UserService.java new file mode 100644 index 000000000..6a0ebed6a --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/service/UserService.java @@ -0,0 +1,128 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.service; + +import java.io.Serializable; +import java.util.List; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.UserPager; +import org.codelibs.fess.es.cbean.UserCB; +import org.codelibs.fess.es.exbhv.UserBhv; +import org.codelibs.fess.es.exentity.User; +import org.dbflute.cbean.result.PagingResultBean; + +public class UserService implements Serializable { + + private static final long serialVersionUID = 1L; + + @Resource + protected UserBhv userBhv; + + public UserService() { + super(); + } + + public List getUserList(final UserPager userPager) { + + final PagingResultBean userList = userBhv.selectPage(cb -> { + cb.paging(userPager.getPageSize(), userPager.getCurrentPageNumber()); + setupListCondition(cb, userPager); + }); + + // update pager + BeanUtil.copyBeanToBean(userList, userPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); + userPager.setPageNumberList(userList.pageRange(op -> { + op.rangeSize(5); + }).createPageNumberList()); + + return userList; + } + + public User getUser(final Map keys) { + final User user = userBhv.selectEntity(cb -> { + cb.query().docMeta().setId_Equal(keys.get("id")); + setupEntityCondition(cb, keys); + }).orElse(null);//TODO + if (user == null) { + // TODO exception? + return null; + } + + return user; + } + + public void store(final User user) { + setupStoreCondition(user); + + userBhv.insertOrUpdate(user, op -> { + op.setRefresh(true); + }); + + } + + public void delete(final User user) { + setupDeleteCondition(user); + + userBhv.delete(user, op -> { + op.setRefresh(true); + }); + + } + + protected void setupListCondition(final UserCB cb, final UserPager userPager) { + if (userPager.id != null) { + cb.query().docMeta().setId_Equal(userPager.id); + } + // TODO Long, Integer, String supported only. + + // setup condition + cb.query().addOrderBy_Name_Asc(); + + // search + + } + + protected void setupEntityCondition(final UserCB cb, final Map keys) { + + // setup condition + + } + + protected void setupStoreCondition(final User user) { + + // setup condition + + } + + protected void setupDeleteCondition(final User user) { + + // setup condition + + } + + public List getAvailableUserList() { + return userBhv.selectList(cb -> { + cb.query().matchAll(); + }); + } + +} diff --git a/src/main/java/org/codelibs/fess/service/WebAuthenticationService.java b/src/main/java/org/codelibs/fess/app/service/WebAuthenticationService.java similarity index 90% rename from src/main/java/org/codelibs/fess/service/WebAuthenticationService.java rename to src/main/java/org/codelibs/fess/app/service/WebAuthenticationService.java index 7375931b0..4dd494e4c 100644 --- a/src/main/java/org/codelibs/fess/service/WebAuthenticationService.java +++ b/src/main/java/org/codelibs/fess/app/service/WebAuthenticationService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.List; @@ -22,14 +22,13 @@ import java.util.Map; import javax.annotation.Resource; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.WebAuthenticationPager; import org.codelibs.fess.es.cbean.WebAuthenticationCB; import org.codelibs.fess.es.exbhv.WebAuthenticationBhv; import org.codelibs.fess.es.exentity.WebAuthentication; -import org.codelibs.fess.pager.WebAuthenticationPager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class WebAuthenticationService implements Serializable { @@ -50,7 +49,7 @@ public class WebAuthenticationService implements Serializable { }); // update pager - Beans.copy(webAuthenticationList, webAuthenticationPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(webAuthenticationList, webAuthenticationPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); webAuthenticationPager.setPageNumberList(webAuthenticationList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -71,7 +70,7 @@ public class WebAuthenticationService implements Serializable { return webAuthentication; } - public void store(final WebAuthentication webAuthentication) throws CrudMessageException { + public void store(final WebAuthentication webAuthentication) { setupStoreCondition(webAuthentication); webAuthenticationBhv.insertOrUpdate(webAuthentication, op -> { @@ -80,7 +79,7 @@ public class WebAuthenticationService implements Serializable { } - public void delete(final WebAuthentication webAuthentication) throws CrudMessageException { + public void delete(final WebAuthentication webAuthentication) { setupDeleteCondition(webAuthentication); webAuthenticationBhv.delete(webAuthentication, op -> { diff --git a/src/main/java/org/codelibs/fess/service/WebConfigService.java b/src/main/java/org/codelibs/fess/app/service/WebConfigService.java similarity index 96% rename from src/main/java/org/codelibs/fess/service/WebConfigService.java rename to src/main/java/org/codelibs/fess/app/service/WebConfigService.java index 737d5caca..62dab61c6 100644 --- a/src/main/java/org/codelibs/fess/service/WebConfigService.java +++ b/src/main/java/org/codelibs/fess/app/service/WebConfigService.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.service; +package org.codelibs.fess.app.service; import java.io.Serializable; import java.util.ArrayList; @@ -23,9 +23,9 @@ import java.util.Map; import javax.annotation.Resource; +import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; +import org.codelibs.fess.app.pager.WebConfigPager; import org.codelibs.fess.es.cbean.WebConfigCB; import org.codelibs.fess.es.exbhv.WebConfigBhv; import org.codelibs.fess.es.exbhv.WebConfigToLabelBhv; @@ -33,9 +33,7 @@ import org.codelibs.fess.es.exbhv.WebConfigToRoleBhv; import org.codelibs.fess.es.exentity.WebConfig; import org.codelibs.fess.es.exentity.WebConfigToLabel; import org.codelibs.fess.es.exentity.WebConfigToRole; -import org.codelibs.fess.pager.WebConfigPager; import org.dbflute.cbean.result.PagingResultBean; -import org.seasar.framework.beans.util.Beans; public class WebConfigService implements Serializable { @@ -62,7 +60,7 @@ public class WebConfigService implements Serializable { }); // update pager - Beans.copy(webConfigList, webConfigPager).includes(CommonConstants.PAGER_CONVERSION_RULE).execute(); + BeanUtil.copyBeanToBean(webConfigList, webConfigPager, option -> option.include(Constants.PAGER_CONVERSION_RULE)); webConfigPager.setPageNumberList(webConfigList.pageRange(op -> { op.rangeSize(5); }).createPageNumberList()); @@ -70,7 +68,7 @@ public class WebConfigService implements Serializable { return webConfigList; } - public void delete(final WebConfig webConfig) throws CrudMessageException { + public void delete(final WebConfig webConfig) { setupDeleteCondition(webConfig); webConfigBhv.delete(webConfig, op -> { diff --git a/src/main/java/org/codelibs/fess/helper/impl/EmptyDatabaseHelperImpl.java b/src/main/java/org/codelibs/fess/app/web/CrudMode.java similarity index 69% rename from src/main/java/org/codelibs/fess/helper/impl/EmptyDatabaseHelperImpl.java rename to src/main/java/org/codelibs/fess/app/web/CrudMode.java index f3e498cec..dfd7bc466 100644 --- a/src/main/java/org/codelibs/fess/helper/impl/EmptyDatabaseHelperImpl.java +++ b/src/main/java/org/codelibs/fess/app/web/CrudMode.java @@ -14,15 +14,20 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.helper.impl; +package org.codelibs.fess.app.web; -import org.codelibs.fess.helper.DatabaseHelper; +public class CrudMode { + public static final int LIST = 0; -public class EmptyDatabaseHelperImpl implements DatabaseHelper { + public static final int CREATE = 1; - @Override - public void optimize() { + public static final int EDIT = 2; + + public static final int DELETE = 3; + + public static final int CONFIRM = 4; + + protected CrudMode() { // nothing } - } diff --git a/src/main/java/org/codelibs/fess/app/web/RootAction.java b/src/main/java/org/codelibs/fess/app/web/RootAction.java new file mode 100644 index 000000000..3107c4257 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/RootAction.java @@ -0,0 +1,46 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web; + +import org.codelibs.fess.app.web.base.FessSearchAction; +import org.lastaflute.web.Execute; +import org.lastaflute.web.response.HtmlResponse; + +public class RootAction extends FessSearchAction { + + // =================================================================================== + // Constant + // + + // =================================================================================== + // Attribute + // + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final RootForm form) { + searchAvailable(); + + return asHtml(path_IndexJsp).renderWith(data -> { + buildLabelParams(form.fields); + buildInitParams(); + }); + } + +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/app/web/RootForm.java b/src/main/java/org/codelibs/fess/app/web/RootForm.java new file mode 100644 index 000000000..4b1668890 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/RootForm.java @@ -0,0 +1,37 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +public class RootForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map fields = new HashMap<>(); + + //@Maxbytelength(maxbytelength = 1000) + public String query; + + public String sort; + + public String num; + + public String[] lang; +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/AdminAction.java b/src/main/java/org/codelibs/fess/app/web/admin/AdminAction.java new file mode 100644 index 000000000..ae72859eb --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/AdminAction.java @@ -0,0 +1,42 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin; + +import org.codelibs.fess.app.web.admin.wizard.AdminWizardAction; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.lastaflute.web.Execute; +import org.lastaflute.web.response.HtmlResponse; + +public class AdminAction extends FessAdminAction { + + // =================================================================================== + // Constant + // + + // =================================================================================== + // Attribute + // + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index() { + return redirect(AdminWizardAction.class); + } + +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/AdminBoostdocumentruleAction.java b/src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/AdminBoostdocumentruleAction.java new file mode 100644 index 000000000..5866bb063 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/AdminBoostdocumentruleAction.java @@ -0,0 +1,337 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.boostdocumentrule; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.BoostDocumentRulePager; +import org.codelibs.fess.app.service.BoostDocumentRuleService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.BoostDocumentRule; +import org.codelibs.fess.helper.SystemHelper; +import org.dbflute.optional.OptionalEntity; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + */ +public class AdminBoostdocumentruleAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private BoostDocumentRuleService boostDocumentRuleService; + @Resource + private BoostDocumentRulePager boostDocumentRulePager; + @Resource + private SystemHelper systemHelper; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("boostDocumentRule")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final SearchForm form) { + return asHtml(path_AdminBoostdocumentrule_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final SearchForm form) { + boostDocumentRulePager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminBoostdocumentrule_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final SearchForm form) { + copyBeanToBean(form, boostDocumentRulePager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminBoostdocumentrule_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final SearchForm form) { + boostDocumentRulePager.clear(); + return asHtml(path_AdminBoostdocumentrule_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final SearchForm form) { + return asHtml(path_AdminBoostdocumentrule_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final SearchForm form) { + data.register("boostDocumentRuleItems", boostDocumentRuleService.getBoostDocumentRuleList(boostDocumentRulePager)); // page navi + + // restore from pager + copyBeanToBean(boostDocumentRulePager, form, op -> op.include("id")); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage() { + return asHtml(path_AdminBoostdocumentrule_EditJsp).useForm(CreateForm.class, op -> { + op.setup(form -> { + form.initialize(); + form.crudMode = CrudMode.CREATE; + }); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id) { + verifyCrudMode(crudMode, CrudMode.EDIT); + return asHtml(path_AdminBoostdocumentrule_EditJsp).useForm(EditForm.class, op -> { + op.setup(form -> { + boostDocumentRuleService.getBoostDocumentRule(id).ifPresent(entity -> { + copyBeanToBean(entity, form, copyOp -> { + copyOp.excludeNull(); + }); + }).orElse(() -> { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, id), toEditHtml()); + }); + form.crudMode = crudMode; + }); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse createagain(final CreateForm form) { + verifyCrudMode(form.crudMode, CrudMode.CREATE); + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminBoostdocumentrule_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final EditForm form) { + verifyCrudMode(form.crudMode, CrudMode.EDIT); + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminBoostdocumentrule_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final EditForm form) { + validate(form, messages -> {}, toEditHtml()); + form.crudMode = CrudMode.EDIT; + final String id = form.id; + boostDocumentRuleService.getBoostDocumentRule(id).ifPresent(entity -> { + copyBeanToBean(entity, form, op -> {}); + }).orElse(() -> { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, id), toEditHtml()); + }); + return asHtml(path_AdminBoostdocumentrule_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id) { + verifyCrudMode(crudMode, CrudMode.DELETE); + return asHtml(path_AdminBoostdocumentrule_ConfirmJsp).useForm(EditForm.class, op -> { + op.setup(form -> { + boostDocumentRuleService.getBoostDocumentRule(id).ifPresent(entity -> { + copyBeanToBean(entity, form, copyOp -> { + copyOp.excludeNull(); + }); + }).orElse(() -> { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, id), toEditHtml()); + }); + form.crudMode = crudMode; + }); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final EditForm form) { + validate(form, messages -> {}, toEditHtml()); + form.crudMode = CrudMode.DELETE; + final String id = form.id; + boostDocumentRuleService.getBoostDocumentRule(id).ifPresent(entity -> { + copyBeanToBean(entity, form, op -> {}); + }).orElse(() -> { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, id), toEditHtml()); + }); + return asHtml(path_AdminBoostdocumentrule_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id) { + verifyCrudMode(crudMode, CrudMode.CONFIRM); + return asHtml(path_AdminBoostdocumentrule_ConfirmJsp).useForm(EditForm.class, op -> { + op.setup(form -> { + boostDocumentRuleService.getBoostDocumentRule(id).ifPresent(entity -> { + copyBeanToBean(entity, form, copyOp -> { + copyOp.excludeNull(); + }); + form.crudMode = crudMode; + }).orElse(() -> { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, id), toEditHtml()); + }); + }); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final CreateForm form) { + validate(form, messages -> {}, toEditHtml()); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminBoostdocumentrule_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final EditForm form) { + validate(form, messages -> {}, toEditHtml()); + form.crudMode = CrudMode.EDIT; + return asHtml(path_AdminBoostdocumentrule_ConfirmJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final CreateForm form) { + verifyCrudMode(form.crudMode, CrudMode.CREATE); + validate(form, messages -> {}, toEditHtml()); + createBoostDocumentRule(form).ifPresent(entity -> { + copyBeanToBean(form, entity, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + boostDocumentRuleService.store(entity); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + }).orElse(() -> { + throwValidationError(messages -> messages.addErrorsCrudFailedToCreateCrudTable(GLOBAL), toEditHtml()); + }); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final EditForm form) { + verifyCrudMode(form.crudMode, CrudMode.EDIT); + validate(form, messages -> {}, toEditHtml()); + createBoostDocumentRule(form).ifPresent(entity -> { + copyBeanToBean(form, entity, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + boostDocumentRuleService.store(entity); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + }).orElse(() -> { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + }); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final EditForm form) { + verifyCrudMode(form.crudMode, CrudMode.DELETE); + validate(form, messages -> {}, toEditHtml()); + final String id = form.id; + boostDocumentRuleService.getBoostDocumentRule(id).ifPresent(entity -> { + boostDocumentRuleService.delete(entity); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + }).orElse(() -> { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, id), toEditHtml()); + }); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + + protected OptionalEntity createBoostDocumentRule(final CreateForm form) { + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + switch (form.crudMode) { + case CrudMode.CREATE: + if (form instanceof CreateForm) { + final BoostDocumentRule entity = new BoostDocumentRule(); + entity.setCreatedBy(username); + entity.setCreatedTime(currentTime); + entity.setUpdatedBy(username); + entity.setUpdatedTime(currentTime); + return OptionalEntity.of(entity); + } + break; + case CrudMode.EDIT: + if (form instanceof EditForm) { + return boostDocumentRuleService.getBoostDocumentRule(((EditForm) form).id).map(entity -> { + entity.setUpdatedBy(username); + entity.setUpdatedTime(currentTime); + return entity; + }); + } + break; + default: + break; + } + return OptionalEntity.empty(); + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final int crudMode, final int expectedMode) { + if (crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminBoostdocumentrule_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/CreateForm.java b/src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/CreateForm.java new file mode 100644 index 000000000..e69af9ed1 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/CreateForm.java @@ -0,0 +1,45 @@ +package org.codelibs.fess.app.web.admin.boostdocumentrule; + +import java.io.Serializable; + +import javax.validation.constraints.Max; +import javax.validation.constraints.Min; +import javax.validation.constraints.Size; + +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.util.ComponentUtil; +import org.lastaflute.web.validation.Required; + +public class CreateForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Integer crudMode; + + @Required + @Size(max = 10000) + public String urlExpr; + + @Required + @Size(max = 10000) + public String boostExpr; + + @Required + @Min(value = 0) + @Max(value = 2147483647) + public Integer sortOrder; + + @Required + @Size(max = 1000) + public String createdBy; + + @Required + public Long createdTime; + + public void initialize() { + crudMode = CrudMode.CREATE; + sortOrder = 0; + createdBy = ComponentUtil.getSystemHelper().getUsername(); + createdTime = ComponentUtil.getSystemHelper().getCurrentTimeAsLong(); + } +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/EditForm.java b/src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/EditForm.java new file mode 100644 index 000000000..a6bf46cb2 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/EditForm.java @@ -0,0 +1,43 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.boostdocumentrule; + +import javax.validation.constraints.Size; + +import org.lastaflute.web.validation.Required; + +/** + * @author shinsuke + * @author jflute + */ +public class EditForm extends CreateForm { + + private static final long serialVersionUID = 1L; + + @Required + @Size(max = 1000) + public String id; + + @Size(max = 1000) + public String updatedBy; + + public Long updatedTime; + + @Required + public Integer versionNo; + +} diff --git a/src/main/java/org/codelibs/fess/web/LoginForm.java b/src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/SearchForm.java similarity index 80% rename from src/main/java/org/codelibs/fess/web/LoginForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/SearchForm.java index 1c48b029b..73b074f63 100644 --- a/src/main/java/org/codelibs/fess/web/LoginForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/boostdocumentrule/SearchForm.java @@ -14,16 +14,18 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web; +package org.codelibs.fess.app.web.admin.boostdocumentrule; import java.io.Serializable; -public class LoginForm implements Serializable { +/** + * @author codelibs + * @author jflute + */ +public class SearchForm implements Serializable { private static final long serialVersionUID = 1L; - public String returnPath; - - public String type; + public String id; } diff --git a/src/main/java/org/codelibs/fess/app/web/admin/crawl/AdminCrawlAction.java b/src/main/java/org/codelibs/fess/app/web/admin/crawl/AdminCrawlAction.java new file mode 100644 index 000000000..b7c2b5119 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/crawl/AdminCrawlAction.java @@ -0,0 +1,183 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.crawl; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.core.lang.StringUtil; +import org.codelibs.core.misc.DynamicProperties; +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.web.admin.keymatch.AdminKeymatchAction; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.helper.SystemHelper; +import org.codelibs.fess.util.ComponentUtil; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.util.LaRequestUtil; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +/** + * @author shinsuke + * @author Shunji Makino + */ +public class AdminCrawlAction extends FessAdminAction { + + private static final Logger logger = LoggerFactory.getLogger(AdminKeymatchAction.class); + // =================================================================================== + // Attribute + // ========= + @Resource + protected DynamicProperties crawlerProperties; + @Resource + protected SystemHelper systemHelper; + + public String getHelpLink() { + return systemHelper.getHelpLink("crawl"); + } + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("crawl")); + runtime.registerData("supportedSearchItems", getSupportedSearchItems()); + } + + // =================================================================================== + + protected void updateForm(final CrawlEditForm form) { + form.diffCrawling = crawlerProperties.getProperty(Constants.DIFF_CRAWLING_PROPERTY, Constants.TRUE); + form.useAclAsRole = crawlerProperties.getProperty(Constants.USE_ACL_AS_ROLE, Constants.FALSE); + form.dayForCleanup = crawlerProperties.getProperty(Constants.DAY_FOR_CLEANUP_PROPERTY, "1"); + form.crawlingThreadCount = crawlerProperties.getProperty(Constants.CRAWLING_THREAD_COUNT_PROPERTY, "5"); + form.searchLog = crawlerProperties.getProperty(Constants.SEARCH_LOG_PROPERTY, Constants.TRUE); + form.userInfo = crawlerProperties.getProperty(Constants.USER_INFO_PROPERTY, Constants.TRUE); + form.userFavorite = crawlerProperties.getProperty(Constants.USER_FAVORITE_PROPERTY, Constants.FALSE); + form.webApiXml = crawlerProperties.getProperty(Constants.WEB_API_XML_PROPERTY, Constants.TRUE); + form.webApiJson = crawlerProperties.getProperty(Constants.WEB_API_JSON_PROPERTY, Constants.TRUE); + form.defaultLabelValue = crawlerProperties.getProperty(Constants.DEFAULT_LABEL_VALUE_PROPERTY, StringUtil.EMPTY); + form.appendQueryParameter = crawlerProperties.getProperty(Constants.APPEND_QUERY_PARAMETER_PROPERTY, Constants.FALSE); + form.supportedSearch = crawlerProperties.getProperty(Constants.SUPPORTED_SEARCH_FEATURE_PROPERTY, Constants.SUPPORTED_SEARCH_WEB); + form.ignoreFailureType = + crawlerProperties.getProperty(Constants.IGNORE_FAILURE_TYPE_PROPERTY, Constants.DEFAULT_IGNORE_FAILURE_TYPE); + form.failureCountThreshold = + crawlerProperties.getProperty(Constants.FAILURE_COUNT_THRESHOLD_PROPERTY, Constants.DEFAULT_FAILURE_COUNT); + form.hotSearchWord = crawlerProperties.getProperty(Constants.WEB_API_HOT_SEARCH_WORD_PROPERTY, Constants.TRUE); + form.csvFileEncoding = crawlerProperties.getProperty(Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8); + form.purgeSearchLogDay = crawlerProperties.getProperty(Constants.PURGE_SEARCH_LOG_DAY_PROPERTY, Constants.DEFAULT_PURGE_DAY); + form.purgeJobLogDay = crawlerProperties.getProperty(Constants.PURGE_JOB_LOG_DAY_PROPERTY, Constants.DEFAULT_PURGE_DAY); + form.purgeUserInfoDay = crawlerProperties.getProperty(Constants.PURGE_USER_INFO_DAY_PROPERTY, Constants.DEFAULT_PURGE_DAY); + form.purgeByBots = crawlerProperties.getProperty(Constants.PURGE_BY_BOTS_PROPERTY, Constants.DEFAULT_PURGE_BY_BOTS); + form.notificationTo = crawlerProperties.getProperty(Constants.NOTIFICATION_TO_PROPERTY, StringUtil.EMPTY); + form.suggestSearchLog = crawlerProperties.getProperty(Constants.SUGGEST_SEARCH_LOG_PROPERTY, Constants.TRUE); + form.purgeSuggestSearchLogDay = crawlerProperties.getProperty(Constants.PURGE_SUGGEST_SEARCH_LOG_DAY_PROPERTY, "30"); + } + + // + @Token(save = true, validate = false) + @Execute + public HtmlResponse index(final CrawlEditForm form) { + return asHtml(path_AdminCrawl_IndexJsp).renderWith(data -> { + updateForm(form); + }); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final CrawlEditForm form) { + crawlerProperties.setProperty(Constants.DIFF_CRAWLING_PROPERTY, + form.diffCrawling != null && Constants.ON.equalsIgnoreCase(form.diffCrawling) ? Constants.TRUE : Constants.FALSE); + crawlerProperties.setProperty(Constants.USE_ACL_AS_ROLE, + form.useAclAsRole != null && Constants.ON.equalsIgnoreCase(form.useAclAsRole) ? Constants.TRUE : Constants.FALSE); + crawlerProperties.setProperty(Constants.DAY_FOR_CLEANUP_PROPERTY, form.dayForCleanup); + crawlerProperties.setProperty(Constants.CRAWLING_THREAD_COUNT_PROPERTY, form.crawlingThreadCount); + crawlerProperties.setProperty(Constants.SEARCH_LOG_PROPERTY, + form.searchLog != null && Constants.ON.equalsIgnoreCase(form.searchLog) ? Constants.TRUE : Constants.FALSE); + crawlerProperties.setProperty(Constants.USER_INFO_PROPERTY, + form.userInfo != null && Constants.ON.equalsIgnoreCase(form.userInfo) ? Constants.TRUE : Constants.FALSE); + crawlerProperties.setProperty(Constants.USER_FAVORITE_PROPERTY, + form.userFavorite != null && Constants.ON.equalsIgnoreCase(form.userFavorite) ? Constants.TRUE : Constants.FALSE); + crawlerProperties.setProperty(Constants.WEB_API_XML_PROPERTY, + form.webApiXml != null && Constants.ON.equalsIgnoreCase(form.webApiXml) ? Constants.TRUE : Constants.FALSE); + crawlerProperties.setProperty(Constants.WEB_API_JSON_PROPERTY, + form.webApiJson != null && Constants.ON.equalsIgnoreCase(form.webApiJson) ? Constants.TRUE : Constants.FALSE); + crawlerProperties.setProperty(Constants.DEFAULT_LABEL_VALUE_PROPERTY, form.defaultLabelValue); + crawlerProperties.setProperty(Constants.APPEND_QUERY_PARAMETER_PROPERTY, + form.appendQueryParameter != null && Constants.ON.equalsIgnoreCase(form.appendQueryParameter) ? Constants.TRUE + : Constants.FALSE); + crawlerProperties.setProperty(Constants.SUPPORTED_SEARCH_FEATURE_PROPERTY, form.supportedSearch); + crawlerProperties.setProperty(Constants.IGNORE_FAILURE_TYPE_PROPERTY, form.ignoreFailureType); + crawlerProperties.setProperty(Constants.FAILURE_COUNT_THRESHOLD_PROPERTY, form.failureCountThreshold); + crawlerProperties.setProperty(Constants.WEB_API_HOT_SEARCH_WORD_PROPERTY, + form.hotSearchWord != null && Constants.ON.equalsIgnoreCase(form.hotSearchWord) ? Constants.TRUE : Constants.FALSE); + crawlerProperties.setProperty(Constants.CSV_FILE_ENCODING_PROPERTY, form.csvFileEncoding); + crawlerProperties.setProperty(Constants.PURGE_SEARCH_LOG_DAY_PROPERTY, form.purgeSearchLogDay); + crawlerProperties.setProperty(Constants.PURGE_JOB_LOG_DAY_PROPERTY, form.purgeJobLogDay); + crawlerProperties.setProperty(Constants.PURGE_USER_INFO_DAY_PROPERTY, form.purgeUserInfoDay); + crawlerProperties.setProperty(Constants.PURGE_BY_BOTS_PROPERTY, form.purgeByBots); + crawlerProperties.setProperty(Constants.NOTIFICATION_TO_PROPERTY, form.notificationTo); + crawlerProperties.setProperty(Constants.SUGGEST_SEARCH_LOG_PROPERTY, + form.suggestSearchLog != null && Constants.ON.equalsIgnoreCase(form.suggestSearchLog) ? Constants.TRUE : Constants.FALSE); + crawlerProperties.setProperty(Constants.PURGE_SUGGEST_SEARCH_LOG_DAY_PROPERTY, form.purgeSuggestSearchLogDay); + + crawlerProperties.store(); + saveInfo(messages -> messages.addSuccessUpdateCrawlerParams(GLOBAL)); + return redirect(getClass()); + } + + public List getDayItems() { + final List items = new ArrayList(); + for (int i = 0; i < 32; i++) { + items.add(Integer.valueOf(i).toString()); + } + for (int i = 40; i < 370; i += 10) { + items.add(Integer.valueOf(i).toString()); + } + items.add(Integer.valueOf(365).toString()); + return items; + } + + private List> getSupportedSearchItems() { + final List> list = new ArrayList>(); + list.add(createItem( + ComponentUtil.getMessageManager().getMessage(LaRequestUtil.getRequest().getLocale(), "labels.supported_search_web"), + Constants.SUPPORTED_SEARCH_WEB)); + list.add(createItem( + ComponentUtil.getMessageManager().getMessage(LaRequestUtil.getRequest().getLocale(), "labels.supported_search_none"), + Constants.SUPPORTED_SEARCH_NONE)); + return list; + } + + private Map createItem(final String label, final String value) { + final Map map = new HashMap(); + map.put(Constants.ITEM_LABEL, label); + map.put(Constants.ITEM_VALUE, value); + return map; + + } + +} diff --git a/src/main/java/org/codelibs/fess/web/admin/CrawlForm.java b/src/main/java/org/codelibs/fess/app/web/admin/crawl/CrawlEditForm.java similarity index 55% rename from src/main/java/org/codelibs/fess/web/admin/CrawlForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/crawl/CrawlEditForm.java index 44116a073..1919e2fad 100644 --- a/src/main/java/org/codelibs/fess/web/admin/CrawlForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/crawl/CrawlEditForm.java @@ -14,91 +14,90 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.crawl; import java.io.Serializable; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.LongRange; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; - -public class CrawlForm implements Serializable { +/** + * @author codelibs + * @author Shunji Makino + */ +public class CrawlEditForm implements Serializable { private static final long serialVersionUID = 1L; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String diffCrawling; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String useAclAsRole; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String serverRotation; - @Required - @IntRange(min = -1, max = 1000) + //@Required + //@IntRange(min = -1, max = 1000) public String dayForCleanup; - @Required - @LongRange(min = 0, max = 100) + //@Required + //@LongRange(min = 0, max = 100) public String crawlingThreadCount; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String searchLog; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String userInfo; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String userFavorite; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String webApiXml; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String webApiJson; - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String defaultLabelValue; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String appendQueryParameter; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String supportedSearch; - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String ignoreFailureType; - @IntRange(min = -1, max = 10000) + //@IntRange(min = -1, max = 10000) public String failureCountThreshold; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String hotSearchWord; - @Required - @Maxbytelength(maxbytelength = 20) + //@Required + //@Maxbytelength(maxbytelength = 20) public String csvFileEncoding; - @IntRange(min = 0, max = 100000) + //@IntRange(min = 0, max = 100000) public String purgeSearchLogDay; - @IntRange(min = 0, max = 100000) + //@IntRange(min = 0, max = 100000) public String purgeJobLogDay; - @IntRange(min = 0, max = 100000) + //@IntRange(min = 0, max = 100000) public String purgeUserInfoDay; - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String purgeByBots; - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String notificationTo; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String suggestSearchLog; - @IntRange(min = 0, max = 100000) + //@IntRange(min = 0, max = 100000) public String purgeSuggestSearchLogDay; } diff --git a/src/main/java/org/codelibs/fess/app/web/admin/crawl/CrawlSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/crawl/CrawlSearchForm.java new file mode 100644 index 000000000..43b0fd88c --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/crawl/CrawlSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.crawl; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Shunji Makino + */ +public class CrawlSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/crawlingsession/AdminCrawlingsessionAction.java b/src/main/java/org/codelibs/fess/app/web/admin/crawlingsession/AdminCrawlingsessionAction.java new file mode 100644 index 000000000..5caa2a876 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/crawlingsession/AdminCrawlingsessionAction.java @@ -0,0 +1,202 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.crawlingsession; + +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.CrawlingSessionPager; +import org.codelibs.fess.app.service.CrawlingSessionService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.CrawlingSession; +import org.codelibs.fess.helper.JobHelper; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + * @author Shunji Makino + */ +public class AdminCrawlingsessionAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private CrawlingSessionService crawlingSessionService; + @Resource + private CrawlingSessionPager crawlingSessionPager; + @Resource + private SystemHelper systemHelper; + @Resource + protected JobHelper jobHelper; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("crawlingSession")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse deleteall(final CrawlingSessionEditForm form) { + crawlingSessionService.deleteOldSessions(jobHelper.getRunningSessionIdSet()); + saveInfo(messages -> messages.addSuccessCrawlingSessionDeleteAll(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse index(final CrawlingSessionSearchForm form) { + return asHtml(path_AdminCrawlingsession_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final CrawlingSessionSearchForm form) { + crawlingSessionPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminCrawlingsession_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final CrawlingSessionSearchForm form) { + copyBeanToBean(form.searchParams, crawlingSessionPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminCrawlingsession_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final CrawlingSessionSearchForm form) { + crawlingSessionPager.clear(); + return asHtml(path_AdminCrawlingsession_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final CrawlingSessionSearchForm form) { + return asHtml(path_AdminCrawlingsession_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final CrawlingSessionSearchForm form) { + data.register("crawlingSessionItems", crawlingSessionService.getCrawlingSessionList(crawlingSessionPager)); // page navi + + // restore from pager + copyBeanToBean(crawlingSessionPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final CrawlingSessionEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadCrawlingSession(form); + return asHtml(path_AdminCrawlingsession_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final CrawlingSessionEditForm form) { + form.crudMode = CrudMode.DELETE; + loadCrawlingSession(form); + return asHtml(path_AdminCrawlingsession_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final CrawlingSessionEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadCrawlingSession(form); + return asHtml(path_AdminCrawlingsession_ConfirmJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Execute + public HtmlResponse delete(final CrawlingSessionEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + crawlingSessionService.delete(getCrawlingSession(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadCrawlingSession(final CrawlingSessionEditForm form) { + copyBeanToBean(getCrawlingSession(form), form, op -> op.exclude("crudMode")); + } + + protected CrawlingSession getCrawlingSession(final CrawlingSessionEditForm form) { + final CrawlingSession crawlingSession = crawlingSessionService.getCrawlingSession(createKeyMap(form)); + return crawlingSession; + } + + protected Map createKeyMap(final CrawlingSessionEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final CrawlingSessionEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toIndexHtml()); + } + } + + protected VaErrorHook toIndexHtml() { + return () -> { + return asHtml(path_AdminCrawlingsession_IndexJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/CrawlingSessionForm.java b/src/main/java/org/codelibs/fess/app/web/admin/crawlingsession/CrawlingSessionEditForm.java similarity index 54% rename from src/main/java/org/codelibs/fess/web/admin/CrawlingSessionForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/crawlingsession/CrawlingSessionEditForm.java index cb096305d..ba5b89633 100644 --- a/src/main/java/org/codelibs/fess/web/admin/CrawlingSessionForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/crawlingsession/CrawlingSessionEditForm.java @@ -14,49 +14,37 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.crawlingsession; import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; -import org.seasar.struts.annotation.DateType; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; - -public class CrawlingSessionForm implements Serializable { +/** + * @author codelibs + * @author Shunji Makino + */ +public class CrawlingSessionEditForm implements Serializable { private static final long serialVersionUID = 1L; - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType + //@IntegerType public int crudMode; - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 20) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 20) public String sessionId; - @Maxbytelength(maxbytelength = 20) + //@Maxbytelength(maxbytelength = 20) public String name; - @DateType + //@DateType public String expiredTime; - @Required(target = "confirmfromupdate,update,delete") - @DateType + //@Required(target = "confirmfromupdate,update,delete") + //@DateType public String createdTime; public void initialize() { @@ -68,5 +56,4 @@ public class CrawlingSessionForm implements Serializable { createdTime = null; } - } diff --git a/src/main/java/org/codelibs/fess/app/web/admin/crawlingsession/CrawlingSessionSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/crawlingsession/CrawlingSessionSearchForm.java new file mode 100644 index 000000000..1035ee65e --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/crawlingsession/CrawlingSessionSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.crawlingsession; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Shunji Makino + */ +public class CrawlingSessionSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/dataconfig/AdminDataconfigAction.java b/src/main/java/org/codelibs/fess/app/web/admin/dataconfig/AdminDataconfigAction.java new file mode 100644 index 000000000..7b6829bfe --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/dataconfig/AdminDataconfigAction.java @@ -0,0 +1,339 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.dataconfig; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.DataConfigPager; +import org.codelibs.fess.app.service.DataConfigService; +import org.codelibs.fess.app.service.LabelTypeService; +import org.codelibs.fess.app.service.RoleTypeService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.ds.DataStoreFactory; +import org.codelibs.fess.es.exentity.DataConfig; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class AdminDataconfigAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private DataConfigService dataConfigService; + @Resource + private DataConfigPager dataConfigPager; + @Resource + private SystemHelper systemHelper; + @Resource + protected RoleTypeService roleTypeService; + @Resource + protected LabelTypeService labelTypeService; + @Resource + protected DataStoreFactory dataStoreFactory; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("dataConfig")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final DataConfigSearchForm form) { + return asHtml(path_AdminDataconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final DataConfigSearchForm form) { + dataConfigPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminDataconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final DataConfigSearchForm form) { + copyBeanToBean(form.searchParams, dataConfigPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminDataconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final DataConfigSearchForm form) { + dataConfigPager.clear(); + return asHtml(path_AdminDataconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final DataConfigSearchForm form) { + return asHtml(path_AdminDataconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final DataConfigSearchForm form) { + data.register("dataConfigItems", dataConfigService.getDataConfigList(dataConfigPager)); // page navi + + // restore from pager + copyBeanToBean(dataConfigPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final DataConfigEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminDataconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + registerHandlerNames(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final DataConfigEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadDataConfig(form); + return asHtml(path_AdminDataconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + registerHandlerNames(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final DataConfigEditForm form) { + return asHtml(path_AdminDataconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + registerHandlerNames(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final DataConfigEditForm form) { + form.crudMode = CrudMode.EDIT; + loadDataConfig(form); + return asHtml(path_AdminDataconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + registerHandlerNames(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final DataConfigEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadDataConfig(form); + return asHtml(path_AdminDataconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + registerHandlerNames(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final DataConfigEditForm form) { + form.crudMode = CrudMode.DELETE; + loadDataConfig(form); + return asHtml(path_AdminDataconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + registerHandlerNames(data); + }); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final DataConfigEditForm form) { + try { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadDataConfig(form); + return asHtml(path_AdminDataconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + registerHandlerNames(data); + }); + } catch (final Exception e) { + e.printStackTrace(); + return asHtml(path_AdminDataconfig_ConfirmJsp); + } + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final DataConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminDataconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + registerHandlerNames(data); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final DataConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminDataconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + registerHandlerNames(data); + }); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final DataConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + dataConfigService.store(createDataConfig(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final DataConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + dataConfigService.store(createDataConfig(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final DataConfigEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + dataConfigService.delete(getDataConfig(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadDataConfig(final DataConfigEditForm form) { + copyBeanToBean(getDataConfig(form), form, op -> op.exclude("crudMode")); + } + + protected DataConfig getDataConfig(final DataConfigEditForm form) { + final DataConfig dataConfig = dataConfigService.getDataConfig(createKeyMap(form)); + if (dataConfig == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return dataConfig; + } + + protected DataConfig createDataConfig(final DataConfigEditForm form) { + DataConfig dataConfig; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + dataConfig = getDataConfig(form); + } else { + dataConfig = new DataConfig(); + dataConfig.setCreatedBy(username); + dataConfig.setCreatedTime(currentTime); + } + dataConfig.setUpdatedBy(username); + dataConfig.setUpdatedTime(currentTime); + copyBeanToBean(form, dataConfig, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return dataConfig; + } + + protected Map createKeyMap(final DataConfigEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + protected void registerRolesAndLabels(final RenderData data) { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + data.register("labelTypeItems", labelTypeService.getLabelTypeList()); + } + + public void registerHandlerNames(final RenderData data) { + final List dataStoreNameList = dataStoreFactory.getDataStoreNameList(); + final List> itemList = new ArrayList>(); + for (final String name : dataStoreNameList) { + final Map map = new HashMap(); + map.put(Constants.ITEM_LABEL, name); + map.put(Constants.ITEM_VALUE, name); + itemList.add(map); + } + data.register("handlerNameItems", itemList); + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final DataConfigEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminDataconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + registerHandlerNames(data); + }); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/DataConfigForm.java b/src/main/java/org/codelibs/fess/app/web/admin/dataconfig/DataConfigEditForm.java similarity index 58% rename from src/main/java/org/codelibs/fess/web/admin/DataConfigForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/dataconfig/DataConfigEditForm.java index 33329b9c9..15d75942d 100644 --- a/src/main/java/org/codelibs/fess/web/admin/DataConfigForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/dataconfig/DataConfigEditForm.java @@ -14,20 +14,19 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.dataconfig; import java.io.Serializable; import java.util.HashMap; import java.util.Map; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class DataConfigForm implements Serializable { +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class DataConfigEditForm implements Serializable { private static final long serialVersionUID = 1L; @@ -35,64 +34,64 @@ public class DataConfigForm implements Serializable { public String[] labelTypeIds; - @IntegerType + //@IntegerType public String pageNumber; public Map searchParams = new HashMap(); - @IntegerType + //@IntegerType public int crudMode; public String getCurrentPageNumber() { return pageNumber; } - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 200) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 200) public String name; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 4000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 4000) public String handlerName; public String handlerParameter; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String handlerScript; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) public String boost; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 5) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 5) public String available; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType + //@IntRange(min = 0, max = 2147483647) public String sortOrder; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType public String versionNo; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/dataconfig/DataConfigSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/dataconfig/DataConfigSearchForm.java new file mode 100644 index 000000000..4832dd76f --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/dataconfig/DataConfigSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.dataconfig; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class DataConfigSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/design/AdminDesignAction.java b/src/main/java/org/codelibs/fess/app/web/admin/design/AdminDesignAction.java new file mode 100644 index 000000000..6eebf610c --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/design/AdminDesignAction.java @@ -0,0 +1,311 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.design; + +import java.io.File; +import java.io.FileInputStream; +import java.io.Serializable; +import java.io.UnsupportedEncodingException; +import java.util.ArrayList; +import java.util.List; +import java.util.Locale; + +import javax.annotation.Resource; + +import org.apache.commons.io.FileUtils; +import org.codelibs.core.io.FileUtil; +import org.codelibs.core.lang.StringUtil; +import org.codelibs.core.misc.DynamicProperties; +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.exception.FessSystemException; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.ActionResponse; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.StreamResponse; +import org.lastaflute.web.validation.VaErrorHook; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +/** + * @author codelibs + * @author jflute + */ +public class AdminDesignAction extends FessAdminAction implements Serializable { + + private static final long serialVersionUID = 1L; + private static final Logger logger = LoggerFactory.getLogger(AdminDesignAction.class); + + // =================================================================================== + // Attribute + // ========= + @Resource + private DynamicProperties crawlerProperties; + @Resource + private SystemHelper systemHelper; + + // =================================================================================== + // Hook + // ====== + @Override + public ActionResponse hookBefore(final ActionRuntime runtime) { + checkEditorStatus(runtime); + return super.hookBefore(runtime); + } + + private void checkEditorStatus(final ActionRuntime runtime) { + if (cannotEdit()) { + throwValidationError(messages -> messages.addErrorsDesignEditorDisabled(GLOBAL), toMainHtml()); + } + } + + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("editable", cannotEdit()); + runtime.registerData("fileNameItems", loadFileNameItems()); + runtime.registerData("helpLink", systemHelper.getHelpLink("design")); + } + + private boolean cannotEdit() { + return Constants.FALSE.equals(crawlerProperties.getProperty(Constants.WEB_DESIGN_EDITOR_PROPERTY, Constants.TRUE)); + } + + private List loadFileNameItems() { + final File baseDir = new File(getServletContext().getRealPath("/")); + final List fileNameItems = new ArrayList(); + final List fileList = getAccessibleFileList(baseDir); + final int length = baseDir.getAbsolutePath().length(); + for (final File file : fileList) { + fileNameItems.add(file.getAbsolutePath().substring(length)); + } + return fileNameItems; + } + + // =================================================================================== + // Execute + // ======= + @Token(save = true, validate = false) + @Execute + public HtmlResponse index() { + return asHtml(path_AdminDesign_AdminDesignJsp).useForm(DesignForm.class); + } + + @Execute + public HtmlResponse upload(final DesignForm form) { + validate(form, messages -> {}, toMainHtml()); + final String uploadedFileName = form.designFile.getFileName(); + String fileName = form.designFileName; + if (StringUtil.isBlank(fileName)) { + fileName = uploadedFileName; + try { + int pos = fileName.indexOf('/'); + if (pos >= 0) { + fileName = fileName.substring(pos + 1); + } + pos = fileName.indexOf('\\'); + if (pos >= 0) { + fileName = fileName.substring(pos + 1); + } + } catch (final Exception e) { + throwValidationError(messages -> messages.addErrorsDesignFileNameIsInvalid(GLOBAL), toMainHtml()); + } + } + if (StringUtil.isBlank(fileName)) { + throwValidationError(messages -> messages.addErrorsDesignFileNameIsNotFound(GLOBAL), toMainHtml()); + } + + String baseDir = null; + // normalize filename + if (checkFileType(fileName, systemHelper.getSupportedUploadedMediaExtentions()) + && checkFileType(uploadedFileName, systemHelper.getSupportedUploadedMediaExtentions())) { + baseDir = "/images/"; + } else if (checkFileType(fileName, systemHelper.getSupportedUploadedCssExtentions()) + && checkFileType(uploadedFileName, systemHelper.getSupportedUploadedCssExtentions())) { + baseDir = "/css/"; + } else if (checkFileType(fileName, systemHelper.getSupportedUploadedJSExtentions()) + && checkFileType(uploadedFileName, systemHelper.getSupportedUploadedJSExtentions())) { + baseDir = "/js/"; + } else { + throwValidationError(messages -> messages.addErrorsDesignFileIsUnsupportedType(GLOBAL), toMainHtml()); + } + + final File uploadFile = new File(getServletContext().getRealPath(baseDir + fileName)); + final File parentFile = uploadFile.getParentFile(); + if (!parentFile.exists() && !parentFile.mkdirs()) { + logger.warn("Could not create " + parentFile.getAbsolutePath()); + } + + try { + write(uploadFile.getAbsolutePath(), form.designFile.getFileData()); + final String currentFileName = fileName; + saveInfo(messages -> messages.addSuccessUploadDesignFile(GLOBAL, currentFileName)); + } catch (final Exception e) { + logger.error("Failed to write an image file: {}", fileName, e); + throwValidationError(messages -> messages.addErrorsFailedToWriteDesignImageFile(GLOBAL), toMainHtml()); + } + return redirect(getClass()); + } + + private boolean checkFileType(final String fileName, final String[] exts) { + if (fileName == null) { + return false; + } + final String lFileName = fileName.toLowerCase(Locale.ENGLISH); + for (final String ext : exts) { + if (lFileName.endsWith("." + ext)) { + return true; + } + } + return false; + } + + @Execute + public StreamResponse download(final DesignForm form) { + final File file = getTargetFile(form); + if (file == null) { + throwValidationError(messages -> messages.addErrorsTargetFileDoesNotExist(GLOBAL, form.fileName), toMainHtml()); + } + return asStream(file.getName()).stream(out -> { + try (FileInputStream fis = new FileInputStream(file)) { + out.write(fis); + } + }); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse delete(final DesignForm form) { + final File file = getTargetFile(form); + if (file == null) { + throwValidationError(messages -> messages.addErrorsTargetFileDoesNotExist(GLOBAL, form.fileName), toMainHtml()); + } + if (!file.delete()) { + logger.error("Failed to delete {}", file.getAbsolutePath()); + throwValidationError(messages -> messages.addErrorsFailedToDeleteFile(GLOBAL, form.fileName), toMainHtml()); + } + saveInfo(messages -> messages.addSuccessDeleteFile(GLOBAL, form.fileName)); + return redirect(getClass()); + } + + // ----------------------------------------------------- + // Edit + // ------ + @Token(save = true, validate = false) + @Execute + public HtmlResponse edit(final DesignEditForm form) { + final String jspType = "view"; + final File jspFile = getJspFile(form.fileName, jspType); + try { + form.content = new String(FileUtil.readBytes(jspFile), Constants.UTF_8); + } catch (final UnsupportedEncodingException e) { + throw new FessSystemException("Invalid encoding", e); + } + return asHtml(path_AdminDesign_AdminDesignEditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editAsUseDefault(final DesignEditForm form) { + final String jspType = "orig/view"; + final File jspFile = getJspFile(form.fileName, jspType); + try { + form.content = new String(FileUtil.readBytes(jspFile), Constants.UTF_8); + } catch (final UnsupportedEncodingException e) { + throw new FessSystemException("Invalid encoding", e); + } + return asHtml(path_AdminDesign_AdminDesignEditJsp); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final DesignEditForm form) { + final String jspType = "view"; + final File jspFile = getJspFile(form.fileName, jspType); + + if (form.content == null) { + form.content = StringUtil.EMPTY; + } + + try { + write(jspFile.getAbsolutePath(), form.content.getBytes(Constants.UTF_8)); + saveInfo(messages -> messages.addSuccessUpdateDesignJspFile(GLOBAL, systemHelper.getDesignJspFileName(form.fileName))); + } catch (final Exception e) { + logger.error("Failed to update {}", form.fileName, e); + throwValidationError(messages -> messages.addErrorsFailedToUpdateJspFile(GLOBAL), toMainHtml()); + } + return redirect(getClass()); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse back() { + return asHtml(path_AdminDesign_AdminDesignJsp).useForm(DesignForm.class); + } + + // =================================================================================== + // Assist Logic + // ============ + private File getTargetFile(final DesignForm form) { + final File baseDir = new File(getServletContext().getRealPath("/")); + final File targetFile = new File(getServletContext().getRealPath(form.fileName)); + final List fileList = getAccessibleFileList(baseDir); + boolean exist = false; + for (final File file : fileList) { + if (targetFile.equals(file)) { + exist = true; + break; + } + } + if (exist) { + return targetFile; + } + return null; + } + + private List getAccessibleFileList(final File baseDir) { + final List fileList = new ArrayList(); + fileList.addAll(FileUtils.listFiles(new File(baseDir, "images"), systemHelper.getSupportedUploadedMediaExtentions(), true)); + fileList.addAll(FileUtils.listFiles(new File(baseDir, "css"), systemHelper.getSupportedUploadedCssExtentions(), true)); + fileList.addAll(FileUtils.listFiles(new File(baseDir, "js"), systemHelper.getSupportedUploadedJSExtentions(), true)); + return fileList; + } + + private File getJspFile(final String fileName, final String jspType) { + final String jspFileName = systemHelper.getDesignJspFileName(fileName); + if (jspFileName == null) { + throwValidationError(messages -> messages.addErrorsInvalidDesignJspFileName(GLOBAL), toMainHtml()); + } + final File jspFile = new File(getServletContext().getRealPath("/WEB-INF/" + jspType + "/" + jspFileName)); + if (jspFile == null || !jspFile.exists()) { + throwValidationError(messages -> messages.addErrorsDesignJspFileDoesNotExist(GLOBAL), toMainHtml()); + } + return jspFile; + } + + // =================================================================================== + // Small Helper + // ============ + private VaErrorHook toMainHtml() { + return () -> { + return asHtml(path_AdminDesign_AdminDesignJsp); + }; + } +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/AppletForm.java b/src/main/java/org/codelibs/fess/app/web/admin/design/DesignEditForm.java similarity index 77% rename from src/main/java/org/codelibs/fess/web/AppletForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/design/DesignEditForm.java index 46f810ca8..3aeeedb39 100644 --- a/src/main/java/org/codelibs/fess/web/AppletForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/design/DesignEditForm.java @@ -14,13 +14,14 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web; +package org.codelibs.fess.app.web.admin.design; -import org.seasar.struts.annotation.Required; +/** + * @author codelibs + * @author jflute + */ +public class DesignEditForm { -public class AppletForm { - @Required - public String uri; - - public String encoding; + public String fileName; + public String content; } diff --git a/src/main/java/org/codelibs/fess/web/admin/DesignForm.java b/src/main/java/org/codelibs/fess/app/web/admin/design/DesignForm.java similarity index 66% rename from src/main/java/org/codelibs/fess/web/admin/DesignForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/design/DesignForm.java index 4c77f7913..a7ccc16f5 100644 --- a/src/main/java/org/codelibs/fess/web/admin/DesignForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/design/DesignForm.java @@ -14,25 +14,25 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.design; import java.io.Serializable; -import org.apache.struts.upload.FormFile; -import org.seasar.struts.annotation.Required; +import org.lastaflute.web.ruts.multipart.MultipartFormFile; +import org.lastaflute.web.validation.Required; public class DesignForm implements Serializable { private static final long serialVersionUID = 1L; - @Required(target = "upload") - public FormFile designFile; + // TODO jflute target needed? (2015/07/25) + //@Required(target = "upload") + @Required + public MultipartFormFile designFile; public String designFileName; - @Required(target = "edit,editAsUseDefault,download,delete") + // TODO jflute unneeded? no validator at the method (2015/07/25) + //@Required(target = "edit,editAsUseDefault,download,delete") public String fileName; - - public String content; - } diff --git a/src/main/java/org/codelibs/fess/app/web/admin/dict/AdminDictAction.java b/src/main/java/org/codelibs/fess/app/web/admin/dict/AdminDictAction.java new file mode 100644 index 000000000..dd20ca38c --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/dict/AdminDictAction.java @@ -0,0 +1,61 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.dict; + +import javax.annotation.Resource; + +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.dict.DictionaryManager; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; + +/** + * @author Keiichi Watanabe + */ +public class AdminDictAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + protected SystemHelper systemHelper; + @Resource + protected DictionaryManager dictionaryManager; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("dict")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final DictForm form) { + return asHtml(path_AdminDict_IndexJsp).renderWith(data -> { + // TODO + // DictionaryFile[] dictFiles dictFiles = dictionaryManager.getDictionaryFiles(); + // data.register("dictFiles", dictFiles); + }); + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/DictForm.java b/src/main/java/org/codelibs/fess/app/web/admin/dict/DictForm.java similarity index 78% rename from src/main/java/org/codelibs/fess/web/admin/DictForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/dict/DictForm.java index 2d6f43c42..88d848912 100644 --- a/src/main/java/org/codelibs/fess/web/admin/DictForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/dict/DictForm.java @@ -14,12 +14,18 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.dict; import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; +/** + * @author Keiichi Watanabe + */ public class DictForm implements Serializable { private static final long serialVersionUID = 1L; + public Map searchParams = new HashMap(); } diff --git a/src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/AdminDictSynonymAction.java b/src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/AdminDictSynonymAction.java new file mode 100644 index 000000000..e2cb21f44 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/AdminDictSynonymAction.java @@ -0,0 +1,270 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.dict.synonym; + +import javax.annotation.Resource; + +import org.codelibs.core.misc.DynamicProperties; +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.SynonymPager; +import org.codelibs.fess.app.service.SynonymService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.admin.suggestelevateword.SuggestElevateWordEditForm; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author Keiichi Watanabe + */ +public class AdminDictSynonymAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private SynonymService synonymService; + @Resource + private SynonymPager synonymPager; + @Resource + private SystemHelper systemHelper; + @Resource + protected DynamicProperties crawlerProperties; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("synonym")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final SynonymSearchForm form) { + return asHtml(path_AdminDictSynonym_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final SynonymSearchForm form) { + synonymPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminDictSynonym_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final SynonymSearchForm form) { + copyBeanToBean(form.searchParams, synonymPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminDictSynonym_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final SynonymSearchForm form) { + synonymPager.clear(); + return asHtml(path_AdminDictSynonym_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final SynonymSearchForm form) { + return asHtml(path_AdminDictSynonym_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final SynonymSearchForm form) { + // TODO + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final SynonymEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminDictSynonym_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final SynonymEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + // TODO loadSynonym(form); + return asHtml(path_AdminDictSynonym_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final SynonymEditForm form) { + return asHtml(path_AdminDictSynonym_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final SynonymEditForm form) { + form.crudMode = CrudMode.EDIT; + // TODO loadSynonym(form); + return asHtml(path_AdminDictSynonym_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final SynonymEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + // TODO loadSynonym(form); + return asHtml(path_AdminDictSynonym_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final SynonymEditForm form) { + form.crudMode = CrudMode.DELETE; + // TODO loadSynonym(form); + return asHtml(path_AdminDictSynonym_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final SynonymEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + // TODO loadSynonym(form); + return asHtml(path_AdminDictSynonym_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final SynonymEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminDictSynonym_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final SynonymEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminDictSynonym_ConfirmJsp); + } + + // ----------------------------------------------------- + // Download + // ------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse downloadpage(final SynonymSearchForm form) { + return asHtml(path_AdminDictSynonym_DownloadJsp); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse download(final SynonymSearchForm form) { + // TODO Download + + return asHtml(path_AdminDictSynonym_DownloadJsp); + } + + // ----------------------------------------------------- + // Upload + // ------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse uploadpage(final SynonymUploadForm form) { + // TODO Upload + + return asHtml(path_AdminDictSynonym_UploadJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final SynonymEditForm form) { + // TODO + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final SynonymEditForm form) { + // TODO + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final SynonymEditForm form) { + // TODO + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse upload(final SynonymUploadForm form) { + // TODO + return redirect(getClass()); + } + + //=================================================================================== + // Assist Logic + // ============ + protected void loadSynonym(final SuggestElevateWordEditForm form) { + // TODO + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final SynonymEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminDictSynonym_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/dict/SynonymForm.java b/src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/SynonymEditForm.java similarity index 58% rename from src/main/java/org/codelibs/fess/web/admin/dict/SynonymForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/SynonymEditForm.java index 86477fa56..0cbc84fe4 100644 --- a/src/main/java/org/codelibs/fess/web/admin/dict/SynonymForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/SynonymEditForm.java @@ -14,47 +14,49 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin.dict; +package org.codelibs.fess.app.web.admin.dict.synonym; +import java.io.Serializable; import java.util.HashMap; import java.util.Map; -import org.apache.struts.upload.FormFile; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class SynonymEditForm implements Serializable { -public class SynonymForm { - @IntegerType + private static final long serialVersionUID = 1L; + + //@IntegerType public String pageNumber; public Map searchParams = new HashMap(); - @Required + //@Required public String dictId; - @IntegerType + //@IntegerType public int crudMode; public String getCurrentPageNumber() { return pageNumber; } - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String inputs; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String outputs; - @Required(target = "upload") - public FormFile synonymFile; + //@Required(target = "upload") + //public FormFile synonymFile; public void initialize() { id = null; diff --git a/src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/SynonymSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/SynonymSearchForm.java new file mode 100644 index 000000000..07e8f1b05 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/SynonymSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.dict.synonym; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class SynonymSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/SynonymUploadForm.java b/src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/SynonymUploadForm.java new file mode 100644 index 000000000..cca76c1ca --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/dict/synonym/SynonymUploadForm.java @@ -0,0 +1,33 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.dict.synonym; + +import java.io.Serializable; + +import org.lastaflute.web.ruts.multipart.MultipartFormFile; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class SynonymUploadForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public MultipartFormFile synonymFile; + +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/AdminDictUserdictAction.java b/src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/AdminDictUserdictAction.java new file mode 100644 index 000000000..051eb15d9 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/AdminDictUserdictAction.java @@ -0,0 +1,270 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.dict.userdict; + +import javax.annotation.Resource; + +import org.codelibs.core.misc.DynamicProperties; +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.UserDictPager; +import org.codelibs.fess.app.service.UserDictService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.admin.suggestelevateword.SuggestElevateWordEditForm; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author Keiichi Watanabe + */ +public class AdminDictUserdictAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private UserDictService userDictService; + @Resource + private UserDictPager userDictPager; + @Resource + private SystemHelper systemHelper; + @Resource + protected DynamicProperties crawlerProperties; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("userDict")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final UserDictSearchForm form) { + return asHtml(path_AdminDictUserdict_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final UserDictSearchForm form) { + userDictPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminDictUserdict_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final UserDictSearchForm form) { + copyBeanToBean(form.searchParams, userDictPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminDictUserdict_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final UserDictSearchForm form) { + userDictPager.clear(); + return asHtml(path_AdminDictUserdict_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final UserDictSearchForm form) { + return asHtml(path_AdminDictUserdict_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final UserDictSearchForm form) { + // TODO + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final UserDictEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminDictUserdict_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final UserDictEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + // TODO loadUserDict(form); + return asHtml(path_AdminDictUserdict_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final UserDictEditForm form) { + return asHtml(path_AdminDictUserdict_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final UserDictEditForm form) { + form.crudMode = CrudMode.EDIT; + // TODO loadUserDict(form); + return asHtml(path_AdminDictUserdict_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final UserDictEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + // TODO loadUserDict(form); + return asHtml(path_AdminDictUserdict_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final UserDictEditForm form) { + form.crudMode = CrudMode.DELETE; + // TODO loadUserDict(form); + return asHtml(path_AdminDictUserdict_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final UserDictEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + // TODO loadUserDict(form); + return asHtml(path_AdminDictUserdict_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final UserDictEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminDictUserdict_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final UserDictEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminDictUserdict_ConfirmJsp); + } + + // ----------------------------------------------------- + // Download + // ------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse downloadpage(final UserDictSearchForm form) { + return asHtml(path_AdminDictUserdict_DownloadJsp); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse download(final UserDictSearchForm form) { + // TODO Download + + return asHtml(path_AdminDictUserdict_DownloadJsp); + } + + // ----------------------------------------------------- + // Upload + // ------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse uploadpage(final UserDictUploadForm form) { + // TODO Upload + + return asHtml(path_AdminDictUserdict_UploadJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final UserDictEditForm form) { + // TODO + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final UserDictEditForm form) { + // TODO + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final UserDictEditForm form) { + // TODO + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse upload(final UserDictUploadForm form) { + // TODO + return redirect(getClass()); + } + + //=================================================================================== + // Assist Logic + // ============ + protected void loadUserDict(final SuggestElevateWordEditForm form) { + // TODO + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final UserDictEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminDictUserdict_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/dict/UserDictForm.java b/src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/UserDictEditForm.java similarity index 52% rename from src/main/java/org/codelibs/fess/web/admin/dict/UserDictForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/UserDictEditForm.java index e9d766a15..5423cca5e 100644 --- a/src/main/java/org/codelibs/fess/web/admin/dict/UserDictForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/UserDictEditForm.java @@ -14,55 +14,57 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin.dict; +package org.codelibs.fess.app.web.admin.dict.userdict; +import java.io.Serializable; import java.util.HashMap; import java.util.Map; -import org.apache.struts.upload.FormFile; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class UserDictEditForm implements Serializable { -public class UserDictForm { - @IntegerType + private static final long serialVersionUID = 1L; + + //@IntegerType public String pageNumber; public Map searchParams = new HashMap(); - @Required + //@Required public String dictId; - @IntegerType + //@IntegerType public int crudMode; public String getCurrentPageNumber() { return pageNumber; } - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String token; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String segmentation; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String reading; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String pos; - @Required(target = "upload") - public FormFile userDictFile; + //@Required(target = "upload") + //public FormFile userDictFile; public void initialize() { id = null; diff --git a/src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/UserDictSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/UserDictSearchForm.java new file mode 100644 index 000000000..7d72ea15e --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/UserDictSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.dict.userdict; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class UserDictSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/UserDictUploadForm.java b/src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/UserDictUploadForm.java new file mode 100644 index 000000000..73d97b4ab --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/dict/userdict/UserDictUploadForm.java @@ -0,0 +1,33 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.dict.userdict; + +import java.io.Serializable; + +import org.lastaflute.web.ruts.multipart.MultipartFormFile; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class UserDictUploadForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public MultipartFormFile userDictFile; + +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/failureurl/AdminFailureurlAction.java b/src/main/java/org/codelibs/fess/app/web/admin/failureurl/AdminFailureurlAction.java new file mode 100644 index 000000000..6f71ca017 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/failureurl/AdminFailureurlAction.java @@ -0,0 +1,162 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.failureurl; + +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.pager.FailureUrlPager; +import org.codelibs.fess.app.service.FailureUrlService; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.FailureUrl; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class AdminFailureurlAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private FailureUrlService failureUrlService; + @Resource + private FailureUrlPager failureUrlPager; + @Resource + private SystemHelper systemHelper; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("failureUrl")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final FailureUrlSearchForm form) { + return asHtml(path_AdminFailureurl_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final FailureUrlSearchForm form) { + failureUrlPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminFailureurl_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final FailureUrlSearchForm form) { + copyBeanToBean(form.searchParams, failureUrlPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminFailureurl_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final FailureUrlSearchForm form) { + failureUrlPager.clear(); + return asHtml(path_AdminFailureurl_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final FailureUrlSearchForm form) { + return asHtml(path_AdminFailureurl_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final FailureUrlSearchForm form) { + data.register("failureUrlItems", failureUrlService.getFailureUrlList(failureUrlPager)); // page navi + + // restore from pager + copyBeanToBean(failureUrlPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final FailureUrlEditForm form) { + // TODO + // form.crudMode = crudMode; + // form.id = id; + // verifyCrudMode(form, CrudMode.CONFIRM); + loadFailureUrl(form); + return asHtml(path_AdminFailureurl_ConfirmJsp); + } + + // ----------------------------------------------------- + // Actually Crud (only Delete) + // ------------- + + @Execute + public HtmlResponse delete(final FailureUrlEditForm form) { + // TODO verifyCrudMode(form, CrudMode.DELETE); + failureUrlService.delete(getFailureUrl(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse deleteall(final FailureUrlEditForm form) { + failureUrlService.deleteAll(failureUrlPager); + saveInfo(messages -> messages.addSuccessFailureUrlDeleteAll(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + + protected void loadFailureUrl(final FailureUrlEditForm form) { + copyBeanToBean(getFailureUrl(form), form, op -> op.exclude("crudMode")); + } + + protected FailureUrl getFailureUrl(final FailureUrlEditForm form) { + final FailureUrl failureUrl = failureUrlService.getFailureUrl(createKeyMap(form)); + if (failureUrl == null) { + // TODO + } + return failureUrl; + } + + protected Map createKeyMap(final FailureUrlEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + +} diff --git a/src/main/java/org/codelibs/fess/web/admin/FailureUrlForm.java b/src/main/java/org/codelibs/fess/app/web/admin/failureurl/FailureUrlEditForm.java similarity index 62% rename from src/main/java/org/codelibs/fess/web/admin/FailureUrlForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/failureurl/FailureUrlEditForm.java index 90932576a..418830ad3 100644 --- a/src/main/java/org/codelibs/fess/web/admin/FailureUrlForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/failureurl/FailureUrlEditForm.java @@ -14,19 +14,17 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.failureurl; import java.io.Serializable; import java.util.HashMap; import java.util.Map; -import org.codelibs.fess.Constants; -import org.seasar.struts.annotation.DateType; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; - -public class FailureUrlForm implements Serializable { +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class FailureUrlEditForm implements Serializable { private static final long serialVersionUID = 1L; @@ -34,41 +32,42 @@ public class FailureUrlForm implements Serializable { public String fileConfigName; - @IntegerType + //@IntegerType public String pageNumber; public Map searchParams = new HashMap(); - @IntegerType + //@IntegerType + // TODO necessary? public int crudMode; public String getCurrentPageNumber() { return pageNumber; } - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") public String url; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") public String threadName; public String errorName; public String errorLog; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@IntegerType public String errorCount; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @DateType(datePattern = Constants.DEFAULT_DATETIME_FORMAT) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@DateType(datePattern = Constants.DEFAULT_DATETIME_FORMAT) public String lastAccessTime; - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String configId; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/failureurl/FailureUrlSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/failureurl/FailureUrlSearchForm.java new file mode 100644 index 000000000..86c0b6954 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/failureurl/FailureUrlSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.failureurl; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class FailureUrlSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/fileauthentication/AdminFileauthenticationAction.java b/src/main/java/org/codelibs/fess/app/web/admin/fileauthentication/AdminFileauthenticationAction.java new file mode 100644 index 000000000..7ad21cf56 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/fileauthentication/AdminFileauthenticationAction.java @@ -0,0 +1,336 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.fileauthentication; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Locale; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.FileAuthenticationPager; +import org.codelibs.fess.app.service.FileAuthenticationService; +import org.codelibs.fess.app.service.FileConfigService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.FileAuthentication; +import org.codelibs.fess.es.exentity.FileConfig; +import org.codelibs.fess.helper.SystemHelper; +import org.codelibs.fess.util.ComponentUtil; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.util.LaRequestUtil; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author Keiichi Watanabe + */ +public class AdminFileauthenticationAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private FileAuthenticationService fileAuthenticationService; + @Resource + private FileAuthenticationPager fileAuthenticationPager; + @Resource + private SystemHelper systemHelper; + + @Resource + protected FileConfigService fileConfigService; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("fileAuthentication")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final FileAuthenticationSearchForm form) { + return asHtml(path_AdminFileauthentication_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final FileAuthenticationSearchForm form) { + fileAuthenticationPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminFileauthentication_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final FileAuthenticationSearchForm form) { + copyBeanToBean(form.searchParams, fileAuthenticationPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminFileauthentication_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final FileAuthenticationSearchForm form) { + fileAuthenticationPager.clear(); + return asHtml(path_AdminFileauthentication_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final FileAuthenticationSearchForm form) { + return asHtml(path_AdminFileauthentication_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final FileAuthenticationSearchForm form) { + data.register("fileAuthenticationItems", fileAuthenticationService.getFileAuthenticationList(fileAuthenticationPager)); // page navi + data.register("displayCreateLink", !fileConfigService.getAllFileConfigList(false, false, false, null).isEmpty()); + // restore from pager + copyBeanToBean(fileAuthenticationPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final FileAuthenticationEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminFileauthentication_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerFileConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final FileAuthenticationEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadFileAuthentication(form); + return asHtml(path_AdminFileauthentication_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerFileConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final FileAuthenticationEditForm form) { + return asHtml(path_AdminFileauthentication_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerFileConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final FileAuthenticationEditForm form) { + form.crudMode = CrudMode.EDIT; + loadFileAuthentication(form); + return asHtml(path_AdminFileauthentication_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerFileConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final FileAuthenticationEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadFileAuthentication(form); + return asHtml(path_AdminFileauthentication_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerFileConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final FileAuthenticationEditForm form) { + form.crudMode = CrudMode.DELETE; + loadFileAuthentication(form); + return asHtml(path_AdminFileauthentication_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerFileConfigItems(data); + }); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final FileAuthenticationEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadFileAuthentication(form); + return asHtml(path_AdminFileauthentication_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerFileConfigItems(data); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final FileAuthenticationEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminFileauthentication_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerFileConfigItems(data); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final FileAuthenticationEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminFileauthentication_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerFileConfigItems(data); + }); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final FileAuthenticationEditForm form) { + validate(form, messages -> {}, toEditHtml()); + fileAuthenticationService.store(createFileAuthentication(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final FileAuthenticationEditForm form) { + validate(form, messages -> {}, toEditHtml()); + fileAuthenticationService.store(createFileAuthentication(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final FileAuthenticationEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + fileAuthenticationService.delete(getFileAuthentication(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + //=================================================================================== + // Assist Logic + // ============ + protected void loadFileAuthentication(final FileAuthenticationEditForm form) { + copyBeanToBean(getFileAuthentication(form), form, op -> op.exclude("crudMode")); + } + + protected FileAuthentication getFileAuthentication(final FileAuthenticationEditForm form) { + final FileAuthentication fileAuthentication = fileAuthenticationService.getFileAuthentication(createKeyMap(form)); + if (fileAuthentication == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return fileAuthentication; + } + + protected FileAuthentication createFileAuthentication(final FileAuthenticationEditForm form) { + FileAuthentication fileAuthentication; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + fileAuthentication = getFileAuthentication(form); + } else { + fileAuthentication = new FileAuthentication(); + fileAuthentication.setCreatedBy(username); + fileAuthentication.setCreatedTime(currentTime); + } + fileAuthentication.setUpdatedBy(username); + fileAuthentication.setUpdatedTime(currentTime); + copyBeanToBean(form, fileAuthentication, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return fileAuthentication; + } + + protected Map createKeyMap(final FileAuthenticationEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + protected void registerProtocolSchemeItems(final RenderData data) { + final List> itemList = new ArrayList>(); + final Locale locale = LaRequestUtil.getRequest().getLocale(); + itemList.add(createItem(ComponentUtil.getMessageManager().getMessage(locale, "labels.file_authentication_scheme_samba"), + Constants.SAMBA)); + data.register("protocolSchemeItems", itemList); + } + + protected void registerFileConfigItems(final RenderData data) { + final List> itemList = new ArrayList>(); + final List fileConfigList = fileConfigService.getAllFileConfigList(false, false, false, null); + for (final FileConfig fileConfig : fileConfigList) { + itemList.add(createItem(fileConfig.getName(), fileConfig.getId().toString())); + } + data.register("fileConfigItems", itemList); + } + + protected Map createItem(final String label, final String value) { + final Map map = new HashMap(2); + map.put(Constants.ITEM_LABEL, label); + map.put(Constants.ITEM_VALUE, value); + return map; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final FileAuthenticationEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminFileauthentication_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/FileAuthenticationForm.java b/src/main/java/org/codelibs/fess/app/web/admin/fileauthentication/FileAuthenticationEditForm.java similarity index 60% rename from src/main/java/org/codelibs/fess/web/admin/FileAuthenticationForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/fileauthentication/FileAuthenticationEditForm.java index 99b46fe43..e167e1101 100644 --- a/src/main/java/org/codelibs/fess/web/admin/FileAuthenticationForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/fileauthentication/FileAuthenticationEditForm.java @@ -14,78 +14,77 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.fileauthentication; import java.io.Serializable; import java.util.HashMap; import java.util.Map; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class FileAuthenticationForm implements Serializable { +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class FileAuthenticationEditForm implements Serializable { private static final long serialVersionUID = 1L; - @IntegerType + //@IntegerType public String pageNumber; public Map searchParams = new HashMap(); - @IntegerType + //@IntegerType public int crudMode; public String getCurrentPageNumber() { return pageNumber; } - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Maxbytelength(maxbytelength = 100) + //@Maxbytelength(maxbytelength = 100) public String hostname; - @IntRange(min = -1, max = 2147483647) + //@IntRange(min = -1, max = 2147483647) public String port; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String protocolScheme; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 100) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) public String username; - @Maxbytelength(maxbytelength = 100) + //@Maxbytelength(maxbytelength = 100) public String password; - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String parameters; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String fileConfigId; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType public String versionNo; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/fileauthentication/FileAuthenticationSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/fileauthentication/FileAuthenticationSearchForm.java new file mode 100644 index 000000000..a9b9a819c --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/fileauthentication/FileAuthenticationSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.fileauthentication; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class FileAuthenticationSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/fileconfig/AdminFileconfigAction.java b/src/main/java/org/codelibs/fess/app/web/admin/fileconfig/AdminFileconfigAction.java new file mode 100644 index 000000000..f73faa7cd --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/fileconfig/AdminFileconfigAction.java @@ -0,0 +1,312 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.fileconfig; + +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.FileConfigPager; +import org.codelibs.fess.app.service.FileConfigService; +import org.codelibs.fess.app.service.LabelTypeService; +import org.codelibs.fess.app.service.RoleTypeService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.FileConfig; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class AdminFileconfigAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private FileConfigService fileConfigService; + @Resource + private FileConfigPager fileConfigPager; + @Resource + private SystemHelper systemHelper; + @Resource + protected RoleTypeService roleTypeService; + @Resource + protected LabelTypeService labelTypeService; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("fileConfig")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final FileConfigSearchForm form) { + return asHtml(path_AdminFileconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final FileConfigSearchForm form) { + fileConfigPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminFileconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final FileConfigSearchForm form) { + copyBeanToBean(form.searchParams, fileConfigPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminFileconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final FileConfigSearchForm form) { + fileConfigPager.clear(); + return asHtml(path_AdminFileconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final FileConfigSearchForm form) { + return asHtml(path_AdminFileconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final FileConfigSearchForm form) { + data.register("fileConfigItems", fileConfigService.getFileConfigList(fileConfigPager)); // page navi + + // restore from pager + copyBeanToBean(fileConfigPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final FileConfigEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminFileconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final FileConfigEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadFileConfig(form); + return asHtml(path_AdminFileconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final FileConfigEditForm form) { + return asHtml(path_AdminFileconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final FileConfigEditForm form) { + form.crudMode = CrudMode.EDIT; + loadFileConfig(form); + return asHtml(path_AdminFileconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final FileConfigEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadFileConfig(form); + return asHtml(path_AdminFileconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final FileConfigEditForm form) { + form.crudMode = CrudMode.DELETE; + loadFileConfig(form); + return asHtml(path_AdminFileconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final FileConfigEditForm form) { + try { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadFileConfig(form); + return asHtml(path_AdminFileconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } catch (final Exception e) { + e.printStackTrace(); + return asHtml(path_AdminFileconfig_ConfirmJsp); + } + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final FileConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminFileconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final FileConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminFileconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final FileConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + fileConfigService.store(createFileConfig(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final FileConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + fileConfigService.store(createFileConfig(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final FileConfigEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + fileConfigService.delete(getFileConfig(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadFileConfig(final FileConfigEditForm form) { + copyBeanToBean(getFileConfig(form), form, op -> op.exclude("crudMode")); + } + + protected FileConfig getFileConfig(final FileConfigEditForm form) { + final FileConfig fileConfig = fileConfigService.getFileConfig(createKeyMap(form)); + if (fileConfig == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return fileConfig; + } + + protected FileConfig createFileConfig(final FileConfigEditForm form) { + FileConfig fileConfig; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + fileConfig = getFileConfig(form); + } else { + fileConfig = new FileConfig(); + fileConfig.setCreatedBy(username); + fileConfig.setCreatedTime(currentTime); + } + fileConfig.setUpdatedBy(username); + fileConfig.setUpdatedTime(currentTime); + copyBeanToBean(form, fileConfig, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return fileConfig; + } + + protected Map createKeyMap(final FileConfigEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + protected void registerRolesAndLabels(final RenderData data) { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + data.register("labelTypeItems", labelTypeService.getLabelTypeList()); + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final FileConfigEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminFileconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/FileConfigForm.java b/src/main/java/org/codelibs/fess/app/web/admin/fileconfig/FileConfigEditForm.java similarity index 52% rename from src/main/java/org/codelibs/fess/web/admin/FileConfigForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/fileconfig/FileConfigEditForm.java index 020533776..e51588223 100644 --- a/src/main/java/org/codelibs/fess/web/admin/FileConfigForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/fileconfig/FileConfigEditForm.java @@ -14,23 +14,19 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.fileconfig; import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; import org.codelibs.fess.Constants; import org.codelibs.fess.annotation.UriType; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongRange; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class FileConfigForm implements Serializable { +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class FileConfigEditForm implements Serializable { private static final long serialVersionUID = 1L; @@ -38,89 +34,80 @@ public class FileConfigForm implements Serializable { public String[] labelTypeIds; - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType + //@IntegerType public int crudMode; - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 200) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 200) public String name; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") @UriType(protocols = "file:,smb:") - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String paths; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String includedPaths; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String excludedPaths; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String includedDocPaths; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String excludedDocPaths; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String configParameter; - @IntRange(min = 0, max = 2147483647) + //@IntRange(min = 0, max = 2147483647) public String depth; - @LongRange(min = 0, max = 9223372036854775807l) + //@LongRange(min = 0, max = 9223372036854775807l) public String maxAccessCount; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) public String numOfThread; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) public String intervalTime; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) public String boost; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 5) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 5) public String available; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType + //@IntRange(min = 0, max = 2147483647) public String sortOrder; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType public String versionNo; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/fileconfig/FileConfigSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/fileconfig/FileConfigSearchForm.java new file mode 100644 index 000000000..cce7404a8 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/fileconfig/FileConfigSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.fileconfig; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class FileConfigSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/group/AdminGroupAction.java b/src/main/java/org/codelibs/fess/app/web/admin/group/AdminGroupAction.java new file mode 100644 index 000000000..39f155c0b --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/group/AdminGroupAction.java @@ -0,0 +1,271 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.group; + +import java.util.Base64; +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.GroupPager; +import org.codelibs.fess.app.service.GroupService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.Group; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + */ +public class AdminGroupAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private GroupService groupService; + @Resource + private GroupPager groupPager; + @Resource + private SystemHelper systemHelper; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("group")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final GroupSearchForm form) { + return asHtml(path_AdminGroup_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final GroupSearchForm form) { + groupPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminGroup_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final GroupSearchForm form) { + copyBeanToBean(form.searchParams, groupPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminGroup_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final GroupSearchForm form) { + groupPager.clear(); + return asHtml(path_AdminGroup_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final GroupSearchForm form) { + return asHtml(path_AdminGroup_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final GroupSearchForm form) { + data.register("groupItems", groupService.getGroupList(groupPager)); // page navi + + // restore from pager + copyBeanToBean(groupPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final GroupEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminGroup_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final GroupEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadGroup(form); + return asHtml(path_AdminGroup_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final GroupEditForm form) { + return asHtml(path_AdminGroup_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final GroupEditForm form) { + form.crudMode = CrudMode.EDIT; + loadGroup(form); + return asHtml(path_AdminGroup_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final GroupEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadGroup(form); + return asHtml(path_AdminGroup_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final GroupEditForm form) { + form.crudMode = CrudMode.DELETE; + loadGroup(form); + return asHtml(path_AdminGroup_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final GroupEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadGroup(form); + return asHtml(path_AdminGroup_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final GroupEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminGroup_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final GroupEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminGroup_ConfirmJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final GroupEditForm form) { + validate(form, messages -> {}, toEditHtml()); + groupService.store(createGroup(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final GroupEditForm form) { + validate(form, messages -> {}, toEditHtml()); + groupService.store(createGroup(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final GroupEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + groupService.delete(getGroup(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadGroup(final GroupEditForm form) { + copyBeanToBean(getGroup(form), form, op -> op.exclude("crudMode")); + } + + protected Group getGroup(final GroupEditForm form) { + final Group group = groupService.getGroup(createKeyMap(form)); + if (group == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return group; + } + + protected Group createGroup(final GroupEditForm form) { + Group group; + if (form.crudMode == CrudMode.EDIT) { + group = getGroup(form); + } else { + group = new Group(); + } + copyBeanToBean(form, group, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + group.setId(Base64.getEncoder().encodeToString(group.getName().getBytes(Constants.CHARSET_UTF_8))); + return group; + } + + protected Map createKeyMap(final GroupEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final GroupEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminGroup_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/group/GroupEditForm.java b/src/main/java/org/codelibs/fess/app/web/admin/group/GroupEditForm.java new file mode 100644 index 000000000..86f624e73 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/group/GroupEditForm.java @@ -0,0 +1,48 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.group; + +import java.io.Serializable; + +/** + * @author shinsuke + */ +public class GroupEditForm implements Serializable { + + private static final long serialVersionUID = 1L; + + //@IntegerType + public int crudMode; + + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) + public String id; + + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) + public String name; + + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType + public String versionNo; + + public void initialize() { + id = null; + name = null; + versionNo = null; + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/group/GroupSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/group/GroupSearchForm.java new file mode 100644 index 000000000..a56349955 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/group/GroupSearchForm.java @@ -0,0 +1,31 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.group; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author shinsuke + */ +public class GroupSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/joblog/AdminJoblogAction.java b/src/main/java/org/codelibs/fess/app/web/admin/joblog/AdminJoblogAction.java new file mode 100644 index 000000000..e7a00b0ae --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/joblog/AdminJoblogAction.java @@ -0,0 +1,192 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.joblog; + +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.JobLogPager; +import org.codelibs.fess.app.service.JobLogService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.JobLog; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + * @author Shunji Makino + */ +public class AdminJoblogAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private JobLogService jobLogService; + @Resource + private JobLogPager jobLogPager; + @Resource + private SystemHelper systemHelper; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("jobLog")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final JobLogSearchForm form) { + return asHtml(path_AdminJoblog_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final JobLogSearchForm form) { + jobLogPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminJoblog_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final JobLogSearchForm form) { + copyBeanToBean(form.searchParams, jobLogPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminJoblog_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final JobLogSearchForm form) { + jobLogPager.clear(); + return asHtml(path_AdminJoblog_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final JobLogSearchForm form) { + return asHtml(path_AdminJoblog_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final JobLogSearchForm form) { + data.register("jobLogItems", jobLogService.getJobLogList(jobLogPager)); // page navi + + // restore from pager + copyBeanToBean(jobLogPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final JobLogEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadJobLog(form); + return asHtml(path_AdminJoblog_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final JobLogEditForm form) { + form.crudMode = CrudMode.DELETE; + loadJobLog(form); + return asHtml(path_AdminJoblog_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final JobLogEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadJobLog(form); + return asHtml(path_AdminJoblog_ConfirmJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Execute + public HtmlResponse delete(final JobLogEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + jobLogService.delete(getJobLog(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadJobLog(final JobLogEditForm form) { + copyBeanToBean(getJobLog(form), form, op -> op.exclude("crudMode")); + } + + protected JobLog getJobLog(final JobLogEditForm form) { + final JobLog jobLog = jobLogService.getJobLog(createKeyMap(form)); + return jobLog; + } + + protected Map createKeyMap(final JobLogEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final JobLogEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toIndexHtml()); + } + } + + protected VaErrorHook toIndexHtml() { + return () -> { + return asHtml(path_AdminJoblog_IndexJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/JobLogForm.java b/src/main/java/org/codelibs/fess/app/web/admin/joblog/JobLogEditForm.java similarity index 51% rename from src/main/java/org/codelibs/fess/web/admin/JobLogForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/joblog/JobLogEditForm.java index d31e8d2c9..c2e67bad0 100644 --- a/src/main/java/org/codelibs/fess/web/admin/JobLogForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/joblog/JobLogEditForm.java @@ -14,59 +14,46 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.joblog; import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; -import org.codelibs.fess.Constants; -import org.seasar.struts.annotation.DateType; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Required; - -public class JobLogForm implements Serializable { +/** + * @author codelibs + * @author Shunji Makino + */ +public class JobLogEditForm implements Serializable { private static final long serialVersionUID = 1L; - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType + //@IntegerType public int crudMode; - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") public String jobName; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") public String jobStatus; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") public String target; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") public String scriptType; public String scriptData; public String scriptResult; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @DateType(datePattern = Constants.DEFAULT_DATETIME_FORMAT) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@DateType(datePattern = Constants.DEFAULT_DATETIME_FORMAT) public String startTime; - @DateType(datePattern = Constants.DEFAULT_DATETIME_FORMAT) + //@DateType(datePattern = Constants.DEFAULT_DATETIME_FORMAT) public String endTime; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/joblog/JobLogSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/joblog/JobLogSearchForm.java new file mode 100644 index 000000000..ece6de24b --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/joblog/JobLogSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.joblog; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Shunji Makino + */ +public class JobLogSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/keymatch/AdminKeymatchAction.java b/src/main/java/org/codelibs/fess/app/web/admin/keymatch/AdminKeymatchAction.java new file mode 100644 index 000000000..9369d6e5b --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/keymatch/AdminKeymatchAction.java @@ -0,0 +1,280 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.keymatch; + +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.KeyMatchPager; +import org.codelibs.fess.app.service.KeyMatchService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.KeyMatch; +import org.codelibs.fess.helper.SystemHelper; +import org.codelibs.fess.util.ComponentUtil; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author codelibs + * @author jflute + */ +public class AdminKeymatchAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private KeyMatchService keyMatchService; + @Resource + private KeyMatchPager keyMatchPager; + @Resource + private SystemHelper systemHelper; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("keyMatch")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final KeyMatchSearchForm form) { + return asHtml(path_AdminKeymatch_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final KeyMatchSearchForm form) { + keyMatchPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminKeymatch_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final KeyMatchSearchForm form) { + copyBeanToBean(form.searchParams, keyMatchPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminKeymatch_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final KeyMatchSearchForm form) { + keyMatchPager.clear(); + return asHtml(path_AdminKeymatch_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final KeyMatchSearchForm form) { + return asHtml(path_AdminKeymatch_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final KeyMatchSearchForm form) { + data.register("keyMatchItems", keyMatchService.getKeyMatchList(keyMatchPager)); // page navi + + // restore from pager + copyBeanToBean(keyMatchPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final KeyMatchEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminKeymatch_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final KeyMatchEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadKeyMatch(form); + return asHtml(path_AdminKeymatch_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final KeyMatchEditForm form) { + return asHtml(path_AdminKeymatch_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final KeyMatchEditForm form) { + form.crudMode = CrudMode.EDIT; + loadKeyMatch(form); + return asHtml(path_AdminKeymatch_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final KeyMatchEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadKeyMatch(form); + return asHtml(path_AdminKeymatch_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final KeyMatchEditForm form) { + form.crudMode = CrudMode.DELETE; + loadKeyMatch(form); + return asHtml(path_AdminKeymatch_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final KeyMatchEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadKeyMatch(form); + return asHtml(path_AdminKeymatch_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final KeyMatchEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminKeymatch_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final KeyMatchEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminKeymatch_ConfirmJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final KeyMatchEditForm form) { + validate(form, messages -> {}, toEditHtml()); + keyMatchService.store(createKeyMatch(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + ComponentUtil.getKeyMatchHelper().update(); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final KeyMatchEditForm form) { + validate(form, messages -> {}, toEditHtml()); + keyMatchService.store(createKeyMatch(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + ComponentUtil.getKeyMatchHelper().update(); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final KeyMatchEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + keyMatchService.delete(getKeyMatch(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + ComponentUtil.getKeyMatchHelper().update(); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadKeyMatch(final KeyMatchEditForm form) { + copyBeanToBean(getKeyMatch(form), form, op -> op.exclude("crudMode")); + } + + protected KeyMatch getKeyMatch(final KeyMatchEditForm form) { + final KeyMatch keyMatch = keyMatchService.getKeyMatch(createKeyMap(form)); + if (keyMatch == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return keyMatch; + } + + protected KeyMatch createKeyMatch(final KeyMatchEditForm form) { + KeyMatch keyMatch; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + keyMatch = getKeyMatch(form); + } else { + keyMatch = new KeyMatch(); + keyMatch.setCreatedBy(username); + keyMatch.setCreatedTime(currentTime); + } + keyMatch.setUpdatedBy(username); + keyMatch.setUpdatedTime(currentTime); + copyBeanToBean(form, keyMatch, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return keyMatch; + } + + protected Map createKeyMap(final KeyMatchEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final KeyMatchEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminKeymatch_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/KeyMatchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/keymatch/KeyMatchEditForm.java similarity index 50% rename from src/main/java/org/codelibs/fess/web/admin/KeyMatchForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/keymatch/KeyMatchEditForm.java index d4507b433..aaa88447c 100644 --- a/src/main/java/org/codelibs/fess/web/admin/KeyMatchForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/keymatch/KeyMatchEditForm.java @@ -14,71 +14,59 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.keymatch; import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class KeyMatchForm implements Serializable { +/** + * @author codelibs + * @author jflute + */ +public class KeyMatchEditForm implements Serializable { private static final long serialVersionUID = 1L; - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType + //@IntegerType public int crudMode; - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 100) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) public String term; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 4000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 4000) public String query; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @IntegerType - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@IntegerType + //@IntRange(min = 0, max = 2147483647) public String maxSize; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") public String boost; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType public String versionNo; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/keymatch/KeyMatchSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/keymatch/KeyMatchSearchForm.java new file mode 100644 index 000000000..f28db079d --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/keymatch/KeyMatchSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.keymatch; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author jflute + */ +public class KeyMatchSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/labeltype/AdminLabeltypeAction.java b/src/main/java/org/codelibs/fess/app/web/admin/labeltype/AdminLabeltypeAction.java new file mode 100644 index 000000000..751211441 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/labeltype/AdminLabeltypeAction.java @@ -0,0 +1,297 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.labeltype; + +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.LabelTypePager; +import org.codelibs.fess.app.service.LabelTypeService; +import org.codelibs.fess.app.service.RoleTypeService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.LabelType; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + * @author Shunji Makino + */ +public class AdminLabeltypeAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private LabelTypeService labelTypeService; + @Resource + private LabelTypePager labelTypePager; + @Resource + private SystemHelper systemHelper; + @Resource + protected RoleTypeService roleTypeService; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("labelType")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final LabelTypeSearchForm form) { + return asHtml(path_AdminLabeltype_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final LabelTypeSearchForm form) { + labelTypePager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminLabeltype_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final LabelTypeSearchForm form) { + copyBeanToBean(form.searchParams, labelTypePager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminLabeltype_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final LabelTypeSearchForm form) { + labelTypePager.clear(); + return asHtml(path_AdminLabeltype_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final LabelTypeSearchForm form) { + return asHtml(path_AdminLabeltype_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final LabelTypeSearchForm form) { + data.register("labelTypeItems", labelTypeService.getLabelTypeList(labelTypePager)); // page navi + + // restore from pager + copyBeanToBean(labelTypePager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final LabelTypeEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminLabeltype_EditJsp).renderWith(data -> { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final LabelTypeEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadLabelType(form); + return asHtml(path_AdminLabeltype_EditJsp).renderWith(data -> { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final LabelTypeEditForm form) { + return asHtml(path_AdminLabeltype_EditJsp).renderWith(data -> { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final LabelTypeEditForm form) { + form.crudMode = CrudMode.EDIT; + loadLabelType(form); + return asHtml(path_AdminLabeltype_EditJsp).renderWith(data -> { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final LabelTypeEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadLabelType(form); + return asHtml(path_AdminLabeltype_ConfirmJsp).renderWith(data -> { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final LabelTypeEditForm form) { + form.crudMode = CrudMode.DELETE; + loadLabelType(form); + return asHtml(path_AdminLabeltype_ConfirmJsp).renderWith(data -> { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + }); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final LabelTypeEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadLabelType(form); + return asHtml(path_AdminLabeltype_ConfirmJsp).renderWith(data -> { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final LabelTypeEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminLabeltype_ConfirmJsp).renderWith(data -> { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final LabelTypeEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminLabeltype_ConfirmJsp).renderWith(data -> { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + }); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final LabelTypeEditForm form) { + validate(form, messages -> {}, toEditHtml()); + labelTypeService.store(createLabelType(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final LabelTypeEditForm form) { + validate(form, messages -> {}, toEditHtml()); + labelTypeService.store(createLabelType(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final LabelTypeEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + labelTypeService.delete(getLabelType(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadLabelType(final LabelTypeEditForm form) { + copyBeanToBean(getLabelType(form), form, op -> op.exclude("crudMode")); + } + + protected LabelType getLabelType(final LabelTypeEditForm form) { + final LabelType labelType = labelTypeService.getLabelType(createKeyMap(form)); + if (labelType == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return labelType; + } + + protected LabelType createLabelType(final LabelTypeEditForm form) { + LabelType labelType; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + labelType = getLabelType(form); + } else { + labelType = new LabelType(); + labelType.setCreatedBy(username); + labelType.setCreatedTime(currentTime); + } + labelType.setUpdatedBy(username); + labelType.setUpdatedTime(currentTime); + copyBeanToBean(form, labelType, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return labelType; + } + + protected Map createKeyMap(final LabelTypeEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final LabelTypeEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminLabeltype_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/labeltype/LabelTypeEditForm.java b/src/main/java/org/codelibs/fess/app/web/admin/labeltype/LabelTypeEditForm.java new file mode 100644 index 000000000..583c99605 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/labeltype/LabelTypeEditForm.java @@ -0,0 +1,91 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.labeltype; + +import java.io.Serializable; + +import org.codelibs.fess.util.ComponentUtil; + +/** + * @author codelibs + * @author Shunji Makino + */ +public class LabelTypeEditForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public String[] roleTypeIds; + + //@IntegerType + public int crudMode; + + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) + public String id; + + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) + public String name; + + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 20) + //@Mask(mask = "^[a-zA-Z0-9_-]+$", msg = @Msg(key = "errors.alphaDigitOnly")) + public String value; + + //@Maxbytelength(maxbytelength = 4000) + public String includedPaths; + + //@Maxbytelength(maxbytelength = 4000) + public String excludedPaths; + + //@Required(target = "confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) + public String sortOrder; + + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) + public String createdBy; + + //@Required(target = "confirmfromupdate,update,delete") + //@LongType + public String createdTime; + + //@Maxbytelength(maxbytelength = 255) + public String updatedBy; + + //@LongType + public String updatedTime; + + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType + public String versionNo; + + public void initialize() { + id = null; + name = null; + value = null; + includedPaths = null; + excludedPaths = null; + sortOrder = null; + createdBy = "system"; + createdTime = Long.toString(ComponentUtil.getSystemHelper().getCurrentTimeAsLong()); + updatedBy = null; + updatedTime = null; + versionNo = null; + sortOrder = "0"; + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/labeltype/LabelTypeSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/labeltype/LabelTypeSearchForm.java new file mode 100644 index 000000000..c8db86a60 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/labeltype/LabelTypeSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.labeltype; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Shunji Makino + */ +public class LabelTypeSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/log/AdminLogAction.java b/src/main/java/org/codelibs/fess/app/web/admin/log/AdminLogAction.java new file mode 100644 index 000000000..161588f58 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/log/AdminLogAction.java @@ -0,0 +1,89 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.log; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class AdminLogAction extends FessAdminAction { + + @Resource + private SystemHelper systemHelper; + + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("log")); + } + + @Execute + public HtmlResponse index(final LogForm form) { + return asHtml(path_AdminLog_IndexJsp).renderWith(data -> { + data.register("logFileItems", getLogFileItems()); + }); + } + + //@Execute(validator = true, input = "index", urlPattern = "download/{logFileName}") + public HtmlResponse download(final LogForm form) { + // TODO + return redirect(getClass()); + /* + final String logFilePath = ComponentUtil.getSystemHelper().getLogFilePath(); + if (StringUtil.isNotBlank(logFilePath)) { + final File file = new File(logFilePath); + final File parentDir = file.getParentFile(); + String fileName; + try { + fileName = new String(Base64.decodeBase64(logForm.logFileName.getBytes(Constants.UTF_8)), Constants.UTF_8); + } catch (final UnsupportedEncodingException e1) { + fileName = + new String(Base64.decodeBase64(logForm.logFileName.getBytes(Charset.defaultCharset())), Charset.defaultCharset()); + } + final File logFile = new File(parentDir, fileName); + if (logFile.isFile()) { + try { + LaResponseUtil.download(fileName, new FileInputStream(logFile)); + return null; + } catch (final FileNotFoundException e) { + logger.warn("Could not find " + logFile.getAbsolutePath(), e); + } + } + } + throw new SSCActionMessagesException("errors.could_not_find_log_file", new Object[] { logForm.logFileName }); + */ + } + + public List> getLogFileItems() { + // TODO + final List> logFileItems = new ArrayList>(); + return logFileItems; + } + +} diff --git a/src/main/java/org/codelibs/fess/web/admin/LogForm.java b/src/main/java/org/codelibs/fess/app/web/admin/log/LogForm.java similarity index 88% rename from src/main/java/org/codelibs/fess/web/admin/LogForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/log/LogForm.java index dd05f17be..d1045c5ee 100644 --- a/src/main/java/org/codelibs/fess/web/admin/LogForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/log/LogForm.java @@ -14,10 +14,14 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.log; import java.io.Serializable; +/** + * @author codelibs + * @author Keiichi Watanabe + */ public class LogForm implements Serializable { private static final long serialVersionUID = 1L; diff --git a/src/main/java/org/codelibs/fess/app/web/admin/overlappinghost/AdminOverlappinghostAction.java b/src/main/java/org/codelibs/fess/app/web/admin/overlappinghost/AdminOverlappinghostAction.java new file mode 100644 index 000000000..4b48748b3 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/overlappinghost/AdminOverlappinghostAction.java @@ -0,0 +1,276 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.overlappinghost; + +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.OverlappingHostPager; +import org.codelibs.fess.app.service.OverlappingHostService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.OverlappingHost; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class AdminOverlappinghostAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private OverlappingHostService overlappingHostService; + @Resource + private OverlappingHostPager overlappingHostPager; + @Resource + private SystemHelper systemHelper; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("overlappingHost")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final OverlappingHostSearchForm form) { + return asHtml(path_AdminOverlappinghost_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final OverlappingHostSearchForm form) { + overlappingHostPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminOverlappinghost_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final OverlappingHostSearchForm form) { + copyBeanToBean(form.searchParams, overlappingHostPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminOverlappinghost_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final OverlappingHostSearchForm form) { + overlappingHostPager.clear(); + return asHtml(path_AdminOverlappinghost_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final OverlappingHostSearchForm form) { + return asHtml(path_AdminOverlappinghost_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final OverlappingHostSearchForm form) { + data.register("overlappingHostItems", overlappingHostService.getOverlappingHostList(overlappingHostPager)); // page navi + + // restore from pager + copyBeanToBean(overlappingHostPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final OverlappingHostEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminOverlappinghost_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final OverlappingHostEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadOverlappingHost(form); + return asHtml(path_AdminOverlappinghost_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final OverlappingHostEditForm form) { + return asHtml(path_AdminOverlappinghost_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final OverlappingHostEditForm form) { + form.crudMode = CrudMode.EDIT; + loadOverlappingHost(form); + return asHtml(path_AdminOverlappinghost_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final OverlappingHostEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadOverlappingHost(form); + return asHtml(path_AdminOverlappinghost_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final OverlappingHostEditForm form) { + form.crudMode = CrudMode.DELETE; + loadOverlappingHost(form); + return asHtml(path_AdminOverlappinghost_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final OverlappingHostEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadOverlappingHost(form); + return asHtml(path_AdminOverlappinghost_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final OverlappingHostEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminOverlappinghost_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final OverlappingHostEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminOverlappinghost_ConfirmJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final OverlappingHostEditForm form) { + validate(form, messages -> {}, toEditHtml()); + overlappingHostService.store(createOverlappingHost(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final OverlappingHostEditForm form) { + validate(form, messages -> {}, toEditHtml()); + overlappingHostService.store(createOverlappingHost(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final OverlappingHostEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + overlappingHostService.delete(getOverlappingHost(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadOverlappingHost(final OverlappingHostEditForm form) { + copyBeanToBean(getOverlappingHost(form), form, op -> op.exclude("crudMode")); + } + + protected OverlappingHost getOverlappingHost(final OverlappingHostEditForm form) { + final OverlappingHost overlappingHost = overlappingHostService.getOverlappingHost(createKeyMap(form)); + if (overlappingHost == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return overlappingHost; + } + + protected OverlappingHost createOverlappingHost(final OverlappingHostEditForm form) { + OverlappingHost overlappingHost; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + overlappingHost = getOverlappingHost(form); + } else { + overlappingHost = new OverlappingHost(); + overlappingHost.setCreatedBy(username); + overlappingHost.setCreatedTime(currentTime); + } + overlappingHost.setUpdatedBy(username); + overlappingHost.setUpdatedTime(currentTime); + copyBeanToBean(form, overlappingHost, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return overlappingHost; + } + + protected Map createKeyMap(final OverlappingHostEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final OverlappingHostEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminOverlappinghost_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/OverlappingHostForm.java b/src/main/java/org/codelibs/fess/app/web/admin/overlappinghost/OverlappingHostEditForm.java similarity index 51% rename from src/main/java/org/codelibs/fess/web/admin/OverlappingHostForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/overlappinghost/OverlappingHostEditForm.java index a9d1808f0..edacf072b 100644 --- a/src/main/java/org/codelibs/fess/web/admin/OverlappingHostForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/overlappinghost/OverlappingHostEditForm.java @@ -14,67 +14,55 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.overlappinghost; import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class OverlappingHostForm implements Serializable { +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class OverlappingHostEditForm implements Serializable { private static final long serialVersionUID = 1L; - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType + //@IntegerType public int crudMode; - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String regularName; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String overlappingName; - @Required(target = "confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) public String sortOrder; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType public String versionNo; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/overlappinghost/OverlappingHostSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/overlappinghost/OverlappingHostSearchForm.java new file mode 100644 index 000000000..d9eaf267b --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/overlappinghost/OverlappingHostSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.overlappinghost; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class OverlappingHostSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/pathmapping/AdminPathmappingAction.java b/src/main/java/org/codelibs/fess/app/web/admin/pathmapping/AdminPathmappingAction.java new file mode 100644 index 000000000..01d33cc10 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/pathmapping/AdminPathmappingAction.java @@ -0,0 +1,276 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.pathmapping; + +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.PathMappingPager; +import org.codelibs.fess.app.service.PathMappingService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.PathMapping; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + * @author Shunji Makino + */ +public class AdminPathmappingAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private PathMappingService pathMappingService; + @Resource + private PathMappingPager pathMappingPager; + @Resource + private SystemHelper systemHelper; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("pathMapping")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final PathMappingSearchForm form) { + return asHtml(path_AdminPathmapping_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final PathMappingSearchForm form) { + pathMappingPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminPathmapping_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final PathMappingSearchForm form) { + copyBeanToBean(form.searchParams, pathMappingPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminPathmapping_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final PathMappingSearchForm form) { + pathMappingPager.clear(); + return asHtml(path_AdminPathmapping_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final PathMappingSearchForm form) { + return asHtml(path_AdminPathmapping_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final PathMappingSearchForm form) { + data.register("pathMappingItems", pathMappingService.getPathMappingList(pathMappingPager)); // page navi + + // restore from pager + copyBeanToBean(pathMappingPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final PathMappingEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminPathmapping_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final PathMappingEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadPathMapping(form); + return asHtml(path_AdminPathmapping_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final PathMappingEditForm form) { + return asHtml(path_AdminPathmapping_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final PathMappingEditForm form) { + form.crudMode = CrudMode.EDIT; + loadPathMapping(form); + return asHtml(path_AdminPathmapping_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final PathMappingEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadPathMapping(form); + return asHtml(path_AdminPathmapping_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final PathMappingEditForm form) { + form.crudMode = CrudMode.DELETE; + loadPathMapping(form); + return asHtml(path_AdminPathmapping_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final PathMappingEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadPathMapping(form); + return asHtml(path_AdminPathmapping_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final PathMappingEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminPathmapping_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final PathMappingEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminPathmapping_ConfirmJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final PathMappingEditForm form) { + validate(form, messages -> {}, toEditHtml()); + pathMappingService.store(createPathMapping(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final PathMappingEditForm form) { + validate(form, messages -> {}, toEditHtml()); + pathMappingService.store(createPathMapping(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final PathMappingEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + pathMappingService.delete(getPathMapping(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadPathMapping(final PathMappingEditForm form) { + copyBeanToBean(getPathMapping(form), form, op -> op.exclude("crudMode")); + } + + protected PathMapping getPathMapping(final PathMappingEditForm form) { + final PathMapping pathMapping = pathMappingService.getPathMapping(createKeyMap(form)); + if (pathMapping == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return pathMapping; + } + + protected PathMapping createPathMapping(final PathMappingEditForm form) { + PathMapping pathMapping; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + pathMapping = getPathMapping(form); + } else { + pathMapping = new PathMapping(); + pathMapping.setCreatedBy(username); + pathMapping.setCreatedTime(currentTime); + } + pathMapping.setUpdatedBy(username); + pathMapping.setUpdatedTime(currentTime); + copyBeanToBean(form, pathMapping, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return pathMapping; + } + + protected Map createKeyMap(final PathMappingEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final PathMappingEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminPathmapping_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/PathMappingForm.java b/src/main/java/org/codelibs/fess/app/web/admin/pathmapping/PathMappingEditForm.java similarity index 50% rename from src/main/java/org/codelibs/fess/web/admin/PathMappingForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/pathmapping/PathMappingEditForm.java index 5ea009dcb..2e0423eda 100644 --- a/src/main/java/org/codelibs/fess/web/admin/PathMappingForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/pathmapping/PathMappingEditForm.java @@ -14,70 +14,58 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.pathmapping; import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class PathMappingForm implements Serializable { +/** + * @author codelibs + * @author Shunji Makino + */ +public class PathMappingEditForm implements Serializable { private static final long serialVersionUID = 1L; - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType + //@IntegerType public int crudMode; - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String regex; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String replacement; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") public String processType; - @Required(target = "confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) public String sortOrder; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String versionNo; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/pathmapping/PathMappingSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/pathmapping/PathMappingSearchForm.java new file mode 100644 index 000000000..421422303 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/pathmapping/PathMappingSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.pathmapping; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Shunji Makino + */ +public class PathMappingSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/requestheader/AdminRequestheaderAction.java b/src/main/java/org/codelibs/fess/app/web/admin/requestheader/AdminRequestheaderAction.java new file mode 100644 index 000000000..67c439961 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/requestheader/AdminRequestheaderAction.java @@ -0,0 +1,334 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.requestheader; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Locale; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.RequestHeaderPager; +import org.codelibs.fess.app.service.RequestHeaderService; +import org.codelibs.fess.app.service.WebConfigService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.RequestHeader; +import org.codelibs.fess.es.exentity.WebConfig; +import org.codelibs.fess.helper.SystemHelper; +import org.codelibs.fess.util.ComponentUtil; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.util.LaRequestUtil; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + * @author Shunji Makino + */ +public class AdminRequestheaderAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private RequestHeaderService requestHeaderService; + @Resource + private RequestHeaderPager requestHeaderPager; + @Resource + private SystemHelper systemHelper; + @Resource + protected WebConfigService webConfigService; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("requestHeader")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final RequestHeaderSearchForm form) { + return asHtml(path_AdminRequestheader_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final RequestHeaderSearchForm form) { + requestHeaderPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminRequestheader_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final RequestHeaderSearchForm form) { + copyBeanToBean(form.searchParams, requestHeaderPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminRequestheader_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final RequestHeaderSearchForm form) { + requestHeaderPager.clear(); + return asHtml(path_AdminRequestheader_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final RequestHeaderSearchForm form) { + return asHtml(path_AdminRequestheader_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final RequestHeaderSearchForm form) { + data.register("requestHeaderItems", requestHeaderService.getRequestHeaderList(requestHeaderPager)); // page navi + data.register("displayCreateLink", !webConfigService.getAllWebConfigList(false, false, false, null).isEmpty()); + + // restore from pager + copyBeanToBean(requestHeaderPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final RequestHeaderEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminRequestheader_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final RequestHeaderEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadRequestHeader(form); + return asHtml(path_AdminRequestheader_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final RequestHeaderEditForm form) { + return asHtml(path_AdminRequestheader_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final RequestHeaderEditForm form) { + form.crudMode = CrudMode.EDIT; + loadRequestHeader(form); + return asHtml(path_AdminRequestheader_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final RequestHeaderEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadRequestHeader(form); + return asHtml(path_AdminRequestheader_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final RequestHeaderEditForm form) { + form.crudMode = CrudMode.DELETE; + loadRequestHeader(form); + return asHtml(path_AdminRequestheader_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final RequestHeaderEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadRequestHeader(form); + return asHtml(path_AdminRequestheader_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final RequestHeaderEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminRequestheader_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final RequestHeaderEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminRequestheader_ConfirmJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final RequestHeaderEditForm form) { + validate(form, messages -> {}, toEditHtml()); + requestHeaderService.store(createRequestHeader(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final RequestHeaderEditForm form) { + validate(form, messages -> {}, toEditHtml()); + requestHeaderService.store(createRequestHeader(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final RequestHeaderEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + requestHeaderService.delete(getRequestHeader(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadRequestHeader(final RequestHeaderEditForm form) { + copyBeanToBean(getRequestHeader(form), form, op -> op.exclude("crudMode")); + } + + protected RequestHeader getRequestHeader(final RequestHeaderEditForm form) { + final RequestHeader requestHeader = requestHeaderService.getRequestHeader(createKeyMap(form)); + if (requestHeader == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return requestHeader; + } + + protected RequestHeader createRequestHeader(final RequestHeaderEditForm form) { + RequestHeader requestHeader; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + requestHeader = getRequestHeader(form); + } else { + requestHeader = new RequestHeader(); + requestHeader.setCreatedBy(username); + requestHeader.setCreatedTime(currentTime); + } + requestHeader.setUpdatedBy(username); + requestHeader.setUpdatedTime(currentTime); + copyBeanToBean(form, requestHeader, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return requestHeader; + } + + protected Map createKeyMap(final RequestHeaderEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + protected void registerProtocolSchemeItems(final RenderData data) { + final List> itemList = new ArrayList>(); + final Locale locale = LaRequestUtil.getRequest().getLocale(); + itemList.add(createItem(ComponentUtil.getMessageManager().getMessage(locale, "labels.web_authentication_scheme_basic"), + Constants.BASIC)); + itemList.add(createItem(ComponentUtil.getMessageManager().getMessage(locale, "labels.web_authentication_scheme_digest"), + Constants.DIGEST)); + itemList.add(createItem(ComponentUtil.getMessageManager().getMessage(locale, "labels.web_authentication_scheme_ntlm"), + Constants.NTLM)); + data.register("protocolSchemeItems", itemList); + } + + protected void registerWebConfigItems(final RenderData data) { + final List> itemList = new ArrayList>(); + final List webConfigList = webConfigService.getAllWebConfigList(false, false, false, null); + for (final WebConfig webConfig : webConfigList) { + itemList.add(createItem(webConfig.getName(), webConfig.getId().toString())); + } + data.register("webConfigItems", itemList); + } + + protected Map createItem(final String label, final String value) { + final Map map = new HashMap(2); + map.put(Constants.ITEM_LABEL, label); + map.put(Constants.ITEM_VALUE, value); + return map; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final RequestHeaderEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminRequestheader_EditJsp).renderWith(data -> { + registerWebConfigItems(data); + }); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/RequestHeaderForm.java b/src/main/java/org/codelibs/fess/app/web/admin/requestheader/RequestHeaderEditForm.java similarity index 50% rename from src/main/java/org/codelibs/fess/web/admin/RequestHeaderForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/requestheader/RequestHeaderEditForm.java index cacbea4a3..ed47bba59 100644 --- a/src/main/java/org/codelibs/fess/web/admin/RequestHeaderForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/requestheader/RequestHeaderEditForm.java @@ -14,66 +14,55 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.requestheader; import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class RequestHeaderForm implements Serializable { +/** + * @author codelibs + * @author Shunji Makino + */ +public class RequestHeaderEditForm implements Serializable { private static final long serialVersionUID = 1L; - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType + //@IntegerType public int crudMode; - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 100) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) public String name; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String value; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String webConfigId; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType public String versionNo; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/requestheader/RequestHeaderSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/requestheader/RequestHeaderSearchForm.java new file mode 100644 index 000000000..ea8418652 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/requestheader/RequestHeaderSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.requestheader; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Shunji Makino + */ +public class RequestHeaderSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/role/AdminRoleAction.java b/src/main/java/org/codelibs/fess/app/web/admin/role/AdminRoleAction.java new file mode 100644 index 000000000..ea8d52548 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/role/AdminRoleAction.java @@ -0,0 +1,271 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.role; + +import java.util.Base64; +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.RolePager; +import org.codelibs.fess.app.service.RoleService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.Role; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + */ +public class AdminRoleAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private RoleService roleService; + @Resource + private RolePager rolePager; + @Resource + private SystemHelper systemHelper; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("role")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final RoleSearchForm form) { + return asHtml(path_AdminRole_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final RoleSearchForm form) { + rolePager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminRole_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final RoleSearchForm form) { + copyBeanToBean(form.searchParams, rolePager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminRole_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final RoleSearchForm form) { + rolePager.clear(); + return asHtml(path_AdminRole_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final RoleSearchForm form) { + return asHtml(path_AdminRole_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final RoleSearchForm form) { + data.register("roleItems", roleService.getRoleList(rolePager)); // page navi + + // restore from pager + copyBeanToBean(rolePager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final RoleEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminRole_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final RoleEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadRole(form); + return asHtml(path_AdminRole_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final RoleEditForm form) { + return asHtml(path_AdminRole_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final RoleEditForm form) { + form.crudMode = CrudMode.EDIT; + loadRole(form); + return asHtml(path_AdminRole_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final RoleEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadRole(form); + return asHtml(path_AdminRole_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final RoleEditForm form) { + form.crudMode = CrudMode.DELETE; + loadRole(form); + return asHtml(path_AdminRole_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final RoleEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadRole(form); + return asHtml(path_AdminRole_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final RoleEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminRole_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final RoleEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminRole_ConfirmJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final RoleEditForm form) { + validate(form, messages -> {}, toEditHtml()); + roleService.store(createRole(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final RoleEditForm form) { + validate(form, messages -> {}, toEditHtml()); + roleService.store(createRole(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final RoleEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + roleService.delete(getRole(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadRole(final RoleEditForm form) { + copyBeanToBean(getRole(form), form, op -> op.exclude("crudMode")); + } + + protected Role getRole(final RoleEditForm form) { + final Role role = roleService.getRole(createKeyMap(form)); + if (role == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return role; + } + + protected Role createRole(final RoleEditForm form) { + Role role; + if (form.crudMode == CrudMode.EDIT) { + role = getRole(form); + } else { + role = new Role(); + } + copyBeanToBean(form, role, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + role.setId(Base64.getEncoder().encodeToString(role.getName().getBytes(Constants.CHARSET_UTF_8))); + return role; + } + + protected Map createKeyMap(final RoleEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final RoleEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminRole_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/role/RoleEditForm.java b/src/main/java/org/codelibs/fess/app/web/admin/role/RoleEditForm.java new file mode 100644 index 000000000..45f5c61e7 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/role/RoleEditForm.java @@ -0,0 +1,48 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.role; + +import java.io.Serializable; + +/** + * @author shinsuke + */ +public class RoleEditForm implements Serializable { + + private static final long serialVersionUID = 1L; + + //@IntegerType + public int crudMode; + + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) + public String id; + + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) + public String name; + + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType + public String versionNo; + + public void initialize() { + id = null; + name = null; + versionNo = null; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/DataForm.java b/src/main/java/org/codelibs/fess/app/web/admin/role/RoleSearchForm.java similarity index 73% rename from src/main/java/org/codelibs/fess/web/admin/DataForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/role/RoleSearchForm.java index 2f7536ba3..98347c0b3 100644 --- a/src/main/java/org/codelibs/fess/web/admin/DataForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/role/RoleSearchForm.java @@ -14,19 +14,18 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.role; import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; -import org.apache.struts.upload.FormFile; -import org.seasar.struts.annotation.Required; - -public class DataForm implements Serializable { +/** + * @author shinsuke + */ +public class RoleSearchForm implements Serializable { private static final long serialVersionUID = 1L; - @Required - public FormFile uploadedFile; - - public String overwrite; + public Map searchParams = new HashMap(); } diff --git a/src/main/java/org/codelibs/fess/app/web/admin/roletype/AdminRoletypeAction.java b/src/main/java/org/codelibs/fess/app/web/admin/roletype/AdminRoletypeAction.java new file mode 100644 index 000000000..150c1e213 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/roletype/AdminRoletypeAction.java @@ -0,0 +1,275 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.roletype; + +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.RoleTypePager; +import org.codelibs.fess.app.service.RoleTypeService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.RoleType; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class AdminRoletypeAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private RoleTypeService roleTypeService; + @Resource + private RoleTypePager roleTypePager; + @Resource + private SystemHelper systemHelper; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("roleType")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final RoleTypeSearchForm form) { + return asHtml(path_AdminRoletype_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final RoleTypeSearchForm form) { + roleTypePager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminRoletype_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final RoleTypeSearchForm form) { + copyBeanToBean(form.searchParams, roleTypePager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminRoletype_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final RoleTypeSearchForm form) { + roleTypePager.clear(); + return asHtml(path_AdminRoletype_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final RoleTypeSearchForm form) { + return asHtml(path_AdminRoletype_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final RoleTypeSearchForm form) { + data.register("roleTypeItems", roleTypeService.getRoleTypeList(roleTypePager)); // page navi + + // restore from pager + copyBeanToBean(roleTypePager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final RoleTypeEditForm form) { + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminRoletype_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final RoleTypeEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadRoleType(form); + return asHtml(path_AdminRoletype_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final RoleTypeEditForm form) { + return asHtml(path_AdminRoletype_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final RoleTypeEditForm form) { + form.crudMode = CrudMode.EDIT; + loadRoleType(form); + return asHtml(path_AdminRoletype_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final RoleTypeEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadRoleType(form); + return asHtml(path_AdminRoletype_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final RoleTypeEditForm form) { + form.crudMode = CrudMode.DELETE; + loadRoleType(form); + return asHtml(path_AdminRoletype_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final RoleTypeEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadRoleType(form); + return asHtml(path_AdminRoletype_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final RoleTypeEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminRoletype_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final RoleTypeEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminRoletype_ConfirmJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final RoleTypeEditForm form) { + validate(form, messages -> {}, toEditHtml()); + roleTypeService.store(createRoleType(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final RoleTypeEditForm form) { + validate(form, messages -> {}, toEditHtml()); + roleTypeService.store(createRoleType(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final RoleTypeEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + roleTypeService.delete(getRoleType(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadRoleType(final RoleTypeEditForm form) { + copyBeanToBean(getRoleType(form), form, op -> op.exclude("crudMode")); + } + + protected RoleType getRoleType(final RoleTypeEditForm form) { + final RoleType roleType = roleTypeService.getRoleType(createKeyMap(form)); + if (roleType == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return roleType; + } + + protected RoleType createRoleType(final RoleTypeEditForm form) { + RoleType roleType; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + roleType = getRoleType(form); + } else { + roleType = new RoleType(); + roleType.setCreatedBy(username); + roleType.setCreatedTime(currentTime); + } + roleType.setUpdatedBy(username); + roleType.setUpdatedTime(currentTime); + copyBeanToBean(form, roleType, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return roleType; + } + + protected Map createKeyMap(final RoleTypeEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final RoleTypeEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminRoletype_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/roletype/RoleTypeEditForm.java b/src/main/java/org/codelibs/fess/app/web/admin/roletype/RoleTypeEditForm.java new file mode 100644 index 000000000..96a5b5283 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/roletype/RoleTypeEditForm.java @@ -0,0 +1,81 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.roletype; + +import java.io.Serializable; + +import org.codelibs.fess.util.ComponentUtil; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class RoleTypeEditForm implements Serializable { + + private static final long serialVersionUID = 1L; + + //@IntegerType + public int crudMode; + + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) + public String id; + + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) + public String name; + + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 20) + //@Mask(mask = "^[a-zA-Z0-9_-| ]+$", msg = @Msg(key = "errors.alphaDigitSpaceOnly")) + public String value; + + //@Required(target = "confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) + public String sortOrder; + + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) + public String createdBy; + + //@Required(target = "confirmfromupdate,update,delete") + //@LongType + public String createdTime; + + //@Maxbytelength(maxbytelength = 255) + public String updatedBy; + + //@LongType + public String updatedTime; + + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType + public String versionNo; + + public void initialize() { + id = null; + name = null; + value = null; + sortOrder = null; + createdBy = "system"; + createdTime = Long.toString(ComponentUtil.getSystemHelper().getCurrentTimeAsLong()); + updatedBy = null; + updatedTime = null; + versionNo = null; + sortOrder = "0"; + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/roletype/RoleTypeSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/roletype/RoleTypeSearchForm.java new file mode 100644 index 000000000..69f9adeec --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/roletype/RoleTypeSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.roletype; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class RoleTypeSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/scheduledjob/AdminScheduledjobAction.java b/src/main/java/org/codelibs/fess/app/web/admin/scheduledjob/AdminScheduledjobAction.java new file mode 100644 index 000000000..f3ed0d714 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/scheduledjob/AdminScheduledjobAction.java @@ -0,0 +1,329 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.scheduledjob; + +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.ScheduledJobPager; +import org.codelibs.fess.app.service.ScheduledJobService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.ScheduledJob; +import org.codelibs.fess.helper.JobHelper; +import org.codelibs.fess.helper.SystemHelper; +import org.codelibs.fess.job.JobExecutor; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + */ +public class AdminScheduledjobAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private ScheduledJobService scheduledJobService; + + @Resource + private ScheduledJobPager scheduledJobPager; + + @Resource + protected SystemHelper systemHelper; + + @Resource + protected JobHelper jobHelper; + + private boolean running = false; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("scheduledJob")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final ScheduledjobSearchForm form) { + return asHtml(path_AdminScheduledjob_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final ScheduledjobSearchForm form) { + scheduledJobPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminScheduledjob_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final ScheduledjobSearchForm form) { + copyBeanToBean(form.searchParams, scheduledJobPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminScheduledjob_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final ScheduledjobSearchForm form) { + scheduledJobPager.clear(); + return asHtml(path_AdminScheduledjob_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final ScheduledjobSearchForm form) { + return asHtml(path_AdminScheduledjob_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final ScheduledjobSearchForm form) { + data.register("scheduledJobItems", scheduledJobService.getScheduledJobList(scheduledJobPager)); // page navi + + // restore from pager + copyBeanToBean(scheduledJobPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final ScheduledjobEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminScheduledjob_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final ScheduledjobEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadScheduledJob(form); + return asHtml(path_AdminScheduledjob_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final ScheduledjobEditForm form) { + return asHtml(path_AdminScheduledjob_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final ScheduledjobEditForm form) { + form.crudMode = CrudMode.EDIT; + loadScheduledJob(form); + return asHtml(path_AdminScheduledjob_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final ScheduledjobEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadScheduledJob(form); + return asHtml(path_AdminScheduledjob_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final ScheduledjobEditForm form) { + form.crudMode = CrudMode.DELETE; + loadScheduledJob(form); + return asHtml(path_AdminScheduledjob_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final ScheduledjobEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadScheduledJob(form); + return asHtml(path_AdminScheduledjob_ConfirmJsp).renderWith(data -> { + data.register("running", running); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final ScheduledjobEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminScheduledjob_ConfirmJsp).renderWith(data -> { + data.register("running", running); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final ScheduledjobEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminScheduledjob_ConfirmJsp).renderWith(data -> { + data.register("running", running); + }); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final ScheduledjobEditForm form) { + validate(form, messages -> {}, toEditHtml()); + scheduledJobService.store(createScheduledJob(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final ScheduledjobEditForm form) { + validate(form, messages -> {}, toEditHtml()); + scheduledJobService.store(createScheduledJob(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final ScheduledjobEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + scheduledJobService.delete(getScheduledJob(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse start(final ScheduledjobEditForm form) { + verifyCrudMode(form, CrudMode.CONFIRM); + final ScheduledJob scheduledJob = getScheduledJob(form); + try { + scheduledJob.start(); + saveInfo(messages -> messages.addSuccessJobStarted(GLOBAL, scheduledJob.getName())); + } catch (final Exception e) { + throwValidationError(messages -> { + messages.addErrorsFailedToStartJob(GLOBAL, scheduledJob.getName()); + }, toEditHtml()); + } + return redirect(getClass()); + } + + @Execute + public HtmlResponse stop(final ScheduledjobEditForm form) { + verifyCrudMode(form, CrudMode.CONFIRM); + final ScheduledJob scheduledJob = getScheduledJob(form); + try { + final JobExecutor jobExecutoer = jobHelper.getJobExecutoer(scheduledJob.getId()); + jobExecutoer.shutdown(); + saveInfo(messages -> messages.addSuccessJobStopped(GLOBAL, scheduledJob.getName())); + } catch (final Exception e) { + throwValidationError(messages -> { + messages.addErrorsFailedToStopJob(GLOBAL, scheduledJob.getName()); + }, toEditHtml()); + } + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadScheduledJob(final ScheduledjobEditForm form) { + final ScheduledJob scheduledJob = getScheduledJob(form); + copyBeanToBean(scheduledJob, form, op -> op.exclude("crudMode")); + form.jobLogging = scheduledJob.isLoggingEnabled() ? Constants.ON : null; + form.crawler = scheduledJob.isCrawlerJob() ? Constants.ON : null; + form.available = scheduledJob.isEnabled() ? Constants.ON : null; + running = scheduledJob.isRunning(); + } + + protected ScheduledJob getScheduledJob(final ScheduledjobEditForm form) { + final ScheduledJob scheduledJob = scheduledJobService.getScheduledJob(createKeyMap(form)); + if (scheduledJob == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return scheduledJob; + } + + protected ScheduledJob createScheduledJob(final ScheduledjobEditForm form) { + ScheduledJob scheduledJob; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + scheduledJob = getScheduledJob(form); + } else { + scheduledJob = new ScheduledJob(); + scheduledJob.setCreatedBy(username); + scheduledJob.setCreatedTime(currentTime); + } + scheduledJob.setUpdatedBy(username); + scheduledJob.setUpdatedTime(currentTime); + copyBeanToBean(form, scheduledJob, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + scheduledJob.setJobLogging(Constants.ON.equals(form.jobLogging) ? Constants.T : Constants.F); + scheduledJob.setCrawler(Constants.ON.equals(form.crawler) ? Constants.T : Constants.F); + scheduledJob.setAvailable(Constants.ON.equals(form.available) ? Constants.T : Constants.F); + return scheduledJob; + } + + protected Map createKeyMap(final ScheduledjobEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final ScheduledjobEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminScheduledjob_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/ScheduledJobForm.java b/src/main/java/org/codelibs/fess/app/web/admin/scheduledjob/ScheduledjobEditForm.java similarity index 56% rename from src/main/java/org/codelibs/fess/web/admin/ScheduledJobForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/scheduledjob/ScheduledjobEditForm.java index 3a455d9da..53655aedc 100644 --- a/src/main/java/org/codelibs/fess/web/admin/ScheduledJobForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/scheduledjob/ScheduledjobEditForm.java @@ -14,59 +14,46 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.scheduledjob; import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; import org.codelibs.fess.Constants; import org.codelibs.fess.annotation.CronExpression; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class ScheduledJobForm implements Serializable { +/** + * @author shinsuke + */ +public class ScheduledjobEditForm implements Serializable { private static final long serialVersionUID = 1L; - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType + //@IntegerType public int crudMode; - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 100) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) public String name; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 100) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) public String target; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 100) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) @CronExpression public String cronExpression; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 100) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) public String scriptType; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String scriptData; // ignore @@ -78,25 +65,25 @@ public class ScheduledJobForm implements Serializable { // ignore public String available; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @IntegerType - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@IntegerType + //@IntRange(min = 0, max = 2147483647) public String sortOrder; - @Required(target = "confirmfromupdate,update,delete") + //@Required(target = "confirmfromupdate,update,delete") public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType public String versionNo; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/scheduledjob/ScheduledjobSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/scheduledjob/ScheduledjobSearchForm.java new file mode 100644 index 000000000..7e8c4ebdf --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/scheduledjob/ScheduledjobSearchForm.java @@ -0,0 +1,31 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.scheduledjob; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author shinsuke + */ +public class ScheduledjobSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/searchlist/AdminSearchlistAction.java b/src/main/java/org/codelibs/fess/app/web/admin/searchlist/AdminSearchlistAction.java new file mode 100644 index 000000000..ae699ddcd --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/searchlist/AdminSearchlistAction.java @@ -0,0 +1,260 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.searchlist; + +import java.text.NumberFormat; +import java.util.List; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.core.lang.StringUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.client.FessEsClient; +import org.codelibs.fess.es.client.FessEsClient.SearchConditionBuilder; +import org.codelibs.fess.exception.InvalidQueryException; +import org.codelibs.fess.exception.ResultOffsetExceededException; +import org.codelibs.fess.helper.FieldHelper; +import org.codelibs.fess.helper.JobHelper; +import org.codelibs.fess.helper.QueryHelper; +import org.codelibs.fess.helper.SystemHelper; +import org.codelibs.fess.util.QueryResponseList; +import org.elasticsearch.index.query.QueryBuilder; +import org.elasticsearch.index.query.QueryBuilders; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.util.LaRequestUtil; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class AdminSearchlistAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private SystemHelper systemHelper; + + @Resource + protected FessEsClient fessEsClient; + @Resource + protected FieldHelper fieldHelper; + @Resource + protected QueryHelper queryHelper; + + @Resource + protected JobHelper jobHelper; + + public List> documentItems; + + public String pageSize; + + public String currentPageNumber; + + public String allRecordCount; + + public String allPageCount; + + public boolean existNextPage; + + public boolean existPrevPage; + + public String currentStartRecordNumber; + + public String currentEndRecordNumber; + + public List pageNumberList; + + public String execTime; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + + runtime.registerData("helpLink", systemHelper.getHelpLink("searchList")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final SearchListForm form) { + return asHtml(path_AdminSearchlist_IndexJsp); + } + + protected HtmlResponse doSearch(final SearchListForm form) { + + if (StringUtil.isBlank(form.query)) { + // redirect to index page + form.query = null; + return redirect(getClass()); + } + return asHtml(path_AdminSearchlist_IndexJsp).renderWith(data -> { + doSearchInternal(data, form); + }); + } + + private void doSearchInternal(final RenderData data, final SearchListForm form) { + // init pager + if (StringUtil.isBlank(form.start)) { + form.start = String.valueOf(Constants.DEFAULT_START_COUNT); + } else { + try { + Long.parseLong(form.start); + } catch (final NumberFormatException e) { + form.start = String.valueOf(Constants.DEFAULT_START_COUNT); + } + } + if (StringUtil.isBlank(form.num)) { + form.num = String.valueOf(Constants.DEFAULT_PAGE_SIZE); + } else { + try { + final int num = Integer.parseInt(form.num); + if (num > 100) { + // max page size + form.num = "100"; + } + } catch (final NumberFormatException e) { + form.num = String.valueOf(Constants.DEFAULT_PAGE_SIZE); + } + } + + final int offset = Integer.parseInt(form.start); + final int size = Integer.parseInt(form.num); + + try { + documentItems = + fessEsClient.getDocumentList(fieldHelper.docIndex, fieldHelper.docType, searchRequestBuilder -> { + return SearchConditionBuilder.builder(searchRequestBuilder).administrativeAccess().offset(offset).size(size) + .responseFields(queryHelper.getResponseFields()).build(); + }); + } catch (final InvalidQueryException e) { + // TODO Log + } catch (final ResultOffsetExceededException e) { + // TODO Log + } + final QueryResponseList queryResponseList = (QueryResponseList) documentItems; + final NumberFormat nf = NumberFormat.getInstance(LaRequestUtil.getRequest().getLocale()); + nf.setMaximumIntegerDigits(2); + nf.setMaximumFractionDigits(2); + try { + nf.format((double) queryResponseList.getExecTime() / 1000); + } catch (final Exception e) {} + + copyBeanToBean(documentItems, this, option -> option.include("pageSize", "currentPageNumber", "allRecordCount", "allPageCount", + "existNextPage", "existPrevPage", "currentStartRecordNumber", "currentEndRecordNumber", "pageNumberList")); + } + + //@Execute(validator = false) + public HtmlResponse search(final SearchListForm form) { + return doSearch(form); + } + + //@Execute(validator = false) + public HtmlResponse prev(final SearchListForm form) { + return doMove(form, -1); + } + + //@Execute(validator = false) + public HtmlResponse next(final SearchListForm form) { + return doMove(form, 1); + } + + //@Execute(validator = false) + public HtmlResponse move(final SearchListForm form) { + return doMove(form, 0); + } + + protected HtmlResponse doMove(final SearchListForm form, final int move) { + int size = Constants.DEFAULT_PAGE_SIZE; + if (StringUtil.isBlank(form.num)) { + form.num = String.valueOf(Constants.DEFAULT_PAGE_SIZE); + } else { + try { + size = Integer.parseInt(form.num); + } catch (final NumberFormatException e) { + form.num = String.valueOf(Constants.DEFAULT_PAGE_SIZE); + } + } + + if (StringUtil.isBlank(form.pn)) { + form.start = String.valueOf(Constants.DEFAULT_START_COUNT); + } else { + Integer pageNumber = Integer.parseInt(form.pn); + if (pageNumber != null && pageNumber > 0) { + pageNumber = pageNumber + move; + if (pageNumber < 1) { + pageNumber = 1; + } + form.start = String.valueOf((pageNumber - 1) * size); + } else { + form.start = String.valueOf(Constants.DEFAULT_START_COUNT); + } + } + + return doSearch(form); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmDelete(final SearchListForm form) { + return asHtml(path_AdminSearchlist_ConfirmDeleteJsp); + } + + @Token(save = false, validate = true) + //@Execute(validator = true, input = "index") + public HtmlResponse delete(final SearchListForm form) { + return deleteByQuery(form); + } + + private HtmlResponse deleteByQuery(final SearchListForm form) { + final String docId = form.docId; + if (jobHelper.isCrawlProcessRunning()) { + // TODO Error + } + final Thread thread = new Thread(() -> { + if (!jobHelper.isCrawlProcessRunning()) { + System.currentTimeMillis(); + try { + final QueryBuilder query = QueryBuilders.termQuery(fieldHelper.docIdField, docId); + fessEsClient.deleteByQuery(fieldHelper.docIndex, fieldHelper.docType, query); + } catch (final Exception e) { + // TODO Log + } + } + } ); + thread.start(); + saveInfo(messages -> messages.addSuccessDeleteSolrIndex(GLOBAL)); + return redirectWith(getClass(), moreUrl("search").params("query", form.query)); + } + + public boolean isSolrProcessRunning() { + return jobHelper.isCrawlProcessRunning(); + } + +} diff --git a/src/main/java/org/codelibs/fess/web/admin/SearchListForm.java b/src/main/java/org/codelibs/fess/app/web/admin/searchlist/SearchListForm.java similarity index 71% rename from src/main/java/org/codelibs/fess/web/admin/SearchListForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/searchlist/SearchListForm.java index 7cef9e168..852696a13 100644 --- a/src/main/java/org/codelibs/fess/web/admin/SearchListForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/searchlist/SearchListForm.java @@ -14,34 +14,33 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.searchlist; import java.io.Serializable; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; - +/** + * @author codelibs + * @author Keiichi Watanabe + */ public class SearchListForm implements Serializable { private static final long serialVersionUID = 1L; - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String query; - @IntegerType + //@IntegerType public String start; - @IntegerType + //@IntegerType public String pn; - @IntegerType + //@IntegerType public String num; - @Required(target = "confirmDelete,delete") + //@Required(target = "confirmDelete,delete") public String docId; - @Required(target = "confirmDelete") + //@Required(target = "confirmDelete") public String url; - } diff --git a/src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/AdminSuggestbadwordAction.java b/src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/AdminSuggestbadwordAction.java new file mode 100644 index 000000000..c668e2528 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/AdminSuggestbadwordAction.java @@ -0,0 +1,389 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.suggestbadword; + +import java.io.BufferedInputStream; +import java.io.BufferedReader; +import java.io.BufferedWriter; +import java.io.File; +import java.io.FileInputStream; +import java.io.FileOutputStream; +import java.io.InputStreamReader; +import java.io.OutputStreamWriter; +import java.io.Reader; +import java.io.Writer; +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; +import javax.servlet.http.HttpServletResponse; + +import org.apache.commons.io.IOUtils; +import org.codelibs.core.io.CopyUtil; +import org.codelibs.core.misc.DynamicProperties; +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.SuggestBadWordPager; +import org.codelibs.fess.app.service.SuggestBadWordService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.SuggestBadWord; +import org.codelibs.fess.exception.FessSystemException; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.util.LaResponseUtil; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + */ +public class AdminSuggestbadwordAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private SuggestBadWordService suggestBadWordService; + @Resource + private SuggestBadWordPager suggestBadWordPager; + @Resource + private SystemHelper systemHelper; + @Resource + protected DynamicProperties crawlerProperties; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("suggestBadWord")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final SuggestBadWordSearchForm form) { + return asHtml(path_AdminSuggestbadword_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final SuggestBadWordSearchForm form) { + suggestBadWordPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminSuggestbadword_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final SuggestBadWordSearchForm form) { + copyBeanToBean(form.searchParams, suggestBadWordPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminSuggestbadword_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final SuggestBadWordSearchForm form) { + suggestBadWordPager.clear(); + return asHtml(path_AdminSuggestbadword_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final SuggestBadWordSearchForm form) { + return asHtml(path_AdminSuggestbadword_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final SuggestBadWordSearchForm form) { + data.register("suggestBadWordItems", suggestBadWordService.getSuggestBadWordList(suggestBadWordPager)); // page navi + // restore from pager + copyBeanToBean(suggestBadWordPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final SuggestBadWordEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminSuggestbadword_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final SuggestBadWordEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadSuggestBadWord(form); + return asHtml(path_AdminSuggestbadword_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final SuggestBadWordEditForm form) { + return asHtml(path_AdminSuggestbadword_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final SuggestBadWordEditForm form) { + form.crudMode = CrudMode.EDIT; + loadSuggestBadWord(form); + return asHtml(path_AdminSuggestbadword_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final SuggestBadWordEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadSuggestBadWord(form); + return asHtml(path_AdminSuggestbadword_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final SuggestBadWordEditForm form) { + form.crudMode = CrudMode.DELETE; + loadSuggestBadWord(form); + return asHtml(path_AdminSuggestbadword_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final SuggestBadWordEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadSuggestBadWord(form); + return asHtml(path_AdminSuggestbadword_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final SuggestBadWordEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminSuggestbadword_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final SuggestBadWordEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminSuggestbadword_ConfirmJsp); + } + + // ----------------------------------------------------- + // Download + // ------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse downloadpage(final SuggestBadWordSearchForm form) { + return asHtml(path_AdminSuggestbadword_DownloadJsp); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse download(final SuggestBadWordSearchForm form) { + final HttpServletResponse response = LaResponseUtil.getResponse(); + response.setContentType("application/octet-stream"); + response.setHeader("Content-Disposition", "attachment; filename=\"" + "badword.csv" + "\""); + try (Writer writer = + new BufferedWriter(new OutputStreamWriter(response.getOutputStream(), crawlerProperties.getProperty( + Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8)))) { + suggestBadWordService.exportCsv(writer); + } catch (final Exception e) { + e.printStackTrace(); + } + return asHtml(path_AdminSuggestbadword_DownloadJsp); + } + + // ----------------------------------------------------- + // Upload + // ------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse uploadpage(final SuggestBadWordUploadForm form) { + return asHtml(path_AdminSuggestbadword_UploadJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final SuggestBadWordEditForm form) { + validate(form, messages -> {}, toEditHtml()); + suggestBadWordService.store(createSuggestBadWord(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final SuggestBadWordEditForm form) { + validate(form, messages -> {}, toEditHtml()); + suggestBadWordService.store(createSuggestBadWord(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final SuggestBadWordEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + suggestBadWordService.delete(getSuggestBadWord(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse upload(final SuggestBadWordUploadForm form) { + BufferedInputStream is = null; + File tempFile = null; + FileOutputStream fos = null; + final byte[] b = new byte[20]; + try { + tempFile = File.createTempFile("suggestbadword-import-", ".csv"); + is = new BufferedInputStream(form.suggestBadWordFile.getInputStream()); + is.mark(20); + if (is.read(b, 0, 20) <= 0) { + // TODO + } + is.reset(); + fos = new FileOutputStream(tempFile); + CopyUtil.copy(is, fos); + } catch (final Exception e) { + if (tempFile != null && !tempFile.delete()) { + // TODO + } + } finally { + IOUtils.closeQuietly(is); + IOUtils.closeQuietly(fos); + } + + final File oFile = tempFile; + try { + final String head = new String(b, Constants.UTF_8); + if (!(head.startsWith("\"SuggestWord\"") || head.startsWith("SuggestWord"))) { + // TODO + } + final String enc = crawlerProperties.getProperty(Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8); + new Thread(() -> { + Reader reader = null; + try { + reader = new BufferedReader(new InputStreamReader(new FileInputStream(oFile), enc)); + suggestBadWordService.importCsv(reader); + } catch (final Exception e) { + throw new FessSystemException("Failed to import data.", e); + } finally { + if (!oFile.delete()) { + // TODO + } + IOUtils.closeQuietly(reader); + } + } ).start(); + } catch (final Exception e) { + if (!oFile.delete()) { + // TODO + } + } + saveInfo(messages -> messages.addSuccessUploadSuggestBadWord(GLOBAL)); + return redirect(getClass()); + } + + //=================================================================================== + // Assist Logic + // ============ + protected void loadSuggestBadWord(final SuggestBadWordEditForm form) { + copyBeanToBean(getSuggestBadWord(form), form, op -> op.exclude("crudMode")); + } + + protected SuggestBadWord getSuggestBadWord(final SuggestBadWordEditForm form) { + final SuggestBadWord suggestBadWord = suggestBadWordService.getSuggestBadWord(createKeyMap(form)); + if (suggestBadWord == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return suggestBadWord; + } + + protected SuggestBadWord createSuggestBadWord(final SuggestBadWordEditForm form) { + SuggestBadWord suggestBadWord; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + suggestBadWord = getSuggestBadWord(form); + } else { + suggestBadWord = new SuggestBadWord(); + suggestBadWord.setCreatedBy(username); + suggestBadWord.setCreatedTime(currentTime); + } + suggestBadWord.setUpdatedBy(username); + suggestBadWord.setUpdatedTime(currentTime); + copyBeanToBean(form, suggestBadWord, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return suggestBadWord; + } + + protected Map createKeyMap(final SuggestBadWordEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + protected Map createItem(final String label, final String value) { + final Map map = new HashMap(2); + map.put(Constants.ITEM_LABEL, label); + map.put(Constants.ITEM_VALUE, value); + return map; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final SuggestBadWordEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminSuggestbadword_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/SuggestBadWordForm.java b/src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/SuggestBadWordEditForm.java similarity index 63% rename from src/main/java/org/codelibs/fess/web/admin/SuggestBadWordForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/SuggestBadWordEditForm.java index 1ce0768a9..7d16aabff 100644 --- a/src/main/java/org/codelibs/fess/web/admin/SuggestBadWordForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/SuggestBadWordEditForm.java @@ -14,76 +14,81 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.suggestbadword; import java.io.Serializable; import java.util.HashMap; import java.util.Map; -import org.apache.struts.upload.FormFile; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class SuggestBadWordForm implements Serializable { +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class SuggestBadWordEditForm implements Serializable { private static final long serialVersionUID = 1L; - @IntegerType + //@IntegerType public String pageNumber; public Map searchParams = new HashMap(); - @IntegerType + //@IntegerType public int crudMode; public String getCurrentPageNumber() { return pageNumber; } - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") public String suggestWord; + public String reading; + public String targetRole; public String targetLabel; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@FloatType + public String boost; + + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType public String versionNo; - @Required(target = "upload") - public FormFile suggestBadWordFile; - public void initialize() { id = null; suggestWord = null; + reading = null; targetRole = null; targetLabel = null; + boost = null; createdBy = "system"; createdTime = Long.toString(ComponentUtil.getSystemHelper().getCurrentTimeAsLong()); updatedBy = null; updatedTime = null; versionNo = null; + boost = "100"; } } diff --git a/src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/SuggestBadWordSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/SuggestBadWordSearchForm.java new file mode 100644 index 000000000..626ac1694 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/SuggestBadWordSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.suggestbadword; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class SuggestBadWordSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/SuggestBadWordUploadForm.java b/src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/SuggestBadWordUploadForm.java new file mode 100644 index 000000000..88c16d0e3 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/suggestbadword/SuggestBadWordUploadForm.java @@ -0,0 +1,33 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.suggestbadword; + +import java.io.Serializable; + +import org.lastaflute.web.ruts.multipart.MultipartFormFile; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class SuggestBadWordUploadForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public MultipartFormFile suggestBadWordFile; + +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/AdminSuggestelevatewordAction.java b/src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/AdminSuggestelevatewordAction.java new file mode 100644 index 000000000..7cec9692b --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/AdminSuggestelevatewordAction.java @@ -0,0 +1,389 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.suggestelevateword; + +import java.io.BufferedInputStream; +import java.io.BufferedReader; +import java.io.BufferedWriter; +import java.io.File; +import java.io.FileInputStream; +import java.io.FileOutputStream; +import java.io.InputStreamReader; +import java.io.OutputStreamWriter; +import java.io.Reader; +import java.io.Writer; +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; +import javax.servlet.http.HttpServletResponse; + +import org.apache.commons.io.IOUtils; +import org.codelibs.core.io.CopyUtil; +import org.codelibs.core.misc.DynamicProperties; +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.SuggestElevateWordPager; +import org.codelibs.fess.app.service.SuggestElevateWordService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.SuggestElevateWord; +import org.codelibs.fess.exception.FessSystemException; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.util.LaResponseUtil; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author Keiichi Watanabe + */ +public class AdminSuggestelevatewordAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private SuggestElevateWordService suggestElevateWordService; + @Resource + private SuggestElevateWordPager suggestElevateWordPager; + @Resource + private SystemHelper systemHelper; + @Resource + protected DynamicProperties crawlerProperties; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("suggestElevateWord")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final SuggestElevateWordSearchForm form) { + return asHtml(path_AdminSuggestelevateword_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final SuggestElevateWordSearchForm form) { + suggestElevateWordPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminSuggestelevateword_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final SuggestElevateWordSearchForm form) { + copyBeanToBean(form.searchParams, suggestElevateWordPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminSuggestelevateword_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final SuggestElevateWordSearchForm form) { + suggestElevateWordPager.clear(); + return asHtml(path_AdminSuggestelevateword_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final SuggestElevateWordSearchForm form) { + return asHtml(path_AdminSuggestelevateword_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final SuggestElevateWordSearchForm form) { + data.register("suggestElevateWordItems", suggestElevateWordService.getSuggestElevateWordList(suggestElevateWordPager)); // page navi + // restore from pager + copyBeanToBean(suggestElevateWordPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final SuggestElevateWordEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminSuggestelevateword_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final SuggestElevateWordEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadSuggestElevateWord(form); + return asHtml(path_AdminSuggestelevateword_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final SuggestElevateWordEditForm form) { + return asHtml(path_AdminSuggestelevateword_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final SuggestElevateWordEditForm form) { + form.crudMode = CrudMode.EDIT; + loadSuggestElevateWord(form); + return asHtml(path_AdminSuggestelevateword_EditJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final SuggestElevateWordEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadSuggestElevateWord(form); + return asHtml(path_AdminSuggestelevateword_ConfirmJsp); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final SuggestElevateWordEditForm form) { + form.crudMode = CrudMode.DELETE; + loadSuggestElevateWord(form); + return asHtml(path_AdminSuggestelevateword_ConfirmJsp); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final SuggestElevateWordEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadSuggestElevateWord(form); + return asHtml(path_AdminSuggestelevateword_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final SuggestElevateWordEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminSuggestelevateword_ConfirmJsp); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final SuggestElevateWordEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminSuggestelevateword_ConfirmJsp); + } + + // ----------------------------------------------------- + // Download + // ------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse downloadpage(final SuggestElevateWordSearchForm form) { + return asHtml(path_AdminSuggestelevateword_DownloadJsp); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse download(final SuggestElevateWordSearchForm form) { + final HttpServletResponse response = LaResponseUtil.getResponse(); + response.setContentType("application/octet-stream"); + response.setHeader("Content-Disposition", "attachment; filename=\"" + "elevateword.csv" + "\""); + try (Writer writer = + new BufferedWriter(new OutputStreamWriter(response.getOutputStream(), crawlerProperties.getProperty( + Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8)))) { + suggestElevateWordService.exportCsv(writer); + } catch (final Exception e) { + e.printStackTrace(); + } + return asHtml(path_AdminSuggestelevateword_DownloadJsp); + } + + // ----------------------------------------------------- + // Upload + // ------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse uploadpage(final SuggestElevateWordUploadForm form) { + return asHtml(path_AdminSuggestelevateword_UploadJsp); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final SuggestElevateWordEditForm form) { + validate(form, messages -> {}, toEditHtml()); + suggestElevateWordService.store(createSuggestElevateWord(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final SuggestElevateWordEditForm form) { + validate(form, messages -> {}, toEditHtml()); + suggestElevateWordService.store(createSuggestElevateWord(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final SuggestElevateWordEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + suggestElevateWordService.delete(getSuggestElevateWord(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse upload(final SuggestElevateWordUploadForm form) { + BufferedInputStream is = null; + File tempFile = null; + FileOutputStream fos = null; + final byte[] b = new byte[20]; + try { + tempFile = File.createTempFile("suggestelevateword-import-", ".csv"); + is = new BufferedInputStream(form.suggestElevateWordFile.getInputStream()); + is.mark(20); + if (is.read(b, 0, 20) <= 0) { + // TODO + } + is.reset(); + fos = new FileOutputStream(tempFile); + CopyUtil.copy(is, fos); + } catch (final Exception e) { + if (tempFile != null && !tempFile.delete()) { + // TODO + } + } finally { + IOUtils.closeQuietly(is); + IOUtils.closeQuietly(fos); + } + + final File oFile = tempFile; + try { + final String head = new String(b, Constants.UTF_8); + if (!(head.startsWith("\"SuggestWord\"") || head.startsWith("SuggestWord"))) { + // TODO + } + final String enc = crawlerProperties.getProperty(Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8); + new Thread(() -> { + Reader reader = null; + try { + reader = new BufferedReader(new InputStreamReader(new FileInputStream(oFile), enc)); + suggestElevateWordService.importCsv(reader); + } catch (final Exception e) { + throw new FessSystemException("Failed to import data.", e); + } finally { + if (!oFile.delete()) { + // TODO + } + IOUtils.closeQuietly(reader); + } + } ).start(); + } catch (final Exception e) { + if (!oFile.delete()) { + // TODO + } + } + saveInfo(messages -> messages.addSuccessUploadSuggestElevateWord(GLOBAL)); + return redirect(getClass()); + } + + //=================================================================================== + // Assist Logic + // ============ + protected void loadSuggestElevateWord(final SuggestElevateWordEditForm form) { + copyBeanToBean(getSuggestElevateWord(form), form, op -> op.exclude("crudMode")); + } + + protected SuggestElevateWord getSuggestElevateWord(final SuggestElevateWordEditForm form) { + final SuggestElevateWord suggestElevateWord = suggestElevateWordService.getSuggestElevateWord(createKeyMap(form)); + if (suggestElevateWord == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return suggestElevateWord; + } + + protected SuggestElevateWord createSuggestElevateWord(final SuggestElevateWordEditForm form) { + SuggestElevateWord suggestElevateWord; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + suggestElevateWord = getSuggestElevateWord(form); + } else { + suggestElevateWord = new SuggestElevateWord(); + suggestElevateWord.setCreatedBy(username); + suggestElevateWord.setCreatedTime(currentTime); + } + suggestElevateWord.setUpdatedBy(username); + suggestElevateWord.setUpdatedTime(currentTime); + copyBeanToBean(form, suggestElevateWord, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return suggestElevateWord; + } + + protected Map createKeyMap(final SuggestElevateWordEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + protected Map createItem(final String label, final String value) { + final Map map = new HashMap(2); + map.put(Constants.ITEM_LABEL, label); + map.put(Constants.ITEM_VALUE, value); + return map; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final SuggestElevateWordEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminSuggestelevateword_EditJsp); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/SuggestElevateWordForm.java b/src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/SuggestElevateWordEditForm.java similarity index 62% rename from src/main/java/org/codelibs/fess/web/admin/SuggestElevateWordForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/SuggestElevateWordEditForm.java index 54bb5701d..3807afc4a 100644 --- a/src/main/java/org/codelibs/fess/web/admin/SuggestElevateWordForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/SuggestElevateWordEditForm.java @@ -14,44 +14,39 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.suggestelevateword; import java.io.Serializable; import java.util.HashMap; import java.util.Map; -import org.apache.struts.upload.FormFile; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.FloatType; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class SuggestElevateWordForm implements Serializable { +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class SuggestElevateWordEditForm implements Serializable { private static final long serialVersionUID = 1L; - @Required(target = "upload") - public FormFile suggestElevateWordFile; - - @IntegerType + //@IntegerType public String pageNumber; public Map searchParams = new HashMap(); - @IntegerType + //@IntegerType public int crudMode; public String getCurrentPageNumber() { return pageNumber; } - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") public String suggestWord; public String reading; @@ -60,26 +55,26 @@ public class SuggestElevateWordForm implements Serializable { public String targetLabel; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @FloatType + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@FloatType public String boost; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType public String versionNo; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/SuggestElevateWordSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/SuggestElevateWordSearchForm.java new file mode 100644 index 000000000..692837119 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/SuggestElevateWordSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.suggestelevateword; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class SuggestElevateWordSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/SuggestElevateWordUploadForm.java b/src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/SuggestElevateWordUploadForm.java new file mode 100644 index 000000000..e0b305d7b --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/suggestelevateword/SuggestElevateWordUploadForm.java @@ -0,0 +1,33 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.suggestelevateword; + +import java.io.Serializable; + +import org.lastaflute.web.ruts.multipart.MultipartFormFile; + +/** + * @author codelibs + * @author Keiichi Watanabe + */ +public class SuggestElevateWordUploadForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public MultipartFormFile suggestElevateWordFile; + +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/system/AdminSystemAction.java b/src/main/java/org/codelibs/fess/app/web/admin/system/AdminSystemAction.java new file mode 100644 index 000000000..bf32c5da9 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/system/AdminSystemAction.java @@ -0,0 +1,134 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.system; + +import java.util.List; +import java.util.Set; + +import javax.annotation.Resource; +import javax.servlet.http.HttpSession; + +import org.codelibs.core.lang.StringUtil; +import org.codelibs.core.misc.DynamicProperties; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.service.ScheduledJobService; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.client.FessEsClient; +import org.codelibs.fess.es.exentity.ScheduledJob; +import org.codelibs.fess.helper.JobHelper; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.util.LaRequestUtil; + +/** + * @author Keiichi Watanabe + */ +public class AdminSystemAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + private static final String STARTING_CRAWL_PROCESS = "startingCrawlProcess"; + + @Resource + private SystemHelper systemHelper; + @Resource + protected DynamicProperties crawlerProperties; + @Resource + protected JobHelper jobHelper; + @Resource + protected ScheduledJobService scheduledJobService; + @Resource + protected FessEsClient fessEsClient; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("system")); + } + + // =================================================================================== + // Index + // ============== + @Execute + public HtmlResponse index() { + return asHtml(path_AdminSystem_IndexJsp).useForm(SystemForm.class).renderWith(data -> { + data.register("clusterName", fessEsClient.getClusterName()); + data.register("clusterStatus", fessEsClient.getStatus()); + data.register("crawlerRunning", isCrawlerRunning()); + data.register("runningSessionIds", getRunningSessionIds()); + }); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse start(final SystemForm form) { + if (!jobHelper.isCrawlProcessRunning()) { + final List scheduledJobList = scheduledJobService.getCrawlerJobList(); + for (final ScheduledJob scheduledJob : scheduledJobList) { + scheduledJob.start(); + } + saveInfo(messages -> messages.addSuccessStartCrawlProcess(GLOBAL)); + LaRequestUtil.getRequest().getSession().setAttribute(STARTING_CRAWL_PROCESS, Boolean.TRUE); + } else { + saveInfo(messages -> messages.addErrorsFailedToStartCrawlProcess(GLOBAL)); + } + + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse stop(final SystemForm form) { + if (jobHelper.isCrawlProcessRunning()) { + if (StringUtil.isNotBlank(form.sessionId)) { + jobHelper.destroyCrawlerProcess(form.sessionId); + } else { + for (final String sessionId : jobHelper.getRunningSessionIdSet()) { + jobHelper.destroyCrawlerProcess(sessionId); + } + } + saveInfo(messages -> messages.addSuccessStoppingCrawlProcess(GLOBAL)); + } else { + saveInfo(messages -> messages.addErrorsNoRunningCrawlProcess(GLOBAL)); + } + return redirect(getClass()); + } + + public boolean isCrawlerRunning() { + final HttpSession session = LaRequestUtil.getRequest().getSession(false); + if (session != null) { + final Object obj = session.getAttribute(STARTING_CRAWL_PROCESS); + if (obj != null) { + session.removeAttribute(STARTING_CRAWL_PROCESS); + return true; + } + } + return jobHelper.isCrawlProcessRunning(); + } + + public String[] getRunningSessionIds() { + final Set idSet = jobHelper.getRunningSessionIdSet(); + return idSet.toArray(new String[idSet.size()]); + } + +} diff --git a/src/main/java/org/codelibs/fess/web/admin/SystemForm.java b/src/main/java/org/codelibs/fess/app/web/admin/system/SystemForm.java similarity index 85% rename from src/main/java/org/codelibs/fess/web/admin/SystemForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/system/SystemForm.java index d986b4462..70ef211bf 100644 --- a/src/main/java/org/codelibs/fess/web/admin/SystemForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/system/SystemForm.java @@ -14,17 +14,19 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.system; import java.io.Serializable; -import org.seasar.struts.annotation.Required; - +/** + * @author codelibs + * @author Keiichi Watanabe + */ public class SystemForm implements Serializable { private static final long serialVersionUID = 1L; - @Required(target = "delete") + //@Required(target = "delete") public String sessionId; } diff --git a/src/main/java/org/codelibs/fess/app/web/admin/systeminfo/AdminSysteminfoAction.java b/src/main/java/org/codelibs/fess/app/web/admin/systeminfo/AdminSysteminfoAction.java new file mode 100644 index 000000000..d4521691d --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/systeminfo/AdminSysteminfoAction.java @@ -0,0 +1,136 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.systeminfo; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.core.lang.StringUtil; +import org.codelibs.core.misc.DynamicProperties; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; + +/** + * @author Keiichi Watanabe + */ +public class AdminSysteminfoAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private SystemHelper systemHelper; + @Resource + protected DynamicProperties crawlerProperties; + + private static final String[] bugReportLabels = { "file.separator", "file.encoding", "java.runtime.version", "java.vm.info", + "java.vm.name", "java.vm.vendor", "java.vm.version", "os.arch", "os.name", "os.version", "user.country", "user.language", + "user.timezone" }; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("systemInfo")); + } + + // =================================================================================== + // Index + // ============== + @Execute + public HtmlResponse index(final SystemInfoForm form) { + return asHtml(path_AdminSysteminfo_IndexJsp).renderWith(data -> { + registerEnvItems(data); + registerPropItems(data); + registerFessPropItems(data); + registerBugReportItems(data); + }); + } + + // =================================================================================== + // Assist Logic + // ============ + + protected void registerEnvItems(final RenderData data) { + final List> itemList = new ArrayList>(); + for (final Map.Entry entry : System.getenv().entrySet()) { + itemList.add(createItem(entry.getKey(), entry.getValue())); + } + data.register("envItems", itemList); + } + + protected void registerPropItems(final RenderData data) { + final List> itemList = new ArrayList>(); + for (final Map.Entry entry : System.getProperties().entrySet()) { + itemList.add(createItem(entry.getKey(), entry.getValue())); + } + data.register("propItems", itemList); + } + + protected void registerFessPropItems(final RenderData data) { + final List> itemList = new ArrayList>(); + for (final Map.Entry entry : crawlerProperties.entrySet()) { + itemList.add(createItem(entry.getKey(), entry.getValue())); + } + data.register("fessPropItems", itemList); + } + + protected void registerBugReportItems(final RenderData data) { + final List> itemList = new ArrayList>(); + for (final String label : bugReportLabels) { + itemList.add(createPropItem(label)); + } + + for (final Map.Entry entry : crawlerProperties.entrySet()) { + if (isBugReportTarget(entry.getKey())) { + itemList.add(createItem(entry.getKey(), entry.getValue())); + } + } + + data.register("bugReportItems", itemList); + } + + private boolean isBugReportTarget(final Object key) { + if ("snapshot.path".equals(key) || "label.value".equals(key)) { + return false; + } + return true; + } + + protected Map createPropItem(final String key) { + return createItem(key, System.getProperty(key)); + } + + protected Map createItem(final Object label, final Object value) { + final Map map = new HashMap(2); + map.put(Constants.ITEM_LABEL, label != null ? label.toString() : StringUtil.EMPTY); + map.put(Constants.ITEM_VALUE, value != null ? value.toString() : StringUtil.EMPTY); + return map; + } + +} diff --git a/src/main/java/org/codelibs/fess/web/admin/SystemInfoForm.java b/src/main/java/org/codelibs/fess/app/web/admin/systeminfo/SystemInfoForm.java similarity index 87% rename from src/main/java/org/codelibs/fess/web/admin/SystemInfoForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/systeminfo/SystemInfoForm.java index 4b0adcd19..625d383fa 100644 --- a/src/main/java/org/codelibs/fess/web/admin/SystemInfoForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/systeminfo/SystemInfoForm.java @@ -14,10 +14,14 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.systeminfo; import java.io.Serializable; +/** + * @author codelibs + * @author Keiichi Watanabe + */ public class SystemInfoForm implements Serializable { private static final long serialVersionUID = 1L; diff --git a/src/main/java/org/codelibs/fess/app/web/admin/user/AdminUserAction.java b/src/main/java/org/codelibs/fess/app/web/admin/user/AdminUserAction.java new file mode 100644 index 000000000..da677e7b1 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/user/AdminUserAction.java @@ -0,0 +1,361 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.user; + +import java.util.Base64; +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.core.lang.StringUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.UserPager; +import org.codelibs.fess.app.service.GroupService; +import org.codelibs.fess.app.service.RoleService; +import org.codelibs.fess.app.service.UserService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.User; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + */ +public class AdminUserAction extends FessAdminAction { + + private static final String TEMPORARY_PASSWORD = "fess.temporary_password"; + // =================================================================================== + // Attribute + // ========= + @Resource + private UserService userService; + @Resource + private RoleService roleService; + @Resource + private GroupService groupService; + @Resource + private UserPager userPager; + @Resource + private SystemHelper systemHelper; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("user")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final UserSearchForm form) { + clearStoredPassword(); + return asHtml(path_AdminUser_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final UserSearchForm form) { + clearStoredPassword(); + userPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminUser_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final UserSearchForm form) { + clearStoredPassword(); + copyBeanToBean(form.searchParams, userPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminUser_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final UserSearchForm form) { + clearStoredPassword(); + userPager.clear(); + return asHtml(path_AdminUser_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final UserSearchForm form) { + clearStoredPassword(); + return asHtml(path_AdminUser_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final UserSearchForm form) { + data.register("userItems", userService.getUserList(userPager)); // page navi + + // restore from pager + copyBeanToBean(userPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + private void registerForms(final RenderData data) { + data.register("roleItems", roleService.getAvailableRoleList()); + data.register("groupItems", groupService.getAvailableGroupList()); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final UserEditForm form) { + clearStoredPassword(); + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminUser_EditJsp).renderWith(data -> { + registerForms(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final UserEditForm form) { + clearStoredPassword(); + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadUser(form, false); + return asHtml(path_AdminUser_EditJsp).renderWith(data -> { + registerForms(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final UserEditForm form) { + clearStoredPassword(); + return asHtml(path_AdminUser_EditJsp).renderWith(data -> { + registerForms(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final UserEditForm form) { + clearStoredPassword(); + form.crudMode = CrudMode.EDIT; + loadUser(form, false); + return asHtml(path_AdminUser_EditJsp).renderWith(data -> { + registerForms(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final UserEditForm form) { + clearStoredPassword(); + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadUser(form, false); + return asHtml(path_AdminUser_ConfirmJsp).renderWith(data -> { + registerForms(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final UserEditForm form) { + clearStoredPassword(); + form.crudMode = CrudMode.DELETE; + loadUser(form, false); + return asHtml(path_AdminUser_ConfirmJsp).renderWith(data -> { + registerForms(data); + }); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final UserEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + verifyPassword(form); + loadUser(form, false); + return asHtml(path_AdminUser_ConfirmJsp).renderWith(data -> { + registerForms(data); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final UserEditForm form) { + verifyPassword(form); + storePassword(form); + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminUser_ConfirmJsp).renderWith(data -> { + registerForms(data); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final UserEditForm form) { + verifyPassword(form); + storePassword(form); + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminUser_ConfirmJsp).renderWith(data -> { + registerForms(data); + }); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final UserEditForm form) { + validate(form, messages -> {}, toEditHtml()); + verifyPassword(form); + userService.store(createUser(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final UserEditForm form) { + validate(form, messages -> {}, toEditHtml()); + verifyPassword(form); + userService.store(createUser(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final UserEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + userService.delete(getUser(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadUser(final UserEditForm form, final boolean hasPassword) { + copyBeanToBean(getUser(form), form, op -> op.exclude("crudMode")); + if (!hasPassword) { + form.password = null; + form.confirmPassword = null; + } + } + + protected User getUser(final UserEditForm form) { + final User user = userService.getUser(createKeyMap(form)); + if (user == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return user; + } + + protected User createUser(final UserEditForm form) { + User user; + if (form.crudMode == CrudMode.EDIT) { + user = getUser(form); + } else { + user = new User(); + } + copyBeanToBean(form, user, op -> op.exclude("password", "confirmPassword")); + sessionManager.getAttribute(TEMPORARY_PASSWORD, String.class).ifPresent(password -> { + user.setPassword(password); + }); + user.setId(Base64.getEncoder().encodeToString(user.getName().getBytes(Constants.CHARSET_UTF_8))); + return user; + } + + protected Map createKeyMap(final UserEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final UserEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected void verifyPassword(final UserEditForm form) { + if (form.crudMode == CrudMode.CREATE && StringUtil.isBlank(form.password)) { + throwValidationError(messages -> { + messages.addErrorsBlankPassword(GLOBAL); + }, toEditHtml()); + } + if (form.password != null && !form.password.equals(form.confirmPassword)) { + throwValidationError(messages -> { + messages.addErrorsInvalidConfirmPassword(GLOBAL); + }, toEditHtml()); + } + } + + protected void verifyStoredPassword(final UserEditForm form) { + if (!sessionManager.getAttribute(TEMPORARY_PASSWORD, String.class).isPresent()) { + throwValidationError(messages -> { + messages.addErrorsInvalidConfirmPassword(GLOBAL); + }, toEditHtml()); + } + } + + private void clearStoredPassword() { + sessionManager.removeAttribute(TEMPORARY_PASSWORD); + } + + private void storePassword(final UserEditForm form) { + final String encodedPassword = fessLoginAssist.encryptPassword(form.password); + sessionManager.setAttribute(TEMPORARY_PASSWORD, encodedPassword); + form.password = null; + form.confirmPassword = null; + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminUser_EditJsp).renderWith(data -> { + registerForms(data); + }); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/user/UserEditForm.java b/src/main/java/org/codelibs/fess/app/web/admin/user/UserEditForm.java new file mode 100644 index 000000000..28de99171 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/user/UserEditForm.java @@ -0,0 +1,60 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.user; + +import java.io.Serializable; + +/** + * @author shinsuke + */ +public class UserEditForm implements Serializable { + + private static final long serialVersionUID = 1L; + + //@IntegerType + public int crudMode; + + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) + public String id; + + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) + public String name; + + //@Maxbytelength(maxbytelength = 100) + public String password; + + //@Maxbytelength(maxbytelength = 100) + public String confirmPassword; + + public String[] roles; + + public String[] groups; + + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType + public String versionNo; + + public void initialize() { + id = null; + name = null; + roles = null; + groups = null; + versionNo = null; + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/user/UserSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/user/UserSearchForm.java new file mode 100644 index 000000000..2aa21c9c8 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/user/UserSearchForm.java @@ -0,0 +1,31 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.user; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author shinsuke + */ +public class UserSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/webauthentication/AdminWebauthenticationAction.java b/src/main/java/org/codelibs/fess/app/web/admin/webauthentication/AdminWebauthenticationAction.java new file mode 100644 index 000000000..a4bebc5a9 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/webauthentication/AdminWebauthenticationAction.java @@ -0,0 +1,343 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.webauthentication; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Locale; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.WebAuthenticationPager; +import org.codelibs.fess.app.service.WebAuthenticationService; +import org.codelibs.fess.app.service.WebConfigService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.WebAuthentication; +import org.codelibs.fess.es.exentity.WebConfig; +import org.codelibs.fess.helper.SystemHelper; +import org.codelibs.fess.util.ComponentUtil; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.util.LaRequestUtil; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + * @author Shunji Makino + */ +public class AdminWebauthenticationAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private WebAuthenticationService webAuthenticationService; + @Resource + private WebAuthenticationPager webAuthenticationPager; + @Resource + private SystemHelper systemHelper; + + @Resource + protected WebConfigService webConfigService; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("webAuthentication")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final WebAuthenticationSearchForm form) { + return asHtml(path_AdminWebauthentication_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final WebAuthenticationSearchForm form) { + webAuthenticationPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminWebauthentication_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final WebAuthenticationSearchForm form) { + copyBeanToBean(form.searchParams, webAuthenticationPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminWebauthentication_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final WebAuthenticationSearchForm form) { + webAuthenticationPager.clear(); + return asHtml(path_AdminWebauthentication_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final WebAuthenticationSearchForm form) { + return asHtml(path_AdminWebauthentication_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final WebAuthenticationSearchForm form) { + data.register("webAuthenticationItems", webAuthenticationService.getWebAuthenticationList(webAuthenticationPager)); // page navi + data.register("displayCreateLink", !webConfigService.getAllWebConfigList(false, false, false, null).isEmpty()); + // restore from pager + copyBeanToBean(webAuthenticationPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final WebAuthenticationEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminWebauthentication_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final WebAuthenticationEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadWebAuthentication(form); + return asHtml(path_AdminWebauthentication_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final WebAuthenticationEditForm form) { + return asHtml(path_AdminWebauthentication_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final WebAuthenticationEditForm form) { + form.crudMode = CrudMode.EDIT; + loadWebAuthentication(form); + return asHtml(path_AdminWebauthentication_EditJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final WebAuthenticationEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadWebAuthentication(form); + return asHtml(path_AdminWebauthentication_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final WebAuthenticationEditForm form) { + form.crudMode = CrudMode.DELETE; + loadWebAuthentication(form); + return asHtml(path_AdminWebauthentication_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final WebAuthenticationEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadWebAuthentication(form); + return asHtml(path_AdminWebauthentication_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final WebAuthenticationEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminWebauthentication_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final WebAuthenticationEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminWebauthentication_ConfirmJsp).renderWith(data -> { + registerProtocolSchemeItems(data); + registerWebConfigItems(data); + }); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final WebAuthenticationEditForm form) { + validate(form, messages -> {}, toEditHtml()); + webAuthenticationService.store(createWebAuthentication(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final WebAuthenticationEditForm form) { + validate(form, messages -> {}, toEditHtml()); + webAuthenticationService.store(createWebAuthentication(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final WebAuthenticationEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + webAuthenticationService.delete(getWebAuthentication(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + //=================================================================================== + // Assist Logic + // ============ + protected void loadWebAuthentication(final WebAuthenticationEditForm form) { + copyBeanToBean(getWebAuthentication(form), form, op -> op.exclude("crudMode")); + } + + protected WebAuthentication getWebAuthentication(final WebAuthenticationEditForm form) { + final WebAuthentication webAuthentication = webAuthenticationService.getWebAuthentication(createKeyMap(form)); + if (webAuthentication == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return webAuthentication; + } + + protected WebAuthentication createWebAuthentication(final WebAuthenticationEditForm form) { + WebAuthentication webAuthentication; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + webAuthentication = getWebAuthentication(form); + } else { + webAuthentication = new WebAuthentication(); + webAuthentication.setCreatedBy(username); + webAuthentication.setCreatedTime(currentTime); + } + webAuthentication.setUpdatedBy(username); + webAuthentication.setUpdatedTime(currentTime); + copyBeanToBean(form, webAuthentication, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return webAuthentication; + } + + protected Map createKeyMap(final WebAuthenticationEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + protected void registerProtocolSchemeItems(final RenderData data) { + final List> itemList = new ArrayList>(); + final Locale locale = LaRequestUtil.getRequest().getLocale(); + itemList.add(createItem(ComponentUtil.getMessageManager().getMessage(locale, "labels.web_authentication_scheme_basic"), + Constants.BASIC)); + itemList.add(createItem(ComponentUtil.getMessageManager().getMessage(locale, "labels.web_authentication_scheme_digest"), + Constants.DIGEST)); + itemList.add(createItem(ComponentUtil.getMessageManager().getMessage(locale, "labels.web_authentication_scheme_ntlm"), + Constants.NTLM)); + data.register("protocolSchemeItems", itemList); + } + + protected void registerWebConfigItems(final RenderData data) { + final List> itemList = new ArrayList>(); + final List webConfigList = webConfigService.getAllWebConfigList(false, false, false, null); + for (final WebConfig webConfig : webConfigList) { + itemList.add(createItem(webConfig.getName(), webConfig.getId().toString())); + } + data.register("webConfigItems", itemList); + } + + protected Map createItem(final String label, final String value) { + final Map map = new HashMap(2); + map.put(Constants.ITEM_LABEL, label); + map.put(Constants.ITEM_VALUE, value); + return map; + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final WebAuthenticationEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminWebauthentication_EditJsp).renderWith(data -> { + registerWebConfigItems(data); + }); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/WebAuthenticationForm.java b/src/main/java/org/codelibs/fess/app/web/admin/webauthentication/WebAuthenticationEditForm.java similarity index 52% rename from src/main/java/org/codelibs/fess/web/admin/WebAuthenticationForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/webauthentication/WebAuthenticationEditForm.java index caecdd552..72a4a1e21 100644 --- a/src/main/java/org/codelibs/fess/web/admin/WebAuthenticationForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/webauthentication/WebAuthenticationEditForm.java @@ -14,81 +14,69 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.webauthentication; import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class WebAuthenticationForm implements Serializable { +/** + * @author codelibs + * @author Shunji Makino + */ +public class WebAuthenticationEditForm implements Serializable { private static final long serialVersionUID = 1L; - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType + //@IntegerType public int crudMode; - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Maxbytelength(maxbytelength = 100) + //@Maxbytelength(maxbytelength = 100) public String hostname; - @IntRange(min = -1, max = 2147483647) + //@IntRange(min = -1, max = 2147483647) public String port; - @Maxbytelength(maxbytelength = 100) + //@Maxbytelength(maxbytelength = 100) public String authRealm; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String protocolScheme; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 100) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 100) public String username; - @Maxbytelength(maxbytelength = 100) + //@Maxbytelength(maxbytelength = 100) public String password; - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String parameters; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String webConfigId; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType public String versionNo; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/webauthentication/WebAuthenticationSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/webauthentication/WebAuthenticationSearchForm.java new file mode 100644 index 000000000..f64416e4d --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/webauthentication/WebAuthenticationSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.webauthentication; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Shunji Makino + */ +public class WebAuthenticationSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/webconfig/AdminWebconfigAction.java b/src/main/java/org/codelibs/fess/app/web/admin/webconfig/AdminWebconfigAction.java new file mode 100644 index 000000000..58b7e940d --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/webconfig/AdminWebconfigAction.java @@ -0,0 +1,313 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.webconfig; + +import java.util.HashMap; +import java.util.Map; + +import javax.annotation.Resource; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.pager.WebConfigPager; +import org.codelibs.fess.app.service.LabelTypeService; +import org.codelibs.fess.app.service.RoleTypeService; +import org.codelibs.fess.app.service.WebConfigService; +import org.codelibs.fess.app.web.CrudMode; +import org.codelibs.fess.app.web.base.FessAdminAction; +import org.codelibs.fess.es.exentity.WebConfig; +import org.codelibs.fess.helper.SystemHelper; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.validation.VaErrorHook; + +/** + * @author shinsuke + * @author Shunji Makino + */ +public class AdminWebconfigAction extends FessAdminAction { + + // =================================================================================== + // Attribute + // ========= + @Resource + private WebConfigService webConfigService; + @Resource + private WebConfigPager webConfigPager; + @Resource + private SystemHelper systemHelper; + @Resource + protected RoleTypeService roleTypeService; + @Resource + protected LabelTypeService labelTypeService; + + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("webConfig")); + } + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final WebConfigSearchForm form) { + return asHtml(path_AdminWebconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse list(final Integer pageNumber, final WebConfigSearchForm form) { + webConfigPager.setCurrentPageNumber(pageNumber); + return asHtml(path_AdminWebconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse search(final WebConfigSearchForm form) { + copyBeanToBean(form.searchParams, webConfigPager, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + return asHtml(path_AdminWebconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse reset(final WebConfigSearchForm form) { + webConfigPager.clear(); + return asHtml(path_AdminWebconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + @Execute + public HtmlResponse back(final WebConfigSearchForm form) { + return asHtml(path_AdminWebconfig_IndexJsp).renderWith(data -> { + searchPaging(data, form); + }); + } + + protected void searchPaging(final RenderData data, final WebConfigSearchForm form) { + data.register("webConfigItems", webConfigService.getWebConfigList(webConfigPager)); // page navi + + // restore from pager + copyBeanToBean(webConfigPager, form.searchParams, op -> op.exclude(Constants.PAGER_CONVERSION_RULE)); + } + + // =================================================================================== + // Edit Execute + // ============ + // ----------------------------------------------------- + // Entry Page + // ---------- + @Token(save = true, validate = false) + @Execute + public HtmlResponse createpage(final WebConfigEditForm form) { + form.initialize(); + form.crudMode = CrudMode.CREATE; + return asHtml(path_AdminWebconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editpage(final int crudMode, final String id, final WebConfigEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.EDIT); + loadWebConfig(form); + return asHtml(path_AdminWebconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editagain(final WebConfigEditForm form) { + return asHtml(path_AdminWebconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse editfromconfirm(final WebConfigEditForm form) { + form.crudMode = CrudMode.EDIT; + loadWebConfig(form); + return asHtml(path_AdminWebconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletepage(final int crudMode, final String id, final WebConfigEditForm form) { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.DELETE); + loadWebConfig(form); + return asHtml(path_AdminWebconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = true, validate = false) + @Execute + public HtmlResponse deletefromconfirm(final WebConfigEditForm form) { + form.crudMode = CrudMode.DELETE; + loadWebConfig(form); + return asHtml(path_AdminWebconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + // ----------------------------------------------------- + // Confirm + // ------- + @Execute + public HtmlResponse confirmpage(final int crudMode, final String id, final WebConfigEditForm form) { + try { + form.crudMode = crudMode; + form.id = id; + verifyCrudMode(form, CrudMode.CONFIRM); + loadWebConfig(form); + return asHtml(path_AdminWebconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } catch (final Exception e) { + e.printStackTrace(); + return asHtml(path_AdminWebconfig_ConfirmJsp); + } + + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromcreate(final WebConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminWebconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + @Token(save = false, validate = true, keep = true) + @Execute + public HtmlResponse confirmfromupdate(final WebConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + return asHtml(path_AdminWebconfig_ConfirmJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + } + + // ----------------------------------------------------- + // Actually Crud + // ------------- + @Token(save = false, validate = true) + @Execute + public HtmlResponse create(final WebConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + webConfigService.store(createWebConfig(form)); + saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Token(save = false, validate = true) + @Execute + public HtmlResponse update(final WebConfigEditForm form) { + validate(form, messages -> {}, toEditHtml()); + webConfigService.store(createWebConfig(form)); + saveInfo(messages -> messages.addSuccessCrudUpdateCrudTable(GLOBAL)); + return redirect(getClass()); + } + + @Execute + public HtmlResponse delete(final WebConfigEditForm form) { + verifyCrudMode(form, CrudMode.DELETE); + webConfigService.delete(getWebConfig(form)); + saveInfo(messages -> messages.addSuccessCrudDeleteCrudTable(GLOBAL)); + return redirect(getClass()); + } + + // =================================================================================== + // Assist Logic + // ============ + protected void loadWebConfig(final WebConfigEditForm form) { + copyBeanToBean(getWebConfig(form), form, op -> op.exclude("crudMode")); + } + + protected WebConfig getWebConfig(final WebConfigEditForm form) { + final WebConfig webConfig = webConfigService.getWebConfig(createKeyMap(form)); + if (webConfig == null) { + throwValidationError(messages -> messages.addErrorsCrudCouldNotFindCrudTable(GLOBAL, form.id), toEditHtml()); + } + return webConfig; + } + + protected WebConfig createWebConfig(final WebConfigEditForm form) { + WebConfig webConfig; + final String username = systemHelper.getUsername(); + final long currentTime = systemHelper.getCurrentTimeAsLong(); + if (form.crudMode == CrudMode.EDIT) { + webConfig = getWebConfig(form); + } else { + webConfig = new WebConfig(); + webConfig.setCreatedBy(username); + webConfig.setCreatedTime(currentTime); + } + webConfig.setUpdatedBy(username); + webConfig.setUpdatedTime(currentTime); + copyBeanToBean(form, webConfig, op -> op.exclude(Constants.COMMON_CONVERSION_RULE)); + return webConfig; + } + + protected Map createKeyMap(final WebConfigEditForm form) { + final Map keys = new HashMap(); + keys.put("id", form.id); + return keys; + } + + protected void registerRolesAndLabels(final RenderData data) { + data.register("roleTypeItems", roleTypeService.getRoleTypeList()); + data.register("labelTypeItems", labelTypeService.getLabelTypeList()); + } + + // =================================================================================== + // Small Helper + // ============ + protected void verifyCrudMode(final WebConfigEditForm form, final int expectedMode) { + if (form.crudMode != expectedMode) { + throwValidationError(messages -> { + messages.addErrorsCrudInvalidMode(GLOBAL, String.valueOf(expectedMode), String.valueOf(form.crudMode)); + }, toEditHtml()); + } + } + + protected VaErrorHook toEditHtml() { + return () -> { + return asHtml(path_AdminWebconfig_EditJsp).renderWith(data -> { + registerRolesAndLabels(data); + }); + }; + } +} diff --git a/src/main/java/org/codelibs/fess/web/admin/WebConfigForm.java b/src/main/java/org/codelibs/fess/app/web/admin/webconfig/WebConfigEditForm.java similarity index 53% rename from src/main/java/org/codelibs/fess/web/admin/WebConfigForm.java rename to src/main/java/org/codelibs/fess/app/web/admin/webconfig/WebConfigEditForm.java index 0352c3b21..69ff23b6d 100644 --- a/src/main/java/org/codelibs/fess/web/admin/WebConfigForm.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/webconfig/WebConfigEditForm.java @@ -14,24 +14,20 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.webconfig; import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; import org.codelibs.fess.annotation.UriType; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongRange; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class WebConfigForm implements Serializable { +/** + * @author codelibs + * @author Shunji Makino + */ +public class WebConfigEditForm implements Serializable { private static final long serialVersionUID = 1L; @@ -39,92 +35,83 @@ public class WebConfigForm implements Serializable { public String[] labelTypeIds; - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType + //@IntegerType public int crudMode; - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 1000) public String id; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 200) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 200) public String name; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") @UriType(protocols = "http:,https:") - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String urls; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String includedUrls; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String excludedUrls; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String includedDocUrls; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String excludedDocUrls; - @Maxbytelength(maxbytelength = 4000) + //@Maxbytelength(maxbytelength = 4000) public String configParameter; - @IntRange(min = 0, max = 2147483647) + //@IntRange(min = 0, max = 2147483647) public String depth; - @LongRange(min = 0, max = 9223372036854775807l) + //@LongRange(min = 0, max = 9223372036854775807l) public String maxAccessCount; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 200) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 200) public String userAgent; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) public String numOfThread; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) public String intervalTime; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) public String boost; - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 5) + //@Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 5) public String available; - @Required(target = "confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) + //@Required(target = "confirmfromupdate,update,delete") + //@IntRange(min = 0, max = 2147483647) public String sortOrder; - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) + //@Required(target = "confirmfromupdate,update,delete") + //@Maxbytelength(maxbytelength = 255) public String createdBy; - @Required(target = "confirmfromupdate,update,delete") - @LongType + //@Required(target = "confirmfromupdate,update,delete") + //@LongType public String createdTime; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String updatedBy; - @LongType + //@LongType public String updatedTime; - @Required(target = "confirmfromupdate,update,delete") - @IntegerType + //@Required(target = "confirmfromupdate,update,delete") + //@IntegerType public String versionNo; public void initialize() { diff --git a/src/main/java/org/codelibs/fess/app/web/admin/webconfig/WebConfigSearchForm.java b/src/main/java/org/codelibs/fess/app/web/admin/webconfig/WebConfigSearchForm.java new file mode 100644 index 000000000..b5dc2e4ec --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/webconfig/WebConfigSearchForm.java @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.admin.webconfig; + +import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; + +/** + * @author codelibs + * @author Shunji Makino + */ +public class WebConfigSearchForm implements Serializable { + + private static final long serialVersionUID = 1L; + + public Map searchParams = new HashMap(); +} diff --git a/src/main/java/org/codelibs/fess/web/admin/WizardAction.java b/src/main/java/org/codelibs/fess/app/web/admin/wizard/AdminWizardAction.java similarity index 64% rename from src/main/java/org/codelibs/fess/web/admin/WizardAction.java rename to src/main/java/org/codelibs/fess/app/web/admin/wizard/AdminWizardAction.java index b87a2c87c..3b32d6b47 100644 --- a/src/main/java/org/codelibs/fess/web/admin/WizardAction.java +++ b/src/main/java/org/codelibs/fess/app/web/admin/wizard/AdminWizardAction.java @@ -14,47 +14,48 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web.admin; +package org.codelibs.fess.app.web.admin.wizard; -import java.io.Serializable; import java.io.UnsupportedEncodingException; import java.net.URLEncoder; import java.util.List; import javax.annotation.Resource; -import org.apache.commons.lang.StringUtils; +import org.apache.commons.lang3.StringUtils; import org.codelibs.core.lang.StringUtil; import org.codelibs.core.misc.DynamicProperties; import org.codelibs.fess.Constants; -import org.codelibs.fess.crud.util.SAStrutsUtil; +import org.codelibs.fess.annotation.Token; +import org.codelibs.fess.app.service.FileConfigService; +import org.codelibs.fess.app.service.ScheduledJobService; +import org.codelibs.fess.app.service.WebConfigService; +import org.codelibs.fess.app.web.admin.system.AdminSystemAction; +import org.codelibs.fess.app.web.base.FessAdminAction; import org.codelibs.fess.es.exentity.FileConfig; import org.codelibs.fess.es.exentity.ScheduledJob; import org.codelibs.fess.es.exentity.WebConfig; import org.codelibs.fess.helper.JobHelper; import org.codelibs.fess.helper.SystemHelper; import org.codelibs.fess.job.TriggeredJob; -import org.codelibs.fess.service.FileConfigService; -import org.codelibs.fess.service.ScheduledJobService; -import org.codelibs.fess.service.WebConfigService; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.robot.util.CharUtil; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; +import org.lastaflute.web.Execute; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.HtmlResponse; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -public class WizardAction implements Serializable { - private static final long serialVersionUID = 1L; +public class AdminWizardAction extends FessAdminAction { - private static final Logger logger = LoggerFactory.getLogger(WizardAction.class); - - @ActionForm - @Resource - protected WizardForm wizardForm; + // =================================================================================== + // Constant + // + private static final Logger logger = LoggerFactory.getLogger(AdminWizardAction.class); + // =================================================================================== + // Attribute + // @Resource protected DynamicProperties crawlerProperties; @@ -73,47 +74,62 @@ public class WizardAction implements Serializable { @Resource protected ScheduledJobService scheduledJobService; - public String getHelpLink() { - return systemHelper.getHelpLink("wizard"); + // =================================================================================== + // Hook + // ====== + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("helpLink", systemHelper.getHelpLink("wizard")); } - @Execute(validator = false) - public String index() { - return "index.jsp"; + // =================================================================================== + // Search Execute + // ============== + + @Execute + public HtmlResponse index() { + return asHtml(path_AdminWizard_IndexJsp).useForm(IndexForm.class); } @Token(save = true, validate = false) - @Execute(validator = false) - public String crawlingConfigForm() { - return "crawlingConfig.jsp"; + @Execute + public HtmlResponse crawlingConfigForm() { + return asHtml(path_AdminWizard_CrawlingConfigJsp).useForm(CrawlingConfigForm.class); } @Token(save = false, validate = true) - @Execute(validator = true, input = "crawlingConfigForm") - public String crawlingConfig() { - final String name = crawlingConfigInternal(wizardForm.crawlingConfigName, wizardForm.crawlingConfigPath); - SAStrutsUtil.addSessionMessage("success.create_crawling_config_at_wizard", name); - return "crawlingConfigForm?redirect=true"; + @Execute + public HtmlResponse crawlingConfig(final CrawlingConfigForm form) { + validate(form, messages -> {}, () -> { + return asHtml(path_AdminWizard_CrawlingConfigJsp); + }); + final String name = crawlingConfigInternal(form); + saveInfo(messages -> messages.addSuccessCreateCrawlingConfigAtWizard(GLOBAL, name)); + return redirectWith(getClass(), moreUrl("crawlingConfigForm")); } @Token(save = false, validate = true) - @Execute(validator = true, input = "crawlingConfigForm") - public String crawlingConfigNext() { - final String name = crawlingConfigInternal(wizardForm.crawlingConfigName, wizardForm.crawlingConfigPath); - SAStrutsUtil.addSessionMessage("success.create_crawling_config_at_wizard", name); - return "startCrawlingForm?redirect=true"; + @Execute + public HtmlResponse crawlingConfigNext(final CrawlingConfigForm form) { + validate(form, messages -> {}, () -> { + return asHtml(path_AdminWizard_CrawlingConfigJsp); + }); + final String name = crawlingConfigInternal(form); + saveInfo(messages -> messages.addSuccessCreateCrawlingConfigAtWizard(GLOBAL, name)); + return redirectWith(getClass(), moreUrl("startCrawlingForm")); } - protected String crawlingConfigInternal(final String crawlingConfigName, final String crawlingConfigPath) { + protected String crawlingConfigInternal(final CrawlingConfigForm form) { - String configName = crawlingConfigName; - String configPath = crawlingConfigPath.trim(); + String configName = form.crawlingConfigName; + String configPath = form.crawlingConfigPath.trim(); if (StringUtil.isBlank(configName)) { configName = StringUtils.abbreviate(configPath, 30); } // normalize - final StringBuilder buf = new StringBuilder(); + final StringBuilder buf = new StringBuilder(1000); for (int i = 0; i < configPath.length(); i++) { final char c = configPath.charAt(i); if (c == '\\') { @@ -141,16 +157,16 @@ public class WizardAction implements Serializable { wConfig.setBoost(1.0f); wConfig.setCreatedBy(username); wConfig.setCreatedTime(now); - if (StringUtil.isNotBlank(wizardForm.depth)) { - wConfig.setDepth(Integer.parseInt(wizardForm.depth)); + if (StringUtil.isNotBlank(form.depth)) { + wConfig.setDepth(Integer.parseInt(form.depth)); } wConfig.setExcludedDocUrls(getDefaultString("default.config.web.excludedDocUrls", StringUtil.EMPTY)); wConfig.setExcludedUrls(getDefaultString("default.config.web.excludedUrls", StringUtil.EMPTY)); wConfig.setIncludedDocUrls(getDefaultString("default.config.web.includedDocUrls", StringUtil.EMPTY)); wConfig.setIncludedUrls(getDefaultString("default.config.web.includedUrls", StringUtil.EMPTY)); wConfig.setIntervalTime(getDefaultInteger("default.config.web.intervalTime", Constants.DEFAULT_INTERVAL_TIME_FOR_WEB)); - if (StringUtil.isNotBlank(wizardForm.maxAccessCount)) { - wConfig.setMaxAccessCount(Long.parseLong(wizardForm.maxAccessCount)); + if (StringUtil.isNotBlank(form.maxAccessCount)) { + wConfig.setMaxAccessCount(Long.parseLong(form.maxAccessCount)); } wConfig.setName(configName); wConfig.setNumOfThread(getDefaultInteger("default.config.web.numOfThread", Constants.DEFAULT_NUM_OF_THREAD_FOR_WEB)); @@ -169,16 +185,16 @@ public class WizardAction implements Serializable { fConfig.setBoost(1.0f); fConfig.setCreatedBy(username); fConfig.setCreatedTime(now); - if (StringUtil.isNotBlank(wizardForm.depth)) { - fConfig.setDepth(Integer.parseInt(wizardForm.depth)); + if (StringUtil.isNotBlank(form.depth)) { + fConfig.setDepth(Integer.parseInt(form.depth)); } fConfig.setExcludedDocPaths(getDefaultString("default.config.file.excludedDocPaths", StringUtil.EMPTY)); fConfig.setExcludedPaths(getDefaultString("default.config.file.excludedPaths", StringUtil.EMPTY)); fConfig.setIncludedDocPaths(getDefaultString("default.config.file.includedDocPaths", StringUtil.EMPTY)); fConfig.setIncludedPaths(getDefaultString("default.config.file.includedPaths", StringUtil.EMPTY)); fConfig.setIntervalTime(getDefaultInteger("default.config.file.intervalTime", Constants.DEFAULT_INTERVAL_TIME_FOR_FS)); - if (StringUtil.isNotBlank(wizardForm.maxAccessCount)) { - fConfig.setMaxAccessCount(Long.parseLong(wizardForm.maxAccessCount)); + if (StringUtil.isNotBlank(form.maxAccessCount)) { + fConfig.setMaxAccessCount(Long.parseLong(form.maxAccessCount)); } fConfig.setName(configName); fConfig.setNumOfThread(getDefaultInteger("default.config.file.numOfThread", Constants.DEFAULT_NUM_OF_THREAD_FOR_FS)); @@ -191,8 +207,11 @@ public class WizardAction implements Serializable { } return configName; } catch (final Exception e) { - logger.error("Failed to create crawling config: " + wizardForm.crawlingConfigPath, e); - throw new SSCActionMessagesException(e, "errors.failed_to_create_crawling_config_at_wizard", wizardForm.crawlingConfigPath); + logger.error("Failed to create crawling config: " + form.crawlingConfigPath, e); + throwValidationError(messages -> messages.addErrorsFailedToCreateCrawlingConfigAtWizard(GLOBAL), () -> { + return asHtml(path_AdminWizard_CrawlingConfigJsp); + }); + return null; } } @@ -252,23 +271,23 @@ public class WizardAction implements Serializable { } @Token(save = true, validate = false) - @Execute(validator = false) - public String startCrawlingForm() { - return "startCrawling.jsp"; + @Execute + public HtmlResponse startCrawlingForm() { + return asHtml(path_AdminWizard_StartCrawlingJsp).useForm(StartCrawlingForm.class); } @Token(save = false, validate = true) - @Execute(validator = false) - public String startCrawling() { + @Execute + public HtmlResponse startCrawling(final StartCrawlingForm form) { if (!jobHelper.isCrawlProcessRunning()) { - final List scheduledJobList = scheduledJobService.getCrawloerJobList(); + final List scheduledJobList = scheduledJobService.getCrawlerJobList(); for (final ScheduledJob scheduledJob : scheduledJobList) { new Thread(() -> new TriggeredJob().execute(scheduledJob)).start(); } - SAStrutsUtil.addSessionMessage("success.start_crawl_process"); + saveInfo(messages -> messages.addSuccessStartCrawlProcess(GLOBAL)); } else { - SAStrutsUtil.addSessionMessage("success.failed_to_start_crawl_process"); + saveError(messages -> messages.addErrorsFailedToStartCrawlProcess(GLOBAL)); } - return "../system/index?redirect=true"; + return redirect(AdminSystemAction.class); } } \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/app/web/admin/wizard/CrawlingConfigForm.java b/src/main/java/org/codelibs/fess/app/web/admin/wizard/CrawlingConfigForm.java new file mode 100644 index 000000000..650ea44e8 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/wizard/CrawlingConfigForm.java @@ -0,0 +1,32 @@ +package org.codelibs.fess.app.web.admin.wizard; + +import java.io.Serializable; + +import javax.validation.constraints.Size; + +import org.lastaflute.web.validation.Required; + +public class CrawlingConfigForm implements Serializable { + + private static final long serialVersionUID = 1L; + + @Required + @Size(max = 200) + public String crawlingConfigName; + + @Required + @Size(max = 1000) + public String crawlingConfigPath; + + // TODO + // @Min(0) + // @Max(Integer.MAX_VALUE) + public String depth; + + // TODO + @Size(max = 100) + // @Min(0) + // @Max(Long.MAX_VALUE) + public String maxAccessCount; + +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/wizard/IndexForm.java b/src/main/java/org/codelibs/fess/app/web/admin/wizard/IndexForm.java new file mode 100644 index 000000000..ee18806a7 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/wizard/IndexForm.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.app.web.admin.wizard; + +import java.io.Serializable; + +public class IndexForm implements Serializable { + + private static final long serialVersionUID = 1L; + +} diff --git a/src/main/java/org/codelibs/fess/app/web/admin/wizard/StartCrawlingForm.java b/src/main/java/org/codelibs/fess/app/web/admin/wizard/StartCrawlingForm.java new file mode 100644 index 000000000..f3edbc83c --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/admin/wizard/StartCrawlingForm.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.app.web.admin.wizard; + +import java.io.Serializable; + +public class StartCrawlingForm implements Serializable { + + private static final long serialVersionUID = 1L; + +} diff --git a/src/main/java/org/codelibs/fess/app/web/base/FessAdminAction.java b/src/main/java/org/codelibs/fess/app/web/base/FessAdminAction.java new file mode 100644 index 000000000..22de3c843 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/base/FessAdminAction.java @@ -0,0 +1,94 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.app.web.base; + +import java.util.function.Consumer; + +import javax.servlet.ServletContext; + +import org.codelibs.core.beans.util.BeanUtil; +import org.codelibs.core.beans.util.CopyOptions; +import org.codelibs.fess.mylasta.action.FessMessages; +import org.dbflute.optional.OptionalThing; +import org.lastaflute.di.util.LdiFileUtil; +import org.lastaflute.web.login.LoginManager; +import org.lastaflute.web.util.LaServletContextUtil; +import org.lastaflute.web.validation.VaMessenger; + +/** + * @author codelibs + * @author jflute + */ +public abstract class FessAdminAction extends FessBaseAction { + + // =================================================================================== + // Attribute + // ========= + + // =================================================================================== + // Small Helper + // ============ + protected void saveInfo(final VaMessenger validationMessagesLambda) { + final FessMessages messages = createMessages(); + validationMessagesLambda.message(messages); + sessionManager.info().save(messages); + } + + protected void saveError(final VaMessenger validationMessagesLambda) { + final FessMessages messages = createMessages(); + validationMessagesLambda.message(messages); + sessionManager.errors().save(messages); + } + + protected void write(final String path, final byte[] data) { + LdiFileUtil.write(path, data); + } + + protected void copyBeanToBean(final Object src, final Object dest, final Consumer option) { + BeanUtil.copyBeanToBean(src, dest, option); + } + + protected ServletContext getServletContext() { + return LaServletContextUtil.getServletContext(); + } + + // =================================================================================== + // Document + // ======== + /** + * {@inheritDoc}
    + * Application Origin Methods: + *
    +     * [Small Helper]
    +     * o saveInfo() // save messages to session
    +     * o write() // write text to specified file
    +     * o copyBeanToBean() // copy bean to bean by BeanUtil
    +     * o getServletContext() // get servlet context
    +     * 
    + */ + @Override + public void document1_CallableSuperMethod() { + super.document1_CallableSuperMethod(); + } + + // =================================================================================== + // User Info + // ========= + @Override + protected OptionalThing myLoginManager() { + return OptionalThing.of(fessLoginAssist); + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/base/FessBaseAction.java b/src/main/java/org/codelibs/fess/app/web/base/FessBaseAction.java new file mode 100644 index 000000000..0b19d97b7 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/base/FessBaseAction.java @@ -0,0 +1,150 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +/* + + * Copyright 2014-2015 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.app.web.base; + +import javax.annotation.Resource; + +import org.codelibs.fess.app.web.base.login.FessLoginAssist; +import org.codelibs.fess.mylasta.action.FessHtmlPath; +import org.codelibs.fess.mylasta.action.FessMessages; +import org.codelibs.fess.mylasta.action.FessUserBean; +import org.dbflute.hook.AccessContext; +import org.dbflute.optional.OptionalThing; +import org.lastaflute.db.dbflute.accesscontext.AccessContextArranger; +import org.lastaflute.web.TypicalAction; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.response.ActionResponse; +import org.lastaflute.web.servlet.session.SessionManager; +import org.lastaflute.web.validation.ActionValidator; +import org.lastaflute.web.validation.LaValidatable; + +/** + * @author jflute + */ +public abstract class FessBaseAction extends TypicalAction // has several interfaces for direct use + implements LaValidatable, FessHtmlPath { + + // =================================================================================== + // Definition + // ========== + /** The application type for FESs, e.g. used by access context. */ + protected static final String APP_TYPE = "FES"; // #change_it_first + + /** The user type for Admin, e.g. used by access context. */ + protected static final String USER_TYPE = "A"; + + // =================================================================================== + // Attribute + // ========= + @Resource + protected FessLoginAssist fessLoginAssist; + + @Resource + protected SessionManager sessionManager; + + // =================================================================================== + // Hook + // ====== + // to suppress unexpected override by sub-class + // you should remove the 'final' if you need to override this + @Override + public final ActionResponse godHandPrologue(final ActionRuntime runtime) { + return super.godHandPrologue(runtime); + } + + @Override + public final ActionResponse godHandMonologue(final ActionRuntime runtime) { + return super.godHandMonologue(runtime); + } + + @Override + public final void godHandEpilogue(final ActionRuntime runtime) { + super.godHandEpilogue(runtime); + } + + // #app_customize you can customize the action hook + @Override + public ActionResponse hookBefore(final ActionRuntime runtime) { // application may override + return super.hookBefore(runtime); + } + + @Override + public void hookFinally(final ActionRuntime runtime) { + super.hookFinally(runtime); + } + + // =================================================================================== + // Access Context + // ============== + @Override + protected AccessContextArranger newAccessContextArranger() { // for framework + // fess does not use DBFlute, and this is unneeded so dummy + return resource -> { + final AccessContext context = new AccessContext(); + context.setAccessLocalDateTimeProvider(() -> currentDateTime()); + context.setAccessUserProvider(() -> "unused"); + return context; + }; + } + + // =================================================================================== + // User Info + // ========= + @Override + protected OptionalThing getUserBean() { // to return as concrete class + return fessLoginAssist.getSessionUserBean(); + } + + @Override + protected String myAppType() { // for framework + return APP_TYPE; + } + + @Override + protected OptionalThing myUserType() { // for framework + return OptionalThing.of(USER_TYPE); // same reason as getUserBean() + } + + // =================================================================================== + // Validation + // ========== + @SuppressWarnings("unchecked") + @Override + public ActionValidator createValidator() { + return super.createValidator(); + } + + @Override + public FessMessages createMessages() { // application may call + return new FessMessages(); // overriding to change return type to concrete-class + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/base/FessSearchAction.java b/src/main/java/org/codelibs/fess/app/web/base/FessSearchAction.java new file mode 100644 index 000000000..a4eb3c16e --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/base/FessSearchAction.java @@ -0,0 +1,199 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.app.web.base; + +import java.util.ArrayList; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Locale; +import java.util.Map; + +import javax.annotation.Resource; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpSession; + +import org.apache.commons.lang3.StringEscapeUtils; +import org.codelibs.core.lang.StringUtil; +import org.codelibs.core.misc.DynamicProperties; +import org.codelibs.core.net.URLUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.entity.LoginInfo; +import org.codelibs.fess.es.client.FessEsClient; +import org.codelibs.fess.exception.UnsupportedSearchException; +import org.codelibs.fess.helper.FieldHelper; +import org.codelibs.fess.helper.LabelTypeHelper; +import org.codelibs.fess.helper.OpenSearchHelper; +import org.codelibs.fess.helper.QueryHelper; +import org.codelibs.fess.helper.RoleQueryHelper; +import org.codelibs.fess.helper.SystemHelper; +import org.codelibs.fess.helper.UserInfoHelper; +import org.codelibs.fess.helper.ViewHelper; +import org.codelibs.fess.screenshot.ScreenShotManager; +import org.dbflute.optional.OptionalThing; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.login.LoginManager; +import org.lastaflute.web.response.ActionResponse; +import org.lastaflute.web.util.LaRequestUtil; + +public abstract class FessSearchAction extends FessBaseAction { + + protected static final String LABEL_FIELD = "label"; + + @Resource + protected FessEsClient fessEsClient; + + @Resource + protected ScreenShotManager screenShotManager; + + @Resource + protected LabelTypeHelper labelTypeHelper; + + @Resource + protected ViewHelper viewHelper; + + @Resource + protected QueryHelper queryHelper; + + @Resource + protected RoleQueryHelper roleQueryHelper; + + @Resource + protected UserInfoHelper userInfoHelper; + + @Resource + protected SystemHelper systemHelper; + + @Resource + protected FieldHelper fieldHelper; + + @Resource + protected OpenSearchHelper openSearchHelper; + + @Resource + protected DynamicProperties crawlerProperties; + + @Resource + protected HttpServletRequest request; + + protected boolean searchLogSupport; + + protected boolean favoriteSupport; + + @Override + public ActionResponse hookBefore(final ActionRuntime runtime) { // application may override + searchLogSupport = Constants.TRUE.equals(crawlerProperties.getProperty(Constants.SEARCH_LOG_PROPERTY, Constants.TRUE)); + favoriteSupport = Constants.TRUE.equals(crawlerProperties.getProperty(Constants.USER_FAVORITE_PROPERTY, Constants.FALSE)); + runtime.registerData("searchLogSupport", searchLogSupport); + runtime.registerData("favoriteSupport", favoriteSupport); + return super.hookBefore(runtime); + } + + @Override + protected OptionalThing myLoginManager() { + return OptionalThing.empty(); + } + + @Override + protected void setupHtmlData(final ActionRuntime runtime) { + super.setupHtmlData(runtime); + runtime.registerData("osddLink", openSearchHelper.hasOpenSearchFile()); + runtime.registerData("helpPage", viewHelper.getPagePath("common/help")); + + final List> labelTypeItems = labelTypeHelper.getLabelTypeItemList(); + runtime.registerData("labelTypeItems", labelTypeItems); + runtime.registerData("displayLabelTypeItems", labelTypeItems != null && !labelTypeItems.isEmpty()); + + Locale locale = request.getLocale(); + if (locale == null) { + locale = Locale.ENGLISH; + } + runtime.registerData("langItems", systemHelper.getLanguageItems(locale)); + + final HttpSession session = request.getSession(false); + if (session != null) { + final Object obj = session.getAttribute(Constants.USER_INFO); + if (obj instanceof LoginInfo) { + final LoginInfo loginInfo = (LoginInfo) obj; + runtime.registerData("username", loginInfo.getUsername()); + } + } + } + + protected void searchAvailable() { + final String supportedSearch = + crawlerProperties.getProperty(Constants.SUPPORTED_SEARCH_FEATURE_PROPERTY, Constants.SUPPORTED_SEARCH_WEB); + if (Constants.SUPPORTED_SEARCH_NONE.equals(supportedSearch)) { + throw new UnsupportedSearchException("A search is not supported: " + LaRequestUtil.getRequest().getRequestURL()); + } + } + + protected void buildLabelParams(final Map fields) { + // label + final List> labelTypeItems = labelTypeHelper.getLabelTypeItemList(); + + if (!labelTypeItems.isEmpty() && !fields.containsKey(FessSearchAction.LABEL_FIELD)) { + final String defaultLabelValue = crawlerProperties.getProperty(Constants.DEFAULT_LABEL_VALUE_PROPERTY, StringUtil.EMPTY); + if (StringUtil.isNotBlank(defaultLabelValue)) { + final String[] values = defaultLabelValue.split("\n"); + if (values != null && values.length > 0) { + final List list = new ArrayList(values.length); + for (final String value : values) { + if (StringUtil.isNotBlank(value)) { + list.add(value); + } + } + if (!list.isEmpty()) { + fields.put(FessSearchAction.LABEL_FIELD, list.toArray(new String[list.size()])); + } + } + } + } + + final Map labelMap = new LinkedHashMap(); + if (!labelTypeItems.isEmpty()) { + for (final Map map : labelTypeItems) { + labelMap.put(map.get(Constants.ITEM_VALUE), map.get(Constants.ITEM_LABEL)); + } + } + request.setAttribute(Constants.LABEL_VALUE_MAP, labelMap); + } + + protected void buildInitParams() { + buildInitParamMap(viewHelper.getInitFacetParamMap(), Constants.FACET_QUERY, Constants.FACET_FORM); + buildInitParamMap(viewHelper.getInitGeoParamMap(), Constants.GEO_QUERY, Constants.GEO_FORM); + } + + protected void buildInitParamMap(final Map paramMap, final String queryKey, final String formKey) { + if (!paramMap.isEmpty()) { + final StringBuilder queryBuf = new StringBuilder(100); + final StringBuilder formBuf = new StringBuilder(100); + for (final Map.Entry entry : paramMap.entrySet()) { + queryBuf.append('&'); + queryBuf.append(URLUtil.encode(entry.getValue(), Constants.UTF_8)); + queryBuf.append('='); + queryBuf.append(URLUtil.encode(entry.getKey(), Constants.UTF_8)); + formBuf.append(""); + } + request.setAttribute(queryKey, queryBuf.toString()); + request.setAttribute(formKey, formBuf.toString()); + } + } + +} diff --git a/src/main/java/org/codelibs/fess/app/web/base/login/FessLoginAssist.java b/src/main/java/org/codelibs/fess/app/web/base/login/FessLoginAssist.java new file mode 100644 index 000000000..256e512a5 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/base/login/FessLoginAssist.java @@ -0,0 +1,127 @@ +/* + * Copyright 2012 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.app.web.base.login; + +import javax.annotation.Resource; + +import org.codelibs.fess.app.web.login.LoginAction; +import org.codelibs.fess.es.exbhv.UserBhv; +import org.codelibs.fess.es.exentity.User; +import org.codelibs.fess.mylasta.action.FessUserBean; +import org.codelibs.fess.mylasta.direction.FessConfig; +import org.dbflute.optional.OptionalEntity; +import org.dbflute.optional.OptionalThing; +import org.lastaflute.core.magic.async.AsyncManager; +import org.lastaflute.core.time.TimeManager; +import org.lastaflute.web.login.LoginHandlingResource; +import org.lastaflute.web.login.LoginManager; +import org.lastaflute.web.login.TypicalLoginAssist; +import org.lastaflute.web.login.exception.LoginRequiredException; +import org.lastaflute.web.login.option.LoginSpecifiedOption; + +/** + * @author jflute + * @author shinsuke + */ +public class FessLoginAssist extends TypicalLoginAssist // #change_it also UserBean + implements LoginManager { + + // =================================================================================== + // Attribute + // ========= + @Resource + private TimeManager timeManager; + @Resource + private AsyncManager asyncManager; + @Resource + private FessConfig fessConfig; + @Resource + private UserBhv userBhv; + + // =================================================================================== + // Find User + // ========= + @Override + protected boolean doCheckUserLoginable(final String username, final String cipheredPassword) { + return userBhv.selectCount(cb -> { + cb.query().setName_Equal(username); + cb.query().setPassword_Equal(cipheredPassword); + }) > 0; + } + + @Override + protected OptionalEntity doFindLoginUser(final String username, final String cipheredPassword) { + return userBhv.selectEntity(cb -> { + cb.query().setName_Equal(username); + cb.query().setPassword_Equal(cipheredPassword); + }); + } + + @Override + protected OptionalEntity doFindLoginUser(final String username) { + return userBhv.selectEntity(cb -> { + cb.query().setName_Equal(username); + }); + } + + // =================================================================================== + // Login Process + // ============= + @Override + protected FessUserBean createUserBean(final User user) { + return new FessUserBean(user); + } + + @Override + protected OptionalThing getCookieRememberMeKey() { + // example to use remember-me + //return OptionalThing.of(fessConfig.getCookieRememberMeFessKey()); + return OptionalThing.empty(); + } + + @Override + protected void saveLoginHistory(final User user, final FessUserBean userBean, final LoginSpecifiedOption option) { + asyncManager.async(() -> { + insertLogin(user); + }); + } + + protected void insertLogin(final Object member) { + } + + @Override + protected void checkPermission(final LoginHandlingResource resource) throws LoginRequiredException { + super.checkPermission(resource); + } + + // =================================================================================== + // Login Resource + // ============== + @Override + protected Class getUserBeanType() { + return FessUserBean.class; + } + + @Override + protected Class getLoginActionType() { + return LoginAction.class; + } + + @Override + protected String toTypedUserId(final String userKey) { + return userKey; + } +} diff --git a/src/main/java/org/codelibs/fess/app/web/cache/CacheAction.java b/src/main/java/org/codelibs/fess/app/web/cache/CacheAction.java new file mode 100644 index 000000000..4c845b84c --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/cache/CacheAction.java @@ -0,0 +1,81 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.cache; + +import java.util.Map; + +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.web.base.FessSearchAction; +import org.codelibs.fess.util.DocumentUtil; +import org.elasticsearch.index.query.QueryBuilders; +import org.elasticsearch.index.query.TermQueryBuilder; +import org.lastaflute.web.Execute; +import org.lastaflute.web.response.StreamResponse; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class CacheAction extends FessSearchAction { + + // =================================================================================== + // Constant + // + private static final Logger logger = LoggerFactory.getLogger(CacheAction.class); + + // =================================================================================== + // Attribute + // + + // =================================================================================== + // Hook + // ====== + + // =================================================================================== + // Search Execute + // ============== + @Execute + public StreamResponse index(final CacheForm form) { + searchAvailable(); + + Map doc = null; + try { + doc = fessEsClient.getDocument(fieldHelper.docIndex, fieldHelper.docType, queryRequestBuilder -> { + final TermQueryBuilder termQuery = QueryBuilders.termQuery(fieldHelper.docIdField, form.docId); + queryRequestBuilder.setQuery(termQuery); + queryRequestBuilder.addFields(queryHelper.getResponseFields()); + return true; + }).get(); + } catch (final Exception e) { + logger.warn("Failed to request: " + form.docId, e); + } + if (doc == null) { + throwValidationError(messages -> { + messages.addErrorsDocidNotFound(GLOBAL, form.docId); + }, () -> asHtml(path_ErrorJsp)); + } + + final String content = viewHelper.createCacheContent(doc, form.hq); + if (content == null) { + throwValidationError(messages -> { + messages.addErrorsDocidNotFound(GLOBAL, form.docId); + }, () -> asHtml(path_ErrorJsp)); + } + + return asStream(DocumentUtil.getValue(doc, fieldHelper.docIdField, String.class)).contentType("text/html; charset=UTF-8").data( + content.getBytes(Constants.CHARSET_UTF_8)); + } + +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/app/web/cache/CacheForm.java b/src/main/java/org/codelibs/fess/app/web/cache/CacheForm.java new file mode 100644 index 000000000..469295a89 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/cache/CacheForm.java @@ -0,0 +1,13 @@ +package org.codelibs.fess.app.web.cache; + +import org.codelibs.fess.app.web.RootForm; + +public class CacheForm extends RootForm { + private static final long serialVersionUID = 1L; + + //@Required(target = "go,cache") + //@Maxbytelength(maxbytelength = 100) + public String docId; + public String[] hq; + +} diff --git a/src/main/java/org/codelibs/fess/app/web/error/ErrorAction.java b/src/main/java/org/codelibs/fess/app/web/error/ErrorAction.java new file mode 100644 index 000000000..5f86b5f1b --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/error/ErrorAction.java @@ -0,0 +1,56 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.error; + +import org.codelibs.fess.app.web.base.FessSearchAction; +import org.lastaflute.web.Execute; +import org.lastaflute.web.response.HtmlResponse; + +public class ErrorAction extends FessSearchAction { + + // =================================================================================== + // Constant + // + + // =================================================================================== + // Attribute + // + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final ErrorForm form) { + return asHtml(path_Error_NotFoundJsp); + } + + @Execute + public HtmlResponse systemError(final ErrorForm form) { + return asHtml(path_Error_SystemJsp); + } + + @Execute + public HtmlResponse badRequest(final ErrorForm form) { + return asHtml(path_Error_BadRequestJsp); + } + + @Execute + public HtmlResponse notFound(final ErrorForm form) { + return asHtml(path_Error_NotFoundJsp); + } + +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/ErrorForm.java b/src/main/java/org/codelibs/fess/app/web/error/ErrorForm.java similarity index 94% rename from src/main/java/org/codelibs/fess/web/ErrorForm.java rename to src/main/java/org/codelibs/fess/app/web/error/ErrorForm.java index d53927591..a519b9e2e 100644 --- a/src/main/java/org/codelibs/fess/web/ErrorForm.java +++ b/src/main/java/org/codelibs/fess/app/web/error/ErrorForm.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web; +package org.codelibs.fess.app.web.error; import java.io.Serializable; @@ -23,4 +23,5 @@ public class ErrorForm implements Serializable { private static final long serialVersionUID = 1L; public String url; + } diff --git a/src/main/java/org/codelibs/fess/app/web/go/GoAction.java b/src/main/java/org/codelibs/fess/app/web/go/GoAction.java new file mode 100644 index 000000000..280f65008 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/go/GoAction.java @@ -0,0 +1,174 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.go; + +import java.awt.Desktop; +import java.io.File; +import java.io.IOException; +import java.io.UnsupportedEncodingException; +import java.net.URLEncoder; +import java.util.Map; + +import javax.servlet.http.HttpServletResponse; + +import org.codelibs.core.lang.StringUtil; +import org.codelibs.core.net.URLUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.web.base.FessSearchAction; +import org.codelibs.fess.es.exentity.ClickLog; +import org.codelibs.fess.helper.SearchLogHelper; +import org.codelibs.fess.helper.ViewHelper; +import org.codelibs.fess.util.ComponentUtil; +import org.codelibs.fess.util.DocumentUtil; +import org.codelibs.robot.util.CharUtil; +import org.elasticsearch.index.query.QueryBuilders; +import org.elasticsearch.index.query.TermQueryBuilder; +import org.lastaflute.web.Execute; +import org.lastaflute.web.response.ActionResponse; +import org.lastaflute.web.response.HtmlResponse; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class GoAction extends FessSearchAction { + + // =================================================================================== + // Constant + // + private static final Logger logger = LoggerFactory.getLogger(GoAction.class); + + // =================================================================================== + // Attribute + // + + // =================================================================================== + // Hook + // ====== + + // =================================================================================== + // Search Execute + // ============== + @Execute + public ActionResponse index(final GoForm form) throws IOException { + searchAvailable(); + + Map doc = null; + try { + doc = fessEsClient.getDocument(fieldHelper.docIndex, fieldHelper.docType, queryRequestBuilder -> { + final TermQueryBuilder termQuery = QueryBuilders.termQuery(fieldHelper.docIdField, form.docId); + queryRequestBuilder.setQuery(termQuery); + queryRequestBuilder.addFields(queryHelper.getResponseFields()); + return true; + }).get(); + } catch (final Exception e) { + logger.warn("Failed to request: " + form.docId, e); + } + if (doc == null) { + throwValidationError(messages -> { + messages.addErrorsDocidNotFound(GLOBAL, form.docId); + }, () -> asHtml(path_ErrorJsp)); + } + final String url = DocumentUtil.getValue(doc, fieldHelper.urlField, String.class); + if (url == null) { + throwValidationError(messages -> { + messages.addErrorsDocumentNotFound(GLOBAL, form.docId); + }, () -> asHtml(path_ErrorJsp)); + } + + if (Constants.TRUE.equals(crawlerProperties.getProperty(Constants.SEARCH_LOG_PROPERTY, Constants.TRUE))) { + final String userSessionId = userInfoHelper.getUserCode(); + if (userSessionId != null) { + final SearchLogHelper searchLogHelper = ComponentUtil.getSearchLogHelper(); + final ClickLog clickLog = new ClickLog(); + clickLog.setUrl(url); + final long now = systemHelper.getCurrentTimeAsLong(); + clickLog.setRequestedTime(now); + clickLog.setQueryRequestedTime(Long.parseLong(form.rt)); + clickLog.setUserSessionId(userSessionId); + clickLog.setDocId(form.docId); + long clickCount = 0; + final Integer count = DocumentUtil.getValue(doc, fieldHelper.clickCountField, Integer.class); + if (count != null) { + clickCount = count.longValue(); + } + clickLog.setClickCount(clickCount); + searchLogHelper.addClickLog(clickLog); + } + } + + String hash; + if (StringUtil.isNotBlank(form.hash)) { + final String value = URLUtil.decode(form.hash, Constants.UTF_8); + final StringBuilder buf = new StringBuilder(value.length() + 100); + for (final char c : value.toCharArray()) { + if (CharUtil.isUrlChar(c) || c == ' ') { + buf.append(c); + } else { + try { + buf.append(URLEncoder.encode(String.valueOf(c), Constants.UTF_8)); + } catch (final UnsupportedEncodingException e) { + // NOP + } + } + } + hash = buf.toString(); + } else { + hash = StringUtil.EMPTY; + } + + if (isFileSystemPath(url)) { + if (Constants.TRUE.equals(crawlerProperties.getProperty(Constants.SEARCH_FILE_PROXY_PROPERTY, Constants.TRUE))) { + final ViewHelper viewHelper = ComponentUtil.getViewHelper(); + try { + return viewHelper.asContentResponse(doc); + } catch (final Exception e) { + logger.error("Failed to load: " + doc, e); + throwValidationError(messages -> { + messages.addErrorsNotLoadFromServer(GLOBAL, url); + }, () -> asHtml(path_ErrorJsp)); + return null; // workaround + } + } else if (Constants.TRUE.equals(crawlerProperties.getProperty(Constants.SEARCH_DESKTOP_PROPERTY, Constants.FALSE))) { + final String path = url.replaceFirst("file:/+", "//"); + final File file = new File(path); + if (!file.exists()) { + throwValidationError(messages -> { + messages.addErrorsNotFoundOnFileSystem(GLOBAL, url); + }, () -> asHtml(path_ErrorJsp)); + } + final Desktop desktop = Desktop.getDesktop(); + try { + desktop.open(file); + } catch (final Exception e) { + logger.warn("Could not open " + path, e); + throwValidationError(messages -> { + messages.addErrorsCouldNotOpenOnSystem(GLOBAL, url); + }, () -> asHtml(path_ErrorJsp)); + } + + return HtmlResponse.asEmptyBody().httpStatus(HttpServletResponse.SC_NO_CONTENT); + } else { + return HtmlResponse.fromRedirectPathAsIs(url + hash); + } + } else { + return HtmlResponse.fromRedirectPathAsIs(url + hash); + } + } + + protected boolean isFileSystemPath(final String url) { + return url.startsWith("file:") || url.startsWith("smb:"); + } +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/app/web/go/GoForm.java b/src/main/java/org/codelibs/fess/app/web/go/GoForm.java new file mode 100644 index 000000000..d89cf9165 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/go/GoForm.java @@ -0,0 +1,15 @@ +package org.codelibs.fess.app.web.go; + +import org.codelibs.fess.app.web.RootForm; + +public class GoForm extends RootForm { + private static final long serialVersionUID = 1L; + + //@Required(target = "go,cache") + //@Maxbytelength(maxbytelength = 100) + public String docId; + + public String rt; + + public String hash; +} diff --git a/src/main/java/org/codelibs/fess/app/web/help/HelpAction.java b/src/main/java/org/codelibs/fess/app/web/help/HelpAction.java new file mode 100644 index 000000000..450c61c26 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/help/HelpAction.java @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.help; + +import org.codelibs.fess.app.web.base.FessSearchAction; +import org.lastaflute.web.Execute; +import org.lastaflute.web.response.HtmlResponse; + +public class HelpAction extends FessSearchAction { + + // =================================================================================== + // Constant + // + + // =================================================================================== + // Attribute + // + + // =================================================================================== + // Hook + // ====== + + // =================================================================================== + // Search Execute + // ============== + + @Execute + public HtmlResponse index(final HelpForm form) { + return asHtml(path_HelpJsp).renderWith(data -> { + buildLabelParams(form.fields); + buildInitParams(); + }); + } + +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/app/web/help/HelpForm.java b/src/main/java/org/codelibs/fess/app/web/help/HelpForm.java new file mode 100644 index 000000000..5a512c1f8 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/help/HelpForm.java @@ -0,0 +1,8 @@ +package org.codelibs.fess.app.web.help; + +import org.codelibs.fess.app.web.RootForm; + +public class HelpForm extends RootForm { + private static final long serialVersionUID = 1L; + +} diff --git a/src/main/java/org/codelibs/fess/app/web/login/LoginAction.java b/src/main/java/org/codelibs/fess/app/web/login/LoginAction.java new file mode 100644 index 000000000..642b0bac2 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/login/LoginAction.java @@ -0,0 +1,62 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.login; + +import org.codelibs.fess.app.web.admin.system.AdminSystemAction; +import org.codelibs.fess.app.web.base.FessSearchAction; +import org.lastaflute.web.Execute; +import org.lastaflute.web.response.HtmlResponse; + +public class LoginAction extends FessSearchAction { + + // =================================================================================== + // Constant + // + + // =================================================================================== + // Attribute + // + + // =================================================================================== + // Hook + // ====== + + // =================================================================================== + // Search Execute + // ============== + + @Execute + public HtmlResponse index() { + return getHtmlResponse().useForm(LoginForm.class); + } + + private HtmlResponse getHtmlResponse() { + return getUserBean().map(user -> redirect(AdminSystemAction.class)).orElse(asHtml(path_Login_IndexJsp)); + } + + @Execute + public HtmlResponse login(final LoginForm form) { + validate(form, messages -> {}, () -> { + form.clearSecurityInfo(); + return asHtml(path_Login_IndexJsp); + }); + final String email = form.username; + final String password = form.password; + return fessLoginAssist.loginRedirect(email, password, op -> {}, () -> getHtmlResponse()); + } + +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/app/web/login/LoginForm.java b/src/main/java/org/codelibs/fess/app/web/login/LoginForm.java new file mode 100644 index 000000000..40cef7998 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/login/LoginForm.java @@ -0,0 +1,19 @@ +package org.codelibs.fess.app.web.login; + +import org.codelibs.fess.app.web.RootForm; +import org.hibernate.validator.constraints.NotBlank; + +public class LoginForm extends RootForm { + private static final long serialVersionUID = 1L; + + @NotBlank + public String username; + + @NotBlank + public String password; + + public void clearSecurityInfo() { + password = null; + } + +} diff --git a/src/main/java/org/codelibs/fess/app/web/logout/LogoutAction.java b/src/main/java/org/codelibs/fess/app/web/logout/LogoutAction.java new file mode 100644 index 000000000..646d3cb10 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/logout/LogoutAction.java @@ -0,0 +1,48 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.logout; + +import org.codelibs.fess.app.web.base.FessSearchAction; +import org.codelibs.fess.app.web.login.LoginAction; +import org.lastaflute.web.Execute; +import org.lastaflute.web.response.HtmlResponse; + +public class LogoutAction extends FessSearchAction { + + // =================================================================================== + // Constant + // + + // =================================================================================== + // Attribute + // + + // =================================================================================== + // Hook + // ====== + + // =================================================================================== + // Search Execute + // ============== + + @Execute + public HtmlResponse index() { + fessLoginAssist.logout(); + return redirect(LoginAction.class); + } + +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/app/web/osdd/OsddAction.java b/src/main/java/org/codelibs/fess/app/web/osdd/OsddAction.java new file mode 100644 index 000000000..0c480023a --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/osdd/OsddAction.java @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.osdd; + +import org.codelibs.fess.app.web.base.FessSearchAction; +import org.lastaflute.web.Execute; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.util.LaResponseUtil; + +public class OsddAction extends FessSearchAction { + + // =================================================================================== + // Constant + // + + // =================================================================================== + // Attribute + // + + // =================================================================================== + // Hook + // ====== + + // =================================================================================== + // Search Execute + // ============== + + @Execute + public HtmlResponse index(final OsddForm form) { + searchAvailable(); + openSearchHelper.write(LaResponseUtil.getResponse()); + return null; + } + +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/app/web/osdd/OsddForm.java b/src/main/java/org/codelibs/fess/app/web/osdd/OsddForm.java new file mode 100644 index 000000000..978360e89 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/osdd/OsddForm.java @@ -0,0 +1,8 @@ +package org.codelibs.fess.app.web.osdd; + +import org.codelibs.fess.app.web.RootForm; + +public class OsddForm extends RootForm { + + private static final long serialVersionUID = 1L; +} diff --git a/src/main/java/org/codelibs/fess/app/web/screenshot/ScreenshotAction.java b/src/main/java/org/codelibs/fess/app/web/screenshot/ScreenshotAction.java new file mode 100644 index 000000000..ab449f48a --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/screenshot/ScreenshotAction.java @@ -0,0 +1,117 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.screenshot; + +import java.io.BufferedInputStream; +import java.io.File; +import java.io.FileInputStream; +import java.io.OutputStream; +import java.util.Map; + +import javax.annotation.Resource; +import javax.servlet.http.HttpServletResponse; + +import org.apache.commons.io.IOUtils; +import org.codelibs.core.io.CopyUtil; +import org.codelibs.core.io.OutputStreamUtil; +import org.codelibs.core.lang.StringUtil; +import org.codelibs.fess.app.web.base.FessSearchAction; +import org.codelibs.fess.util.DocumentUtil; +import org.elasticsearch.index.query.QueryBuilders; +import org.elasticsearch.index.query.TermQueryBuilder; +import org.lastaflute.web.Execute; +import org.lastaflute.web.response.HtmlResponse; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class ScreenshotAction extends FessSearchAction { + + // =================================================================================== + // Constant + // + private static final Logger logger = LoggerFactory.getLogger(ScreenshotAction.class); + + // =================================================================================== + // Attribute + // + @Resource + protected HttpServletResponse response; + + // =================================================================================== + // Hook + // ====== + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final ScreenshotForm form) { + searchAvailable(); + + OutputStream out = null; + BufferedInputStream in = null; + try { + final Map doc = fessEsClient.getDocument(fieldHelper.docIndex, fieldHelper.docType, queryRequestBuilder -> { + final TermQueryBuilder termQuery = QueryBuilders.termQuery(fieldHelper.docIdField, form.docId); + queryRequestBuilder.setQuery(termQuery); + queryRequestBuilder.addFields(queryHelper.getResponseFields()); + return true; + }).get(); + final String url = DocumentUtil.getValue(doc, fieldHelper.urlField, String.class); + if (StringUtil.isBlank(form.queryId) || StringUtil.isBlank(url) || screenShotManager == null) { + // 404 + response.sendError(HttpServletResponse.SC_NOT_FOUND); + return null; + } + + final File screenShotFile = screenShotManager.getScreenShotFile(form.queryId, form.docId); + if (screenShotFile == null) { + // 404 + response.sendError(HttpServletResponse.SC_NOT_FOUND); + screenShotManager.generate(doc); + return null; + } + + response.setContentType(getImageMimeType(screenShotFile)); + + out = response.getOutputStream(); + in = new BufferedInputStream(new FileInputStream(screenShotFile)); + CopyUtil.copy(in, out); + OutputStreamUtil.flush(out); + } catch (final Exception e) { + logger.error("Failed to response: " + form.docId, e); + } finally { + IOUtils.closeQuietly(in); + IOUtils.closeQuietly(out); + } + + return null; + } + + protected String getImageMimeType(final File imageFile) { + final String path = imageFile.getAbsolutePath(); + if (path.endsWith(".png")) { + return "image/png"; + } else if (path.endsWith(".gif")) { + return "image/gif"; + } else if (path.endsWith(".jpg") || path.endsWith(".jpeg")) { + return "image/jpeg"; + } else { + return "application/octet-stream"; + } + } +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/app/web/screenshot/ScreenshotForm.java b/src/main/java/org/codelibs/fess/app/web/screenshot/ScreenshotForm.java new file mode 100644 index 000000000..f3701b694 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/screenshot/ScreenshotForm.java @@ -0,0 +1,12 @@ +package org.codelibs.fess.app.web.screenshot; + +import org.codelibs.fess.app.web.RootForm; + +public class ScreenshotForm extends RootForm { + private static final long serialVersionUID = 1L; + + public String docId; + + public String queryId; + +} diff --git a/src/main/java/org/codelibs/fess/app/web/search/SearchAction.java b/src/main/java/org/codelibs/fess/app/web/search/SearchAction.java new file mode 100644 index 000000000..6e73eb524 --- /dev/null +++ b/src/main/java/org/codelibs/fess/app/web/search/SearchAction.java @@ -0,0 +1,570 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ + +package org.codelibs.fess.app.web.search; + +import java.text.NumberFormat; +import java.time.Clock; +import java.util.ArrayList; +import java.util.Enumeration; +import java.util.HashSet; +import java.util.List; +import java.util.Locale; +import java.util.Map; +import java.util.Set; +import java.util.regex.Matcher; +import java.util.regex.Pattern; + +import javax.servlet.http.HttpSession; + +import org.apache.commons.lang3.StringUtils; +import org.codelibs.core.lang.StringUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.app.web.RootAction; +import org.codelibs.fess.app.web.RootForm; +import org.codelibs.fess.app.web.base.FessSearchAction; +import org.codelibs.fess.es.client.FessEsClient.SearchConditionBuilder; +import org.codelibs.fess.es.exentity.SearchLog; +import org.codelibs.fess.es.exentity.UserInfo; +import org.codelibs.fess.exception.InvalidQueryException; +import org.codelibs.fess.exception.ResultOffsetExceededException; +import org.codelibs.fess.helper.SearchLogHelper; +import org.codelibs.fess.util.ComponentUtil; +import org.codelibs.fess.util.QueryResponseList; +import org.dbflute.optional.OptionalEntity; +import org.lastaflute.taglib.function.LaFunctions; +import org.lastaflute.web.Execute; +import org.lastaflute.web.response.HtmlResponse; +import org.lastaflute.web.response.render.RenderData; +import org.lastaflute.web.util.LaRequestUtil; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class SearchAction extends FessSearchAction { + + // =================================================================================== + // Constant + // + private static final Logger logger = LoggerFactory.getLogger(SearchAction.class); + + protected static final long DEFAULT_START_COUNT = 0; + + protected static final int MAX_PAGE_SIZE = 100; + + private static final int DEFAULT_PAGE_SIZE = 20; + + protected static final Pattern FIELD_EXTRACTION_PATTERN = Pattern.compile("^([a-zA-Z0-9_]+):.*"); + + // =================================================================================== + // Attribute + // + + // =================================================================================== + // Hook + // ====== + + // =================================================================================== + // Search Execute + // ============== + @Execute + public HtmlResponse index(final SearchForm form) { + return search(form); + } + + @Execute + public HtmlResponse search(final SearchForm form) { + if (viewHelper.isUseSession() && StringUtil.isNotBlank(form.num)) { + normalizePageNum(form); + final HttpSession session = request.getSession(); + if (session != null) { + session.setAttribute(Constants.RESULTS_PER_PAGE, form.num); + } + } + + return doSearch(form); + } + + @Execute + public HtmlResponse prev(final SearchForm form) { + return doMove(form, -1); + } + + @Execute + public HtmlResponse next(final SearchForm form) { + return doMove(form, 1); + } + + @Execute + public HtmlResponse move(final SearchForm form) { + return doMove(form, 0); + } + + protected HtmlResponse doSearch(final SearchForm form) { + searchAvailable(); + + if (viewHelper.isUseSession()) { + final HttpSession session = request.getSession(false); + if (session != null) { + final Object resultsPerPage = session.getAttribute(Constants.RESULTS_PER_PAGE); + if (resultsPerPage != null) { + form.num = resultsPerPage.toString(); + } + } + } + + if (StringUtil.isBlank(form.query)) { + try { + final String optionQuery = queryHelper.buildOptionQuery(form.options); + form.query = optionQuery; + } catch (final InvalidQueryException e) { + if (logger.isDebugEnabled()) { + logger.debug(e.getMessage(), e); + } + throwValidationError(e.getMessageCode(), () -> asHtml(path_ErrorJsp)); + } + } + + if (StringUtil.isBlank(form.query) && form.fields.isEmpty()) { + // redirect to index page + form.query = null; + return redirect(RootAction.class); + } + + return asHtml(path_SearchJsp).renderWith(data -> { + updateSearchParams(form); + buildLabelParams(form.fields); + doSearchInternal(data, form); + data.register("displayQuery", getDisplayQuery(form, labelTypeHelper.getLabelTypeItemList())); + data.register("pagingQuery", getPagingQuery(form)); + }); + } + + protected HtmlResponse doMove(final SearchForm form, final int move) { + int pageNum = getDefaultPageSize(); + if (StringUtil.isBlank(form.num)) { + form.num = String.valueOf(getDefaultPageSize()); + } else { + try { + pageNum = Integer.parseInt(form.num); + } catch (final NumberFormatException e) { + form.num = String.valueOf(getDefaultPageSize()); + } + } + + if (StringUtil.isBlank(form.pn)) { + form.start = String.valueOf(DEFAULT_START_COUNT); + } else { + Integer pageNumber = Integer.parseInt(form.pn); + if (pageNumber != null && pageNumber > 0) { + pageNumber = pageNumber + move; + if (pageNumber < 1) { + pageNumber = 1; + } + form.start = String.valueOf((pageNumber - 1) * pageNum); + } else { + form.start = String.valueOf(DEFAULT_START_COUNT); + } + } + + return doSearch(form); + } + + protected String doSearchInternal(final RenderData data, final SearchForm form) { + final StringBuilder queryBuf = new StringBuilder(255); + if (StringUtil.isNotBlank(form.query)) { + queryBuf.append(form.query); + } + if (StringUtil.isNotBlank(form.op)) { + request.setAttribute(Constants.DEFAULT_OPERATOR, form.op); + } + if (queryBuf.indexOf(" OR ") >= 0) { + queryBuf.insert(0, '(').append(')'); + } + if (form.additional != null) { + final Set fieldSet = new HashSet(); + for (final String additional : form.additional) { + if (StringUtil.isNotBlank(additional) && additional.length() < 1000 && !hasFieldInQuery(fieldSet, additional)) { + queryBuf.append(' ').append(additional); + } + } + } + if (!form.fields.isEmpty()) { + for (final Map.Entry entry : form.fields.entrySet()) { + final List valueList = new ArrayList(); + final String[] values = entry.getValue(); + if (values != null) { + for (final String v : values) { + valueList.add(v); + } + } + if (valueList.size() == 1) { + queryBuf.append(' ').append(entry.getKey()).append(":\"").append(valueList.get(0)).append('\"'); + } else if (valueList.size() > 1) { + queryBuf.append(" ("); + for (int i = 0; i < valueList.size(); i++) { + if (i != 0) { + queryBuf.append(" OR"); + } + queryBuf.append(' ').append(entry.getKey()).append(":\"").append(valueList.get(i)).append('\"'); + } + queryBuf.append(')'); + } + + } + } + if (StringUtil.isNotBlank(form.sort)) { + queryBuf.append(" sort:").append(form.sort); + } + if (form.lang != null) { + final Set langSet = new HashSet<>(); + for (final String lang : form.lang) { + if (StringUtil.isNotBlank(lang) && lang.length() < 1000) { + if (Constants.ALL_LANGUAGES.equalsIgnoreCase(lang)) { + langSet.add(Constants.ALL_LANGUAGES); + } else { + final String normalizeLang = systemHelper.normalizeLang(lang); + if (normalizeLang != null) { + langSet.add(normalizeLang); + } + } + } + } + if (langSet.size() > 1 && langSet.contains(Constants.ALL_LANGUAGES)) { + langSet.clear(); + form.lang = new String[] { Constants.ALL_LANGUAGES }; + } else { + langSet.remove(Constants.ALL_LANGUAGES); + } + appendLangQuery(queryBuf, langSet); + } else if (Constants.TRUE.equals(crawlerProperties.getProperty(Constants.USE_BROWSER_LOCALE_FOR_SEARCH_PROPERTY, Constants.FALSE))) { + final Set langSet = new HashSet<>(); + final Enumeration locales = request.getLocales(); + if (locales != null) { + while (locales.hasMoreElements()) { + final Locale locale = locales.nextElement(); + final String normalizeLang = systemHelper.normalizeLang(locale.toString()); + if (normalizeLang != null) { + langSet.add(normalizeLang); + } + } + if (!langSet.isEmpty()) { + appendLangQuery(queryBuf, langSet); + } + } + } + + final String query = queryBuf.toString().trim(); + + // init pager + if (StringUtil.isBlank(form.start)) { + form.start = String.valueOf(DEFAULT_START_COUNT); + } else { + try { + Integer.parseInt(form.start); + } catch (final NumberFormatException e) { + form.start = String.valueOf(DEFAULT_START_COUNT); + } + } + if (StringUtil.isBlank(form.num)) { + form.num = String.valueOf(getDefaultPageSize()); + } + normalizePageNum(form); + + final int pageStart = Integer.parseInt(form.start); + final int pageNum = Integer.parseInt(form.num); + List> documentItems = null; + try { + documentItems = + fessEsClient.search(fieldHelper.docIndex, fieldHelper.docType, + searchRequestBuilder -> { + return SearchConditionBuilder.builder(searchRequestBuilder).query(query).offset(pageStart).size(pageNum) + .facetInfo(form.facet).geoInfo(form.geo).responseFields(queryHelper.getResponseFields()).build(); + }, (searchRequestBuilder, execTime, searchResponse) -> { + final QueryResponseList queryResponseList = ComponentUtil.getQueryResponseList(); + queryResponseList.init(searchResponse, pageStart, pageNum); + return queryResponseList; + }); + } catch (final InvalidQueryException e) { + if (logger.isDebugEnabled()) { + logger.debug(e.getMessage(), e); + } + throwValidationError(e.getMessageCode(), () -> asHtml(path_ErrorJsp)); + } catch (final ResultOffsetExceededException e) { + if (logger.isDebugEnabled()) { + logger.debug(e.getMessage(), e); + } + throwValidationError(messages -> { + messages.addErrorsResultSizeExceeded(GLOBAL); + }, () -> asHtml(path_ErrorJsp)); + } + data.register("documentItems", documentItems); + + // search + final QueryResponseList queryResponseList = (QueryResponseList) documentItems; + data.register("facetResponse", queryResponseList.getFacetResponse()); + final NumberFormat nf = NumberFormat.getInstance(LaRequestUtil.getRequest().getLocale()); + nf.setMaximumIntegerDigits(2); + nf.setMaximumFractionDigits(2); + String execTime; + try { + execTime = nf.format((double) queryResponseList.getExecTime() / 1000); + } catch (final Exception e) { + execTime = StringUtil.EMPTY; + } + data.register("execTime", execTime); + + final Clock clock = Clock.systemDefaultZone(); + form.rt = Long.toString(clock.millis()); + + // favorite + if (favoriteSupport || screenShotManager != null) { + form.queryId = userInfoHelper.generateQueryId(query, documentItems); + if (screenShotManager != null) { + screenShotManager.storeRequest(form.queryId, documentItems); + data.register("screenShotSupport", true); + } + } + + // search log + if (searchLogSupport) { + final long now = systemHelper.getCurrentTimeAsLong(); + + final SearchLogHelper searchLogHelper = ComponentUtil.getSearchLogHelper(); + final SearchLog searchLog = new SearchLog(); + + String userCode = null; + if (Constants.TRUE.equals(crawlerProperties.getProperty(Constants.USER_INFO_PROPERTY, Constants.TRUE))) { + userCode = userInfoHelper.getUserCode(); + if (StringUtil.isNotBlank(userCode)) { + final UserInfo userInfo = new UserInfo(); + userInfo.setCode(userCode); + userInfo.setCreatedTime(now); + userInfo.setUpdatedTime(now); + searchLog.setUserInfo(OptionalEntity.of(userInfo)); + } + } + + searchLog.setHitCount(queryResponseList.getAllRecordCount()); + searchLog.setResponseTime(Integer.valueOf((int) queryResponseList.getExecTime())); + searchLog.setSearchWord(StringUtils.abbreviate(query, 1000)); + searchLog.setSearchQuery(StringUtils.abbreviate(queryResponseList.getSearchQuery(), 1000)); + searchLog.setRequestedTime(now); + searchLog.setQueryOffset(pageStart); + searchLog.setQueryPageSize(pageNum); + + searchLog.setClientIp(StringUtils.abbreviate(request.getRemoteAddr(), 50)); + searchLog.setReferer(StringUtils.abbreviate(request.getHeader("referer"), 1000)); + searchLog.setUserAgent(StringUtils.abbreviate(request.getHeader("user-agent"), 255)); + if (userCode != null) { + searchLog.setUserSessionId(userCode); + } + final Object accessType = request.getAttribute(Constants.SEARCH_LOG_ACCESS_TYPE); + if (Constants.SEARCH_LOG_ACCESS_TYPE_JSON.equals(accessType)) { + searchLog.setAccessType(Constants.SEARCH_LOG_ACCESS_TYPE_JSON); + } else if (Constants.SEARCH_LOG_ACCESS_TYPE_XML.equals(accessType)) { + searchLog.setAccessType(Constants.SEARCH_LOG_ACCESS_TYPE_XML); + } else if (Constants.SEARCH_LOG_ACCESS_TYPE_OTHER.equals(accessType)) { + searchLog.setAccessType(Constants.SEARCH_LOG_ACCESS_TYPE_OTHER); + } else { + searchLog.setAccessType(Constants.SEARCH_LOG_ACCESS_TYPE_WEB); + } + + @SuppressWarnings("unchecked") + final Map> fieldLogMap = (Map>) request.getAttribute(Constants.FIELD_LOGS); + if (fieldLogMap != null) { + for (final Map.Entry> logEntry : fieldLogMap.entrySet()) { + for (final String value : logEntry.getValue()) { + searchLog.addSearchFieldLogValue(logEntry.getKey(), StringUtils.abbreviate(value, 1000)); + } + } + } + + searchLogHelper.addSearchLog(searchLog); + } + + final String[] highlightQueries = (String[]) request.getAttribute(Constants.HIGHLIGHT_QUERIES); + if (highlightQueries != null) { + final StringBuilder buf = new StringBuilder(100); + for (final String q : highlightQueries) { + buf.append("&hq=").append(q); + } + data.register("appendHighlightQueries", buf.toString()); + } + + data.register("pageSize", queryResponseList.getPageSize()); + data.register("currentPageNumber", queryResponseList.getCurrentPageNumber()); + data.register("allRecordCount", queryResponseList.getAllRecordCount()); + data.register("allPageCount", queryResponseList.getAllPageCount()); + data.register("existNextPage", queryResponseList.isExistNextPage()); + data.register("existPrevPage", queryResponseList.isExistPrevPage()); + data.register("currentStartRecordNumber", queryResponseList.getCurrentStartRecordNumber()); + data.register("currentEndRecordNumber", queryResponseList.getCurrentEndRecordNumber()); + data.register("pageNumberList", queryResponseList.getPageNumberList()); + data.register("partialResults", queryResponseList.isPartialResults()); + // TODO + // data.register("queryTime", queryResponseList.get); + // data.register("searchTime", queryResponseList.get); + + return query; + } + + protected void appendLangQuery(final StringBuilder queryBuf, final Set langSet) { + if (langSet.size() == 1) { + queryBuf.append(' ').append(fieldHelper.langField).append(':').append(langSet.iterator().next()); + } else if (langSet.size() > 1) { + boolean first = true; + for (final String lang : langSet) { + if (first) { + queryBuf.append(" ("); + first = false; + } else { + queryBuf.append(" OR "); + } + queryBuf.append(fieldHelper.langField).append(':').append(lang); + } + queryBuf.append(')'); + } + } + + protected void updateSearchParams(final SearchForm form) { + if (form.facet == null) { + form.facet = queryHelper.getDefaultFacetInfo(); + } + + if (form.geo == null) { + form.geo = queryHelper.getDefaultGeoInfo(); + } + } + + protected String getDisplayQuery(final RootForm form, final List> labelTypeItems) { + final StringBuilder buf = new StringBuilder(100); + buf.append(form.query); + if (!form.fields.isEmpty() && form.fields.containsKey(LABEL_FIELD)) { + final String[] values = form.fields.get(LABEL_FIELD); + final List labelList = new ArrayList(); + if (values != null) { + for (final String v : values) { + labelList.add(v); + } + } + for (final String labelTypeValue : labelList) { + for (final Map map : labelTypeItems) { + if (map.get(Constants.ITEM_VALUE).equals(labelTypeValue)) { + buf.append(' '); + buf.append(map.get(Constants.ITEM_LABEL)); + break; + } + } + } + } + return buf.toString(); + } + + protected void normalizePageNum(final RootForm form) { + try { + final int num = Integer.parseInt(form.num); + if (num > getMaxPageSize()) { + // max page size + form.num = String.valueOf(getMaxPageSize()); + } else if (num <= 0) { + form.num = String.valueOf(getDefaultPageSize()); + } + } catch (final NumberFormatException e) { + form.num = String.valueOf(getDefaultPageSize()); + } + } + + protected int getDefaultPageSize() { + return DEFAULT_PAGE_SIZE; + } + + protected int getMaxPageSize() { + final Object maxPageSize = crawlerProperties.get(Constants.SEARCH_RESULT_MAX_PAGE_SIZE); + if (maxPageSize == null) { + return MAX_PAGE_SIZE; + } + try { + return Integer.parseInt(maxPageSize.toString()); + } catch (final NumberFormatException e) { + return MAX_PAGE_SIZE; + } + } + + protected boolean hasFieldInQuery(final Set fieldSet, final String query) { + final Matcher matcher = FIELD_EXTRACTION_PATTERN.matcher(query); + if (matcher.matches()) { + final String field = matcher.replaceFirst("$1"); + if (fieldSet.contains(field)) { + return true; + } + fieldSet.add(field); + } + return false; + } + + protected String getPagingQuery(final SearchForm form) { + final StringBuilder buf = new StringBuilder(200); + if (form.additional != null) { + final Set fieldSet = new HashSet(); + for (final String additional : form.additional) { + if (StringUtil.isNotBlank(additional) && additional.length() < 1000 && !hasFieldInQuery(fieldSet, additional)) { + buf.append("&additional=").append(LaFunctions.u(additional)); + } + } + } + if (StringUtil.isNotBlank(form.sort)) { + buf.append("&sort=").append(LaFunctions.u(form.sort)); + } + if (StringUtil.isNotBlank(form.op)) { + buf.append("&op=").append(LaFunctions.u(form.op)); + } + if (form.lang != null) { + final Set langSet = new HashSet(); + for (final String lang : form.lang) { + if (StringUtil.isNotBlank(lang) && lang.length() < 1000) { + if (Constants.ALL_LANGUAGES.equals(lang)) { + langSet.clear(); + break; + } + final String normalizeLang = systemHelper.normalizeLang(lang); + if (normalizeLang != null) { + langSet.add(normalizeLang); + } + } + } + if (!langSet.isEmpty()) { + for (final String lang : langSet) { + buf.append("&lang=").append(LaFunctions.u(lang)); + } + } + } + if (!form.fields.isEmpty()) { + for (final Map.Entry entry : form.fields.entrySet()) { + final String[] values = entry.getValue(); + if (values != null) { + for (final String v : values) { + if (StringUtil.isNotBlank(v)) { + buf.append("&fields.").append(LaFunctions.u(entry.getKey())).append('=').append(LaFunctions.u(v)); + } + } + } + } + } + + return buf.toString(); + } + +} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/IndexForm.java b/src/main/java/org/codelibs/fess/app/web/search/SearchForm.java similarity index 55% rename from src/main/java/org/codelibs/fess/web/IndexForm.java rename to src/main/java/org/codelibs/fess/app/web/search/SearchForm.java index 05114c0e5..2df128db3 100644 --- a/src/main/java/org/codelibs/fess/web/IndexForm.java +++ b/src/main/java/org/codelibs/fess/app/web/search/SearchForm.java @@ -14,76 +14,61 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.web; +package org.codelibs.fess.app.web.search; -import java.io.Serializable; +import java.util.HashMap; +import java.util.Map; +import org.codelibs.fess.app.web.RootForm; import org.codelibs.fess.entity.FacetInfo; import org.codelibs.fess.entity.GeoInfo; -import org.codelibs.fess.util.SearchParamMap; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; -public class IndexForm implements Serializable { +public class SearchForm extends RootForm { private static final long serialVersionUID = 1L; - @Maxbytelength(maxbytelength = 1000) - public String query; - public String additional[]; - @Maxbytelength(maxbytelength = 1000) - public String sort; - - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String op; - @IntegerType + //@IntegerType public String start; - @IntegerType + //@IntegerType public String pn; - @IntegerType - public String num; - - public String[] lang; - - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String queryId; - public SearchParamMap fields = new SearchParamMap(); - // response redirect - @Required(target = "go") - @Maxbytelength(maxbytelength = 4000) + //@Required(target = "go") + //@Maxbytelength(maxbytelength = 4000) public String rt; - @Required(target = "go,cache") - @Maxbytelength(maxbytelength = 100) + //@Required(target = "go,cache") + //@Maxbytelength(maxbytelength = 100) public String docId; public String[] hq; - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String hash; // xml/json - @Maxbytelength(maxbytelength = 20) + //@Maxbytelength(maxbytelength = 20) public String type; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String callback; public String[] fn; // hotsearchword - @Maxbytelength(maxbytelength = 100) + //@Maxbytelength(maxbytelength = 100) public String range; // geo @@ -96,6 +81,6 @@ public class IndexForm implements Serializable { // advance - public SearchParamMap options = new SearchParamMap(); + public Map options = new HashMap<>(); } diff --git a/src/main/java/org/codelibs/fess/beans/FessBeans.java b/src/main/java/org/codelibs/fess/beans/FessBeans.java deleted file mode 100644 index 52c4c7f6c..000000000 --- a/src/main/java/org/codelibs/fess/beans/FessBeans.java +++ /dev/null @@ -1,27 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.beans; - -public class FessBeans { - protected FessBeans() { - // nothing - } - - public static FessCopy copy(final Object src, final Object dest) { - return new FessCopy(src, dest); - } -} diff --git a/src/main/java/org/codelibs/fess/beans/FessCopy.java b/src/main/java/org/codelibs/fess/beans/FessCopy.java deleted file mode 100644 index 9f5924e83..000000000 --- a/src/main/java/org/codelibs/fess/beans/FessCopy.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.beans; - -import java.util.ArrayList; -import java.util.List; - -import org.seasar.framework.beans.util.Copy; - -public class FessCopy extends Copy { - - public FessCopy(final Object src, final Object dest) { - super(src, dest); - } - - public Copy excludesCommonColumns() { - return excludesCommonColumns(new CharSequence[0]); - } - - public Copy excludesCommonColumns(final CharSequence... propertyNames) { - final List list = new ArrayList(); - list.add("searchParams"); - list.add("mode"); - list.add("createdBy"); - list.add("createdTime"); - list.add("updatedBy"); - list.add("updatedTime"); - if (propertyNames.length > 0) { - for (final CharSequence propertyName : propertyNames) { - list.add(propertyName); - } - } - return super.excludes(list.toArray(new CharSequence[list.size()])); - } - - public Copy commonColumnDateConverter() { - return this; - } - -} diff --git a/src/main/java/org/codelibs/fess/beans/converter/LocalDateTimeConverter.java b/src/main/java/org/codelibs/fess/beans/converter/LocalDateTimeConverter.java deleted file mode 100644 index 4db1b34d8..000000000 --- a/src/main/java/org/codelibs/fess/beans/converter/LocalDateTimeConverter.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.beans.converter; - -import java.time.LocalDateTime; -import java.time.format.DateTimeFormatter; - -import org.seasar.framework.beans.Converter; -import org.seasar.framework.exception.EmptyRuntimeException; -import org.seasar.framework.util.StringUtil; - -public class LocalDateTimeConverter implements Converter { - - protected String pattern; - - public LocalDateTimeConverter(String pattern) { - if (StringUtil.isEmpty(pattern)) { - throw new EmptyRuntimeException("pattern"); - } - this.pattern = pattern; - } - - @Override - public Object getAsObject(String value) { - if (StringUtil.isEmpty(value)) { - return null; - } - return LocalDateTime.parse(value, DateTimeFormatter.ofPattern(pattern)); - } - - @Override - public String getAsString(Object value) { - return ((LocalDateTime) value).format(DateTimeFormatter.ofPattern(pattern)); - } - - @Override - public boolean isTarget(Class clazz) { - return clazz == LocalDateTime.class; - } - -} diff --git a/src/main/java/org/codelibs/fess/client/FessEsClientException.java b/src/main/java/org/codelibs/fess/client/FessEsClientException.java deleted file mode 100644 index b149bec11..000000000 --- a/src/main/java/org/codelibs/fess/client/FessEsClientException.java +++ /dev/null @@ -1,17 +0,0 @@ -package org.codelibs.fess.client; - -import org.codelibs.fess.FessSystemException; - -public class FessEsClientException extends FessSystemException { - - private static final long serialVersionUID = 1L; - - public FessEsClientException(String message, Throwable cause) { - super(message, cause); - } - - public FessEsClientException(String message) { - super(message); - } - -} diff --git a/src/main/java/org/codelibs/fess/robot/FessS2RobotThread.java b/src/main/java/org/codelibs/fess/crawler/FessS2RobotThread.java similarity index 91% rename from src/main/java/org/codelibs/fess/robot/FessS2RobotThread.java rename to src/main/java/org/codelibs/fess/crawler/FessS2RobotThread.java index 4ec91fea9..25155166e 100644 --- a/src/main/java/org/codelibs/fess/robot/FessS2RobotThread.java +++ b/src/main/java/org/codelibs/fess/crawler/FessS2RobotThread.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.robot; +package org.codelibs.fess.crawler; import java.util.ArrayList; import java.util.Date; @@ -28,7 +28,7 @@ import java.util.Set; import org.apache.commons.io.IOUtils; import org.codelibs.core.misc.DynamicProperties; import org.codelibs.fess.Constants; -import org.codelibs.fess.client.FessEsClient; +import org.codelibs.fess.es.client.FessEsClient; import org.codelibs.fess.es.exentity.CrawlingConfig; import org.codelibs.fess.helper.CrawlingConfigHelper; import org.codelibs.fess.helper.CrawlingSessionHelper; @@ -100,25 +100,25 @@ public class FessS2RobotThread extends S2RobotThread { dataMap.put(fieldHelper.roleField, roleTypeList); final String id = crawlingSessionHelper.generateId(dataMap); - final Map solrDocument = - indexingHelper.getSolrDocument(fessEsClient, id, new String[] { fieldHelper.idField, fieldHelper.lastModifiedField, + final Map document = + indexingHelper.getDocument(fessEsClient, id, new String[] { fieldHelper.idField, fieldHelper.lastModifiedField, fieldHelper.anchorField, fieldHelper.segmentField, fieldHelper.expiresField, fieldHelper.clickCountField, fieldHelper.favoriteCountField }); - if (solrDocument == null) { + if (document == null) { storeChildUrlsToQueue(urlQueue, getChildUrlSet(fessEsClient, id)); return true; } - final Date expires = (Date) solrDocument.get(fieldHelper.expiresField); + final Date expires = (Date) document.get(fieldHelper.expiresField); if (expires != null && expires.getTime() < System.currentTimeMillis()) { - final Object idValue = solrDocument.get(fieldHelper.idField); + final Object idValue = document.get(fieldHelper.idField); if (idValue != null) { indexingHelper.deleteDocument(fessEsClient, idValue.toString()); } return true; } - final Date lastModified = (Date) solrDocument.get(fieldHelper.lastModifiedField); + final Date lastModified = (Date) document.get(fieldHelper.lastModifiedField); if (lastModified == null) { return true; } @@ -133,7 +133,7 @@ public class FessS2RobotThread extends S2RobotThread { final int httpStatusCode = responseData.getHttpStatusCode(); if (httpStatusCode == 404) { - storeChildUrlsToQueue(urlQueue, getAnchorSet(solrDocument.get(fieldHelper.anchorField))); + storeChildUrlsToQueue(urlQueue, getAnchorSet(document.get(fieldHelper.anchorField))); indexingHelper.deleteDocument(fessEsClient, id); return false; } else if (responseData.getLastModified() == null) { @@ -148,7 +148,7 @@ public class FessS2RobotThread extends S2RobotThread { responseData.setHttpStatusCode(org.codelibs.robot.Constants.NOT_MODIFIED_STATUS); processResponse(urlQueue, responseData); - storeChildUrlsToQueue(urlQueue, getAnchorSet(solrDocument.get(fieldHelper.anchorField))); + storeChildUrlsToQueue(urlQueue, getAnchorSet(document.get(fieldHelper.anchorField))); return false; } @@ -197,12 +197,12 @@ public class FessS2RobotThread extends S2RobotThread { final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); final IndexingHelper indexingHelper = ComponentUtil.getIndexingHelper(); final List> docList = - indexingHelper.getChildSolrDocumentList(fessEsClient, id, new String[] { fieldHelper.urlField }); + indexingHelper.getChildDocumentList(fessEsClient, id, new String[] { fieldHelper.urlField }); if (docList.isEmpty()) { return null; } if (logger.isDebugEnabled()) { - logger.debug("Found solr documents: " + docList); + logger.debug("Found documents: " + docList); } final Set urlSet = new HashSet<>(docList.size()); for (final Map doc : docList) { diff --git a/src/main/java/org/codelibs/fess/interval/FessIntervalController.java b/src/main/java/org/codelibs/fess/crawler/interval/FessIntervalController.java similarity index 98% rename from src/main/java/org/codelibs/fess/interval/FessIntervalController.java rename to src/main/java/org/codelibs/fess/crawler/interval/FessIntervalController.java index 388e63055..d9a0f68c7 100644 --- a/src/main/java/org/codelibs/fess/interval/FessIntervalController.java +++ b/src/main/java/org/codelibs/fess/crawler/interval/FessIntervalController.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.interval; +package org.codelibs.fess.crawler.interval; import org.codelibs.fess.helper.IntervalControlHelper; import org.codelibs.fess.util.ComponentUtil; diff --git a/src/main/java/org/codelibs/fess/transformer/AbstractFessFileTransformer.java b/src/main/java/org/codelibs/fess/crawler/transformer/AbstractFessFileTransformer.java similarity index 91% rename from src/main/java/org/codelibs/fess/transformer/AbstractFessFileTransformer.java rename to src/main/java/org/codelibs/fess/crawler/transformer/AbstractFessFileTransformer.java index add3ef132..29ad610cb 100644 --- a/src/main/java/org/codelibs/fess/transformer/AbstractFessFileTransformer.java +++ b/src/main/java/org/codelibs/fess/crawler/transformer/AbstractFessFileTransformer.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.transformer; +package org.codelibs.fess.crawler.transformer; import java.io.InputStream; import java.io.UnsupportedEncodingException; @@ -29,9 +29,11 @@ import java.util.Map; import java.util.Set; import org.apache.commons.io.IOUtils; -import org.apache.commons.lang.StringUtils; +import org.apache.commons.lang3.StringUtils; import org.apache.tika.metadata.HttpHeaders; import org.apache.tika.metadata.TikaMetadataKeys; +import org.codelibs.core.collection.LruHashMap; +import org.codelibs.core.io.SerializeUtil; import org.codelibs.core.lang.StringUtil; import org.codelibs.core.misc.DynamicProperties; import org.codelibs.fess.Constants; @@ -44,23 +46,19 @@ import org.codelibs.fess.helper.FileTypeHelper; import org.codelibs.fess.helper.LabelTypeHelper; import org.codelibs.fess.helper.PathMappingHelper; import org.codelibs.fess.helper.SambaHelper; -import org.codelibs.fess.taglib.FessFunctions; +import org.codelibs.fess.helper.SystemHelper; import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.robot.RobotCrawlAccessException; -import org.codelibs.robot.RobotSystemException; import org.codelibs.robot.client.smb.SmbClient; -import org.codelibs.robot.db.cbean.AccessResultDataCB; -import org.codelibs.robot.db.exbhv.AccessResultDataBhv; +import org.codelibs.robot.entity.AccessResult; import org.codelibs.robot.entity.AccessResultData; import org.codelibs.robot.entity.ExtractData; import org.codelibs.robot.entity.ResponseData; import org.codelibs.robot.entity.ResultData; import org.codelibs.robot.entity.UrlQueue; +import org.codelibs.robot.exception.RobotCrawlAccessException; +import org.codelibs.robot.exception.RobotSystemException; import org.codelibs.robot.extractor.Extractor; import org.codelibs.robot.util.CrawlingParameterUtil; -import org.codelibs.robot.util.LruHashMap; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.framework.util.SerializeUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -133,12 +131,12 @@ public abstract class AbstractFessFileTransformer extends AbstractFessXpathTrans if (StringUtil.isNotBlank(joinValue)) { contentMetaBuf.append(joinValue); if (metaContentMapping != null) { - final String solrField = metaContentMapping.get(key); - if (StringUtil.isNotBlank(solrField)) { - if (solrField.endsWith("_m")) { - dataMap.put(solrField, values); + final String dynamicField = metaContentMapping.get(key); + if (StringUtil.isNotBlank(dynamicField)) { + if (dynamicField.endsWith("_m")) { + dataMap.put(dynamicField, values); } else { - dataMap.put(solrField, joinValue); + dataMap.put(dynamicField, joinValue); } } } @@ -170,6 +168,7 @@ public abstract class AbstractFessFileTransformer extends AbstractFessXpathTrans final CrawlingConfigHelper crawlingConfigHelper = ComponentUtil.getCrawlingConfigHelper(); final CrawlingConfig crawlingConfig = crawlingConfigHelper.get(responseData.getSessionId()); final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); + final SystemHelper systemHelper = ComponentUtil.getSystemHelper(); final FileTypeHelper fileTypeHelper = ComponentUtil.getFileTypeHelper(); String url = responseData.getUrl(); final String indexingTarget = crawlingConfig.getIndexingTarget(url); @@ -178,7 +177,7 @@ public abstract class AbstractFessFileTransformer extends AbstractFessXpathTrans final Map fieldConfigMap = crawlingConfig.getConfigParameterMap(ConfigName.FIELD); String urlEncoding; - final UrlQueue urlQueue = CrawlingParameterUtil.getUrlQueue(); + final UrlQueue urlQueue = CrawlingParameterUtil.getUrlQueue(); if (urlQueue != null && urlQueue.getEncoding() != null) { urlEncoding = urlQueue.getEncoding(); } else { @@ -247,7 +246,7 @@ public abstract class AbstractFessFileTransformer extends AbstractFessXpathTrans // url putResultDataBody(dataMap, fieldHelper.urlField, url); // created - putResultDataBody(dataMap, fieldHelper.createdField, Constants.NOW); + putResultDataBody(dataMap, fieldHelper.createdField, systemHelper.getCurrentTime()); // TODO anchor putResultDataBody(dataMap, fieldHelper.anchorField, StringUtil.EMPTY); // mimetype @@ -260,7 +259,7 @@ public abstract class AbstractFessFileTransformer extends AbstractFessXpathTrans putResultDataBody(dataMap, fieldHelper.contentLengthField, Long.toString(responseData.getContentLength())); // lastModified if (responseData.getLastModified() != null) { - putResultDataBody(dataMap, fieldHelper.lastModifiedField, FessFunctions.formatDate(responseData.getLastModified())); + putResultDataBody(dataMap, fieldHelper.lastModifiedField, responseData.getLastModified()); } // indexingTarget putResultDataBody(dataMap, Constants.INDEXING_TARGET, indexingTarget); @@ -370,7 +369,7 @@ public abstract class AbstractFessFileTransformer extends AbstractFessXpathTrans String enc = Constants.UTF_8; if (encoding == null) { - final UrlQueue urlQueue = CrawlingParameterUtil.getUrlQueue(); + final UrlQueue urlQueue = CrawlingParameterUtil.getUrlQueue(); if (urlQueue != null) { final String parentUrl = urlQueue.getParentUrl(); if (StringUtil.isNotEmpty(parentUrl)) { @@ -402,15 +401,14 @@ public abstract class AbstractFessFileTransformer extends AbstractFessXpathTrans return enc; } - final AccessResultDataCB cb = new AccessResultDataCB(); - cb.query().queryAccessResult().setSessionId_Equal(sessionId); - cb.query().queryAccessResult().setUrl_Equal(parentUrl); - cb.specify().columnEncoding(); - final AccessResultData accessResultData = SingletonS2Container.getComponent(AccessResultDataBhv.class).selectEntity(cb); - if (accessResultData != null && accessResultData.getEncoding() != null) { - enc = accessResultData.getEncoding(); - parentEncodingMap.put(key, enc); - return enc; + final AccessResult accessResult = ComponentUtil.getDataService().getAccessResult(sessionId, parentUrl); + if (accessResult != null) { + final AccessResultData accessResultData = accessResult.getAccessResultData(); + if (accessResultData != null && accessResultData.getEncoding() != null) { + enc = accessResultData.getEncoding(); + parentEncodingMap.put(key, enc); + return enc; + } } return null; } @@ -462,7 +460,7 @@ public abstract class AbstractFessFileTransformer extends AbstractFessXpathTrans } @Override - public Object getData(final AccessResultData accessResultData) { + public Object getData(final AccessResultData accessResultData) { final byte[] data = accessResultData.getData(); if (data != null) { try { @@ -474,10 +472,10 @@ public abstract class AbstractFessFileTransformer extends AbstractFessXpathTrans return new HashMap(); } - public void addMetaContentMapping(final String metaname, final String solrField) { + public void addMetaContentMapping(final String metaname, final String dynamicField) { if (metaContentMapping == null) { metaContentMapping = new HashMap(); } - metaContentMapping.put(metaname, solrField); + metaContentMapping.put(metaname, dynamicField); } } diff --git a/src/main/java/org/codelibs/fess/transformer/AbstractFessXpathTransformer.java b/src/main/java/org/codelibs/fess/crawler/transformer/AbstractFessXpathTransformer.java similarity index 95% rename from src/main/java/org/codelibs/fess/transformer/AbstractFessXpathTransformer.java rename to src/main/java/org/codelibs/fess/crawler/transformer/AbstractFessXpathTransformer.java index 1af600d1f..343a3e53b 100644 --- a/src/main/java/org/codelibs/fess/transformer/AbstractFessXpathTransformer.java +++ b/src/main/java/org/codelibs/fess/crawler/transformer/AbstractFessXpathTransformer.java @@ -14,22 +14,24 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.transformer; +package org.codelibs.fess.crawler.transformer; import java.net.URLDecoder; import java.util.Arrays; import java.util.HashMap; import java.util.Map; -import org.apache.commons.lang.StringUtils; +import org.apache.commons.lang3.StringUtils; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.helper.FieldHelper; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.robot.transformer.impl.XpathTransformer; -import org.seasar.framework.util.OgnlUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import groovy.lang.Binding; +import groovy.lang.GroovyShell; + public abstract class AbstractFessXpathTransformer extends XpathTransformer { private static final Logger logger = LoggerFactory.getLogger(AbstractFessXpathTransformer.class); @@ -178,8 +180,7 @@ public abstract class AbstractFessXpathTransformer extends XpathTransformer { } try { - final Object exp = OgnlUtil.parseExpression(template); - final Object value = OgnlUtil.getValue(exp, paramMap); + final Object value = new GroovyShell(new Binding(paramMap)).evaluate(template); if (value == null) { return null; } diff --git a/src/main/java/org/codelibs/fess/transformer/FessFileTransformer.java b/src/main/java/org/codelibs/fess/crawler/transformer/FessFileTransformer.java similarity index 93% rename from src/main/java/org/codelibs/fess/transformer/FessFileTransformer.java rename to src/main/java/org/codelibs/fess/crawler/transformer/FessFileTransformer.java index cb4032f15..4a538cfe5 100644 --- a/src/main/java/org/codelibs/fess/transformer/FessFileTransformer.java +++ b/src/main/java/org/codelibs/fess/crawler/transformer/FessFileTransformer.java @@ -14,9 +14,9 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.transformer; +package org.codelibs.fess.crawler.transformer; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.robot.entity.ResponseData; import org.codelibs.robot.extractor.Extractor; diff --git a/src/main/java/org/codelibs/fess/transformer/FessTikaTransformer.java b/src/main/java/org/codelibs/fess/crawler/transformer/FessTikaTransformer.java similarity index 82% rename from src/main/java/org/codelibs/fess/transformer/FessTikaTransformer.java rename to src/main/java/org/codelibs/fess/crawler/transformer/FessTikaTransformer.java index a90c51a18..86e6c8b14 100644 --- a/src/main/java/org/codelibs/fess/transformer/FessTikaTransformer.java +++ b/src/main/java/org/codelibs/fess/crawler/transformer/FessTikaTransformer.java @@ -14,17 +14,17 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.transformer; +package org.codelibs.fess.crawler.transformer; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; import org.codelibs.robot.entity.ResponseData; import org.codelibs.robot.extractor.Extractor; -import org.seasar.framework.container.SingletonS2Container; +import org.lastaflute.di.core.SingletonLaContainer; public class FessTikaTransformer extends AbstractFessFileTransformer { @Override protected Extractor getExtractor(final ResponseData responseData) { - final Extractor extractor = SingletonS2Container.getComponent("tikaExtractor"); + final Extractor extractor = SingletonLaContainer.getComponent("tikaExtractor"); if (extractor == null) { throw new FessSystemException("Could not find tikaExtractor."); } diff --git a/src/main/java/org/codelibs/fess/transformer/FessXpathTransformer.java b/src/main/java/org/codelibs/fess/crawler/transformer/FessXpathTransformer.java similarity index 97% rename from src/main/java/org/codelibs/fess/transformer/FessXpathTransformer.java rename to src/main/java/org/codelibs/fess/crawler/transformer/FessXpathTransformer.java index 3e116d857..ef6873444 100644 --- a/src/main/java/org/codelibs/fess/transformer/FessXpathTransformer.java +++ b/src/main/java/org/codelibs/fess/crawler/transformer/FessXpathTransformer.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.transformer; +package org.codelibs.fess.crawler.transformer; import java.io.BufferedInputStream; import java.io.File; @@ -33,8 +33,10 @@ import java.util.Set; import javax.xml.transform.TransformerException; import org.apache.commons.io.IOUtils; -import org.apache.commons.lang.StringUtils; +import org.apache.commons.lang3.StringUtils; import org.apache.xpath.objects.XObject; +import org.codelibs.core.io.InputStreamUtil; +import org.codelibs.core.io.SerializeUtil; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; import org.codelibs.fess.es.exentity.CrawlingConfig; @@ -47,22 +49,19 @@ import org.codelibs.fess.helper.LabelTypeHelper; import org.codelibs.fess.helper.OverlappingHostHelper; import org.codelibs.fess.helper.PathMappingHelper; import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.taglib.FessFunctions; import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.robot.RobotCrawlAccessException; -import org.codelibs.robot.RobotSystemException; import org.codelibs.robot.builder.RequestDataBuilder; -import org.codelibs.robot.client.fs.ChildUrlsException; import org.codelibs.robot.entity.AccessResultData; import org.codelibs.robot.entity.RequestData; import org.codelibs.robot.entity.ResponseData; import org.codelibs.robot.entity.ResultData; import org.codelibs.robot.entity.UrlQueue; +import org.codelibs.robot.exception.ChildUrlsException; +import org.codelibs.robot.exception.RobotCrawlAccessException; +import org.codelibs.robot.exception.RobotSystemException; import org.codelibs.robot.util.CrawlingParameterUtil; import org.codelibs.robot.util.ResponseDataUtil; import org.cyberneko.html.parsers.DOMParser; -import org.seasar.framework.util.InputStreamUtil; -import org.seasar.framework.util.SerializeUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.w3c.dom.Document; @@ -210,7 +209,7 @@ public class FessXpathTransformer extends AbstractFessXpathTransformer { final Map fieldConfigMap = crawlingConfig.getConfigParameterMap(ConfigName.FIELD); String urlEncoding; - final UrlQueue urlQueue = CrawlingParameterUtil.getUrlQueue(); + final UrlQueue urlQueue = CrawlingParameterUtil.getUrlQueue(); if (urlQueue != null && urlQueue.getEncoding() != null) { urlEncoding = urlQueue.getEncoding(); } else { @@ -259,7 +258,7 @@ public class FessXpathTransformer extends AbstractFessXpathTransformer { // url putResultDataBody(dataMap, fieldHelper.urlField, url); // created - putResultDataBody(dataMap, fieldHelper.createdField, Constants.NOW); + putResultDataBody(dataMap, fieldHelper.createdField, systemHelper.getCurrentTime()); // anchor putResultDataBody(dataMap, fieldHelper.anchorField, getAnchorList(document, responseData)); // mimetype @@ -273,7 +272,7 @@ public class FessXpathTransformer extends AbstractFessXpathTransformer { putResultDataBody(dataMap, fieldHelper.contentLengthField, Long.toString(responseData.getContentLength())); // lastModified if (responseData.getLastModified() != null) { - putResultDataBody(dataMap, fieldHelper.lastModifiedField, FessFunctions.formatDate(responseData.getLastModified())); + putResultDataBody(dataMap, fieldHelper.lastModifiedField, responseData.getLastModified()); } // indexingTarget putResultDataBody(dataMap, Constants.INDEXING_TARGET, indexingTarget); @@ -495,7 +494,7 @@ public class FessXpathTransformer extends AbstractFessXpathTransformer { } @Override - public Object getData(final AccessResultData accessResultData) { + public Object getData(final AccessResultData accessResultData) { final byte[] data = accessResultData.getData(); if (data != null) { try { diff --git a/src/main/java/org/codelibs/fess/crud/CommonConstants.java b/src/main/java/org/codelibs/fess/crud/CommonConstants.java deleted file mode 100644 index a38b9531f..000000000 --- a/src/main/java/org/codelibs/fess/crud/CommonConstants.java +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.crud; - -public class CommonConstants { - public static final int LIST_MODE = 0; - - public static final int CREATE_MODE = 1; - - public static final int EDIT_MODE = 2; - - public static final int DELETE_MODE = 3; - - public static final int CONFIRM_MODE = 4; - - public static final String TIMESTAMP_PATTERN = "yyyy/MM/dd HH:mm:ss"; - - public static final String TRUE = "T"; - - public static final String FALSE = "F"; - - public static final String[] PAGER_CONVERSION_RULE = { "allRecordCount", "pageSize", "currentPageNumber", "allPageCount", - "existPrePage", "existNextPage" }; - - protected CommonConstants() { - // nothing - } -} diff --git a/src/main/java/org/codelibs/fess/crud/CrudMessageException.java b/src/main/java/org/codelibs/fess/crud/CrudMessageException.java deleted file mode 100644 index ea12012d6..000000000 --- a/src/main/java/org/codelibs/fess/crud/CrudMessageException.java +++ /dev/null @@ -1,95 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.crud; - -/** - * @author shinsuke - */ -public class CrudMessageException extends RuntimeException { - - /** - * Serial Version UID - */ - private static final long serialVersionUID = 4564000116499132363L; - - private final String messageId; - - private final Object[] args; - - /** - * @return Returns the messageId. - */ - public String getMessageId() { - return messageId; - } - - /** - * @return Returns the args. - */ - public Object[] getArgs() { - return args; - } - - public CrudMessageException(final String messageId) { - super(messageId); - this.messageId = messageId; - args = null; - } - - public CrudMessageException(final String messageId, final Object[] args) { - super(messageId); - this.messageId = messageId; - this.args = args; - } - - public CrudMessageException(final String messageId, final String message, final Throwable cause) { - super(message, cause); - this.messageId = messageId; - args = null; - } - - public CrudMessageException(final String messageId, final Object[] args, final String message, final Throwable cause) { - super(message, cause); - this.messageId = messageId; - this.args = args; - } - - public CrudMessageException(final String messageId, final String message) { - super(message); - this.messageId = messageId; - args = null; - } - - public CrudMessageException(final String messageId, final Object[] args, final String message) { - super(message); - this.messageId = messageId; - this.args = args; - } - - public CrudMessageException(final String messageId, final Throwable cause) { - super(cause); - this.messageId = messageId; - args = null; - } - - public CrudMessageException(final String messageId, final Object[] args, final Throwable cause) { - super(cause); - this.messageId = messageId; - this.args = args; - } - -} diff --git a/src/main/java/org/codelibs/fess/crud/util/SAStrutsUtil.java b/src/main/java/org/codelibs/fess/crud/util/SAStrutsUtil.java deleted file mode 100644 index 82fde7f96..000000000 --- a/src/main/java/org/codelibs/fess/crud/util/SAStrutsUtil.java +++ /dev/null @@ -1,70 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.crud.util; - -import javax.servlet.http.HttpServletRequest; - -import org.apache.struts.action.ActionMessage; -import org.apache.struts.action.ActionMessages; -import org.seasar.struts.util.ActionMessagesUtil; -import org.seasar.struts.util.RequestUtil; - -public class SAStrutsUtil { - protected SAStrutsUtil() { - // nothing - } - - public static void addMessage(final String key) { - addMessage(RequestUtil.getRequest(), key); - } - - public static void addMessage(final HttpServletRequest request, final String key) { - final ActionMessages msgs = new ActionMessages(); - msgs.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(key)); - ActionMessagesUtil.saveMessages(request, msgs); - } - - public static void addMessage(final String key, final Object... values) { - addMessage(RequestUtil.getRequest(), key, values); - } - - public static void addMessage(final HttpServletRequest request, final String key, final Object... values) { - final ActionMessages msgs = new ActionMessages(); - msgs.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(key, values)); - ActionMessagesUtil.saveMessages(request, msgs); - } - - public static void addSessionMessage(final String key) { - addSessionMessage(RequestUtil.getRequest(), key); - } - - public static void addSessionMessage(final HttpServletRequest request, final String key) { - final ActionMessages msgs = new ActionMessages(); - msgs.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(key)); - ActionMessagesUtil.saveMessages(request.getSession(), msgs); - } - - public static void addSessionMessage(final String key, final Object... values) { - addSessionMessage(RequestUtil.getRequest(), key, values); - } - - public static void addSessionMessage(final HttpServletRequest request, final String key, final Object... values) { - final ActionMessages msgs = new ActionMessages(); - msgs.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(key, values)); - ActionMessagesUtil.saveMessages(request.getSession(), msgs); - } -} diff --git a/src/main/java/org/codelibs/fess/dict/DictionaryException.java b/src/main/java/org/codelibs/fess/dict/DictionaryException.java index 2998b7509..f9f06c698 100644 --- a/src/main/java/org/codelibs/fess/dict/DictionaryException.java +++ b/src/main/java/org/codelibs/fess/dict/DictionaryException.java @@ -16,7 +16,7 @@ package org.codelibs.fess.dict; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; public class DictionaryException extends FessSystemException { diff --git a/src/main/java/org/codelibs/fess/dict/DictionaryExpiredException.java b/src/main/java/org/codelibs/fess/dict/DictionaryExpiredException.java index b9302e34a..8b6270364 100644 --- a/src/main/java/org/codelibs/fess/dict/DictionaryExpiredException.java +++ b/src/main/java/org/codelibs/fess/dict/DictionaryExpiredException.java @@ -16,13 +16,11 @@ package org.codelibs.fess.dict; -import org.seasar.struts.exception.ActionMessagesException; - -public class DictionaryExpiredException extends ActionMessagesException { +public class DictionaryExpiredException extends RuntimeException { private static final long serialVersionUID = 1L; - public DictionaryExpiredException() { - super("errors.expired_dict_id"); - } + // public DictionaryExpiredException() { + // super("errors.expired_dict_id"); + // } } diff --git a/src/main/java/org/codelibs/fess/dict/DictionaryManager.java b/src/main/java/org/codelibs/fess/dict/DictionaryManager.java index 97e21ba78..f3d6101a0 100644 --- a/src/main/java/org/codelibs/fess/dict/DictionaryManager.java +++ b/src/main/java/org/codelibs/fess/dict/DictionaryManager.java @@ -23,12 +23,13 @@ import java.util.List; import java.util.Map; import java.util.UUID; +import javax.annotation.PostConstruct; +import javax.annotation.PreDestroy; + import org.codelibs.core.lang.StringUtil; -import org.seasar.extension.timer.TimeoutManager; -import org.seasar.extension.timer.TimeoutTarget; -import org.seasar.extension.timer.TimeoutTask; -import org.seasar.framework.container.annotation.tiger.DestroyMethod; -import org.seasar.framework.container.annotation.tiger.InitMethod; +import org.lastaflute.di.helper.timer.TimeoutManager; +import org.lastaflute.di.helper.timer.TimeoutTarget; +import org.lastaflute.di.helper.timer.TimeoutTask; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -47,14 +48,14 @@ public class DictionaryManager { protected List locatorList = new ArrayList(); - @InitMethod + @PostConstruct public void init() { // start final WatcherTarget watcherTarget = new WatcherTarget(); watcherTargetTask = TimeoutManager.getInstance().addTimeoutTarget(watcherTarget, watcherTimeout, true); } - @DestroyMethod + @PreDestroy public void destroy() { if (watcherTargetTask != null && !watcherTargetTask.isStopped()) { watcherTargetTask.stop(); diff --git a/src/main/java/org/codelibs/fess/dict/synonym/SynonymFile.java b/src/main/java/org/codelibs/fess/dict/synonym/SynonymFile.java index 34f1c716d..7507eb0a4 100644 --- a/src/main/java/org/codelibs/fess/dict/synonym/SynonymFile.java +++ b/src/main/java/org/codelibs/fess/dict/synonym/SynonymFile.java @@ -33,11 +33,11 @@ import java.util.List; import org.apache.commons.io.FileUtils; import org.apache.commons.io.IOUtils; +import org.codelibs.core.io.CopyUtil; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; import org.codelibs.fess.dict.DictionaryException; import org.codelibs.fess.dict.DictionaryFile; -import org.codelibs.robot.util.StreamUtil; public class SynonymFile extends DictionaryFile { private static final String SYNONYM = "synonym"; @@ -373,7 +373,7 @@ public class SynonymFile extends DictionaryFile { } public void update(final InputStream in) throws IOException { - StreamUtil.drain(in, file); + CopyUtil.copy(in, file); reload(null); } diff --git a/src/main/java/org/codelibs/fess/dict/userdict/UserDictFile.java b/src/main/java/org/codelibs/fess/dict/userdict/UserDictFile.java index 474add840..953201171 100644 --- a/src/main/java/org/codelibs/fess/dict/userdict/UserDictFile.java +++ b/src/main/java/org/codelibs/fess/dict/userdict/UserDictFile.java @@ -33,12 +33,12 @@ import java.util.List; import org.apache.commons.io.FileUtils; import org.apache.commons.io.IOUtils; +import org.codelibs.core.io.CopyUtil; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; import org.codelibs.fess.dict.DictionaryException; import org.codelibs.fess.dict.DictionaryFile; import org.codelibs.fess.util.UserDictCSVUtil; -import org.codelibs.robot.util.StreamUtil; public class UserDictFile extends DictionaryFile { private static final String USERDICT = "userDict"; @@ -302,7 +302,7 @@ public class UserDictFile extends DictionaryFile { } public void update(final InputStream in) throws IOException { - StreamUtil.drain(in, file); + CopyUtil.copy(in, file); reload(null); } diff --git a/src/main/java/org/codelibs/fess/ds/DataStoreCrawlingException.java b/src/main/java/org/codelibs/fess/ds/DataStoreCrawlingException.java index 85e82dd45..4c76f6bc6 100644 --- a/src/main/java/org/codelibs/fess/ds/DataStoreCrawlingException.java +++ b/src/main/java/org/codelibs/fess/ds/DataStoreCrawlingException.java @@ -16,7 +16,7 @@ package org.codelibs.fess.ds; -import org.codelibs.robot.RobotCrawlAccessException; +import org.codelibs.robot.exception.RobotCrawlAccessException; public class DataStoreCrawlingException extends RobotCrawlAccessException { diff --git a/src/main/java/org/codelibs/fess/ds/DataStoreException.java b/src/main/java/org/codelibs/fess/ds/DataStoreException.java index d87276012..64e59cd73 100644 --- a/src/main/java/org/codelibs/fess/ds/DataStoreException.java +++ b/src/main/java/org/codelibs/fess/ds/DataStoreException.java @@ -16,7 +16,7 @@ package org.codelibs.fess.ds; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; public class DataStoreException extends FessSystemException { private static final long serialVersionUID = 1L; diff --git a/src/main/java/org/codelibs/fess/ds/IndexUpdateCallback.java b/src/main/java/org/codelibs/fess/ds/IndexUpdateCallback.java index 8856ce285..fded86c31 100644 --- a/src/main/java/org/codelibs/fess/ds/IndexUpdateCallback.java +++ b/src/main/java/org/codelibs/fess/ds/IndexUpdateCallback.java @@ -18,7 +18,7 @@ package org.codelibs.fess.ds; import java.util.Map; -import org.codelibs.fess.client.FessEsClient; +import org.codelibs.fess.es.client.FessEsClient; public interface IndexUpdateCallback { diff --git a/src/main/java/org/codelibs/fess/ds/impl/AbstractDataStoreImpl.java b/src/main/java/org/codelibs/fess/ds/impl/AbstractDataStoreImpl.java index 7612041ee..a6b7ecd98 100644 --- a/src/main/java/org/codelibs/fess/ds/impl/AbstractDataStoreImpl.java +++ b/src/main/java/org/codelibs/fess/ds/impl/AbstractDataStoreImpl.java @@ -29,11 +29,14 @@ import org.codelibs.fess.ds.IndexUpdateCallback; import org.codelibs.fess.es.exentity.DataConfig; import org.codelibs.fess.helper.CrawlingSessionHelper; import org.codelibs.fess.helper.FieldHelper; +import org.codelibs.fess.helper.SystemHelper; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.framework.util.OgnlUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import groovy.lang.Binding; +import groovy.lang.GroovyShell; + public abstract class AbstractDataStoreImpl implements DataStore { private static final Logger logger = LoggerFactory.getLogger(AbstractDataStoreImpl.class); @@ -52,6 +55,7 @@ public abstract class AbstractDataStoreImpl implements DataStore { final Map configParamMap = config.getHandlerParameterMap(); final Map configScriptMap = config.getHandlerScriptMap(); final CrawlingSessionHelper crawlingSessionHelper = ComponentUtil.getCrawlingSessionHelper(); + final SystemHelper systemHelper = ComponentUtil.getSystemHelper(); final Long documentExpires = crawlingSessionHelper.getDocumentExpires(); final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); @@ -73,7 +77,7 @@ public abstract class AbstractDataStoreImpl implements DataStore { // segment defaultDataMap.put(fieldHelper.segmentField, initParamMap.get(Constants.SESSION_ID)); // created - defaultDataMap.put(fieldHelper.createdField, "NOW"); + defaultDataMap.put(fieldHelper.createdField, systemHelper.getCurrentTime()); // boost defaultDataMap.put(fieldHelper.boostField, config.getBoost().toString()); // label: labelType @@ -112,8 +116,7 @@ public abstract class AbstractDataStoreImpl implements DataStore { } try { - final Object exp = OgnlUtil.parseExpression(template); - final Object value = OgnlUtil.getValue(exp, paramMap); + final Object value = new GroovyShell(new Binding(paramMap)).evaluate(template); if (value == null) { return null; } diff --git a/src/main/java/org/codelibs/fess/ds/impl/CsvDataStoreImpl.java b/src/main/java/org/codelibs/fess/ds/impl/CsvDataStoreImpl.java index 9127f5440..7e6b7e08b 100644 --- a/src/main/java/org/codelibs/fess/ds/impl/CsvDataStoreImpl.java +++ b/src/main/java/org/codelibs/fess/ds/impl/CsvDataStoreImpl.java @@ -31,19 +31,19 @@ import java.util.regex.Pattern; import org.apache.commons.io.IOUtils; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; +import org.codelibs.fess.app.service.FailureUrlService; import org.codelibs.fess.ds.DataStoreCrawlingException; import org.codelibs.fess.ds.DataStoreException; import org.codelibs.fess.ds.IndexUpdateCallback; import org.codelibs.fess.es.exentity.DataConfig; -import org.codelibs.fess.service.FailureUrlService; -import org.codelibs.robot.RobotCrawlAccessException; -import org.codelibs.robot.RobotMultipleCrawlAccessException; -import org.seasar.framework.container.SingletonS2Container; +import org.codelibs.robot.exception.RobotCrawlAccessException; +import org.codelibs.robot.exception.RobotMultipleCrawlAccessException; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import jp.sf.orangesignal.csv.CsvConfig; -import jp.sf.orangesignal.csv.CsvReader; +import com.orangesignal.csv.CsvConfig; +import com.orangesignal.csv.CsvReader; public class CsvDataStoreImpl extends AbstractDataStoreImpl { private static final Logger logger = LoggerFactory.getLogger(CsvDataStoreImpl.class); @@ -254,13 +254,13 @@ public class CsvDataStoreImpl extends AbstractDataStoreImpl { url = csvFile.getAbsolutePath() + ":" + csvReader.getLineNumber(); } - final FailureUrlService failureUrlService = SingletonS2Container.getComponent(FailureUrlService.class); + final FailureUrlService failureUrlService = SingletonLaContainer.getComponent(FailureUrlService.class); failureUrlService.store(dataConfig, errorName, url, target); logger.warn("Crawling Access Exception at : " + dataMap, e); } catch (final Exception e) { final String url = csvFile.getAbsolutePath() + ":" + csvReader.getLineNumber(); - final FailureUrlService failureUrlService = SingletonS2Container.getComponent(FailureUrlService.class); + final FailureUrlService failureUrlService = SingletonLaContainer.getComponent(FailureUrlService.class); failureUrlService.store(dataConfig, e.getClass().getCanonicalName(), url, e); logger.warn("Crawling Access Exception at : " + dataMap, e); diff --git a/src/main/java/org/codelibs/fess/ds/impl/DatabaseDataStoreImpl.java b/src/main/java/org/codelibs/fess/ds/impl/DatabaseDataStoreImpl.java index a84abc995..feea8155d 100644 --- a/src/main/java/org/codelibs/fess/ds/impl/DatabaseDataStoreImpl.java +++ b/src/main/java/org/codelibs/fess/ds/impl/DatabaseDataStoreImpl.java @@ -28,10 +28,10 @@ import java.util.Map; import java.util.Set; import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.FessSystemException; import org.codelibs.fess.ds.DataStoreException; import org.codelibs.fess.ds.IndexUpdateCallback; import org.codelibs.fess.es.exentity.DataConfig; +import org.codelibs.fess.exception.FessSystemException; import org.slf4j.Logger; import org.slf4j.LoggerFactory; diff --git a/src/main/java/org/codelibs/fess/ds/impl/FileListDataStoreImpl.java b/src/main/java/org/codelibs/fess/ds/impl/FileListDataStoreImpl.java index e3a7db091..3ee29749d 100644 --- a/src/main/java/org/codelibs/fess/ds/impl/FileListDataStoreImpl.java +++ b/src/main/java/org/codelibs/fess/ds/impl/FileListDataStoreImpl.java @@ -22,34 +22,34 @@ import java.util.Collections; import java.util.List; import java.util.Map; +import org.codelibs.core.collection.LruHashMap; +import org.codelibs.core.io.SerializeUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.client.FessEsClient; import org.codelibs.fess.ds.DataStoreCrawlingException; import org.codelibs.fess.ds.DataStoreException; import org.codelibs.fess.ds.IndexUpdateCallback; +import org.codelibs.fess.es.client.FessEsClient; import org.codelibs.fess.es.exentity.DataConfig; import org.codelibs.fess.helper.CrawlingSessionHelper; import org.codelibs.fess.helper.FieldHelper; import org.codelibs.fess.helper.IndexingHelper; import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.robot.RobotSystemException; import org.codelibs.robot.builder.RequestDataBuilder; import org.codelibs.robot.client.S2RobotClient; import org.codelibs.robot.client.S2RobotClientFactory; import org.codelibs.robot.entity.ResponseData; import org.codelibs.robot.entity.ResultData; +import org.codelibs.robot.exception.RobotSystemException; import org.codelibs.robot.processor.ResponseProcessor; import org.codelibs.robot.processor.impl.DefaultResponseProcessor; import org.codelibs.robot.rule.Rule; import org.codelibs.robot.rule.RuleManager; import org.codelibs.robot.transformer.Transformer; -import org.codelibs.robot.util.LruHashMap; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.framework.util.SerializeUtil; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import jp.sf.orangesignal.csv.CsvConfig; +import com.orangesignal.csv.CsvConfig; public class FileListDataStoreImpl extends CsvDataStoreImpl { @@ -75,7 +75,7 @@ public class FileListDataStoreImpl extends CsvDataStoreImpl { protected CrawlingSessionHelper crawlingSessionHelper; - public Map parentEncodingMap = Collections.synchronizedMap(new LruHashMap(1000)); + public Map parentEncodingMap = Collections.synchronizedMap(new LruHashMap<>(1000)); public String[] ignoreFieldNames = new String[] { Constants.INDEXING_TARGET, Constants.SESSION_ID }; @@ -92,7 +92,7 @@ public class FileListDataStoreImpl extends CsvDataStoreImpl { @Override public void store(final DataConfig config, final IndexUpdateCallback callback, final Map initParamMap) { - robotClientFactory = SingletonS2Container.getComponent(S2RobotClientFactory.class); + robotClientFactory = SingletonLaContainer.getComponent(S2RobotClientFactory.class); config.initializeClientFactory(robotClientFactory); @@ -181,7 +181,7 @@ public class FileListDataStoreImpl extends CsvDataStoreImpl { responseData.setExecutionTime(System.currentTimeMillis() - startTime); responseData.setSessionId((String) dataMap.get(Constants.SESSION_ID)); - final RuleManager ruleManager = SingletonS2Container.getComponent(RuleManager.class); + final RuleManager ruleManager = SingletonLaContainer.getComponent(RuleManager.class); final Rule rule = ruleManager.getRule(responseData); if (rule == null) { logger.warn("No url rule. Data: " + dataMap); diff --git a/src/main/java/org/codelibs/fess/ds/impl/IndexUpdateCallbackImpl.java b/src/main/java/org/codelibs/fess/ds/impl/IndexUpdateCallbackImpl.java index b3696fd58..f689c8b19 100644 --- a/src/main/java/org/codelibs/fess/ds/impl/IndexUpdateCallbackImpl.java +++ b/src/main/java/org/codelibs/fess/ds/impl/IndexUpdateCallbackImpl.java @@ -21,16 +21,17 @@ import java.util.List; import java.util.Map; import java.util.concurrent.atomic.AtomicLong; -import org.codelibs.fess.FessSystemException; -import org.codelibs.fess.client.FessEsClient; +import javax.annotation.PostConstruct; + import org.codelibs.fess.ds.IndexUpdateCallback; +import org.codelibs.fess.es.client.FessEsClient; +import org.codelibs.fess.exception.FessSystemException; import org.codelibs.fess.helper.CrawlingSessionHelper; import org.codelibs.fess.helper.FieldHelper; import org.codelibs.fess.helper.IndexingHelper; import org.codelibs.fess.helper.SearchLogHelper; import org.codelibs.fess.helper.SystemHelper; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.framework.container.annotation.tiger.InitMethod; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -53,7 +54,7 @@ public class IndexUpdateCallbackImpl implements IndexUpdateCallback { private FieldHelper fieldHelper; - @InitMethod + @PostConstruct public void init() { fieldHelper = ComponentUtil.getFieldHelper(); } diff --git a/src/main/java/org/codelibs/fess/entity/FacetInfo.java b/src/main/java/org/codelibs/fess/entity/FacetInfo.java index f39076eb6..237403eda 100644 --- a/src/main/java/org/codelibs/fess/entity/FacetInfo.java +++ b/src/main/java/org/codelibs/fess/entity/FacetInfo.java @@ -18,29 +18,26 @@ package org.codelibs.fess.entity; import java.util.Arrays; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.Maxbytelength; - public class FacetInfo { - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String[] field; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String[] query; - @Maxbytelength(maxbytelength = 1000) + //@Maxbytelength(maxbytelength = 1000) public String prefix; - @IntegerType + //@IntegerType public String limit; - @IntegerType + //@IntegerType public String minCount; - @Maxbytelength(maxbytelength = 255) + //@Maxbytelength(maxbytelength = 255) public String sort; - @Maxbytelength(maxbytelength = 10) + //@Maxbytelength(maxbytelength = 10) public String missing; @Override diff --git a/src/main/java/org/codelibs/fess/entity/GeoInfo.java b/src/main/java/org/codelibs/fess/entity/GeoInfo.java index 04f6c3371..3c31154ba 100644 --- a/src/main/java/org/codelibs/fess/entity/GeoInfo.java +++ b/src/main/java/org/codelibs/fess/entity/GeoInfo.java @@ -20,20 +20,18 @@ import org.codelibs.core.lang.StringUtil; import org.elasticsearch.common.unit.DistanceUnit; import org.elasticsearch.index.query.FilterBuilder; import org.elasticsearch.index.query.FilterBuilders; -import org.seasar.struts.annotation.Mask; -import org.seasar.struts.annotation.Maxbytelength; public class GeoInfo { - @Mask(mask = "-?([0-9]+|[0-9]+\\.[0-9]+)") - @Maxbytelength(maxbytelength = 20) + //@Mask(mask = "-?([0-9]+|[0-9]+\\.[0-9]+)") + //@Maxbytelength(maxbytelength = 20) public String latitude; - @Mask(mask = "-?([0-9]+|[0-9]+\\.[0-9]+)") - @Maxbytelength(maxbytelength = 20) + //@Mask(mask = "-?([0-9]+|[0-9]+\\.[0-9]+)") + //@Maxbytelength(maxbytelength = 20) public String longitude; - @Mask(mask = "-?([0-9]+|[0-9]+\\.[0-9]+)") - @Maxbytelength(maxbytelength = 20) + //@Mask(mask = "-?([0-9]+|[0-9]+\\.[0-9]+)") + //@Maxbytelength(maxbytelength = 20) public String distance; private boolean isInit = false; diff --git a/src/main/java/org/codelibs/fess/entity/LoginInfo.java b/src/main/java/org/codelibs/fess/entity/LoginInfo.java index 26dc48078..e7989125e 100644 --- a/src/main/java/org/codelibs/fess/entity/LoginInfo.java +++ b/src/main/java/org/codelibs/fess/entity/LoginInfo.java @@ -17,7 +17,6 @@ package org.codelibs.fess.entity; import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.sastruts.core.entity.UserInfo; public class LoginInfo extends UserInfo { diff --git a/src/main/java/org/codelibs/sastruts/core/entity/UserInfo.java b/src/main/java/org/codelibs/fess/entity/UserInfo.java similarity index 90% rename from src/main/java/org/codelibs/sastruts/core/entity/UserInfo.java rename to src/main/java/org/codelibs/fess/entity/UserInfo.java index 52aadc49e..c65845c42 100644 --- a/src/main/java/org/codelibs/sastruts/core/entity/UserInfo.java +++ b/src/main/java/org/codelibs/fess/entity/UserInfo.java @@ -13,7 +13,7 @@ * either express or implied. See the License for the specific language * governing permissions and limitations under the License. */ -package org.codelibs.sastruts.core.entity; +package org.codelibs.fess.entity; import java.io.Serializable; import java.util.Set; @@ -30,7 +30,7 @@ public class UserInfo implements Serializable { return roleSet; } - public void setRoleSet(Set roleSet) { + public void setRoleSet(final Set roleSet) { this.roleSet = roleSet; } @@ -42,7 +42,7 @@ public class UserInfo implements Serializable { this.username = username; } - public boolean isUserInRole(String role) { + public boolean isUserInRole(final String role) { if (roleSet != null) { return roleSet.contains(role); } diff --git a/src/main/java/org/codelibs/fess/es/bsbhv/AbstractBehavior.java b/src/main/java/org/codelibs/fess/es/bsbhv/AbstractBehavior.java index 0fa3d1f2b..a6a517131 100644 --- a/src/main/java/org/codelibs/fess/es/bsbhv/AbstractBehavior.java +++ b/src/main/java/org/codelibs/fess/es/bsbhv/AbstractBehavior.java @@ -25,6 +25,7 @@ import org.dbflute.cbean.ConditionBean; import org.dbflute.cbean.coption.CursorSelectOption; import org.dbflute.cbean.result.ListResultBean; import org.dbflute.exception.IllegalBehaviorStateException; +import org.dbflute.util.DfTypeUtil; import org.elasticsearch.action.bulk.BulkItemResponse; import org.elasticsearch.action.bulk.BulkRequestBuilder; import org.elasticsearch.action.bulk.BulkResponse; @@ -76,10 +77,17 @@ public abstract class AbstractBehavior List delegateSelectList(final ConditionBean cb, final Class entityType) { // TODO check response final SearchRequestBuilder builder = client.prepareSearch(asEsIndex()).setTypes(asEsSearchType()); + final int from; + final int size; if (cb.isFetchScopeEffective()) { - builder.setFrom(cb.getFetchStartIndex()); - builder.setSize(cb.getFetchSize()); + from = cb.getFetchStartIndex(); + size = cb.getFetchSize(); + } else { + from = 0; + size = 10; } + builder.setFrom(from); + builder.setSize(size); ((AbstractConditionBean) cb).request().build(builder); final SearchResponse response = ((AbstractConditionBean) cb).build(builder).execute().actionGet(); @@ -94,8 +102,8 @@ public abstract class AbstractBehavior createPlainUpdateOption() { + UpdateOption updateOption = new UpdateOption(); + updateOption.xtoBeCompatibleBatchUpdateDefaultEveryColumn(); + return updateOption; } - protected static Short toShort(final Object value) { - if (value instanceof Number) { - return ((Number) value).shortValue(); - } else if (value instanceof String) { - return Short.parseShort(value.toString()); - } else { - return null; - } - } - - protected static Integer toInteger(final Object value) { - if (value instanceof Number) { - return ((Number) value).intValue(); - } else if (value instanceof String) { - return Integer.parseInt(value.toString()); - } else { - return null; - } - } - - protected static Long toLong(final Object value) { - if (value instanceof Number) { - return ((Number) value).longValue(); - } else if (value instanceof String) { - return Long.parseLong(value.toString()); - } else { - return null; - } - } - - protected static Float toFloat(final Object value) { - if (value instanceof Number) { - return ((Number) value).floatValue(); - } else if (value instanceof String) { - return Float.parseFloat(value.toString()); - } else { - return null; - } - } - - protected static Double toDouble(final Object value) { - if (value instanceof Number) { - return ((Number) value).doubleValue(); - } else if (value instanceof String) { - return Double.parseDouble(value.toString()); - } else { - return null; - } - } - - protected static Boolean toBoolean(final Object value) { - if (value instanceof Boolean) { - return ((Boolean) value).booleanValue(); - } else if (value instanceof String) { - return Boolean.parseBoolean(value.toString()); - } else { + public static String[] toStringArray(final Object value) { + if (value instanceof String[]) { + return (String[]) value; + } else if (value instanceof List) { + return ((List) value).stream().map(v -> v.toString()).toArray(n -> new String[n]); + } + String str = DfTypeUtil.toString(value); + if (str == null) { return null; } + return new String[] { str }; } public static class BulkList implements List { diff --git a/src/main/java/org/codelibs/fess/es/bsbhv/BsBoostDocumentRuleBhv.java b/src/main/java/org/codelibs/fess/es/bsbhv/BsBoostDocumentRuleBhv.java index 2ffc11644..504767b25 100644 --- a/src/main/java/org/codelibs/fess/es/bsbhv/BsBoostDocumentRuleBhv.java +++ b/src/main/java/org/codelibs/fess/es/bsbhv/BsBoostDocumentRuleBhv.java @@ -16,6 +16,7 @@ import org.dbflute.cbean.result.ListResultBean; import org.dbflute.cbean.result.PagingResultBean; import org.dbflute.exception.IllegalBehaviorStateException; import org.dbflute.optional.OptionalEntity; +import org.dbflute.util.DfTypeUtil; import org.elasticsearch.action.bulk.BulkRequestBuilder; import org.elasticsearch.action.delete.DeleteRequestBuilder; import org.elasticsearch.action.index.IndexRequestBuilder; @@ -54,14 +55,14 @@ public abstract class BsBoostDocumentRuleBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setBoostExpr(toString(source.get("boostExpr"))); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setId(toString(source.get("id"))); - result.setSortOrder(toInteger(source.get("sortOrder"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); - result.setUrlExpr(toString(source.get("urlExpr"))); + result.setBoostExpr(DfTypeUtil.toString(source.get("boostExpr"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setSortOrder(DfTypeUtil.toInteger(source.get("sortOrder"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); + result.setUrlExpr(DfTypeUtil.toString(source.get("urlExpr"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -226,4 +227,9 @@ public abstract class BsBoostDocumentRuleBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setId(toString(source.get("id"))); - result.setRequestedTime(toLong(source.get("requestedTime"))); - result.setSearchLogId(toString(source.get("searchLogId"))); - result.setUrl(toString(source.get("url"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setRequestedTime(DfTypeUtil.toLong(source.get("requestedTime"))); + result.setSearchLogId(DfTypeUtil.toString(source.get("searchLogId"))); + result.setUrl(DfTypeUtil.toString(source.get("url"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -221,4 +222,9 @@ public abstract class BsClickLogBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setExpiredTime(toLong(source.get("expiredTime"))); - result.setId(toString(source.get("id"))); - result.setName(toString(source.get("name"))); - result.setSessionId(toString(source.get("sessionId"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setExpiredTime(DfTypeUtil.toLong(source.get("expiredTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + result.setSessionId(DfTypeUtil.toString(source.get("sessionId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -223,4 +224,9 @@ public abstract class BsCrawlingSessionBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setCrawlingSessionId(toString(source.get("crawlingSessionId"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setId(toString(source.get("id"))); - result.setKey(toString(source.get("key"))); - result.setValue(toString(source.get("value"))); + result.setCrawlingSessionId(DfTypeUtil.toString(source.get("crawlingSessionId"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setKey(DfTypeUtil.toString(source.get("key"))); + result.setValue(DfTypeUtil.toString(source.get("value"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -223,4 +224,9 @@ public abstract class BsCrawlingSessionInfoBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setAvailable(toBoolean(source.get("available"))); - result.setBoost(toFloat(source.get("boost"))); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setHandlerName(toString(source.get("handlerName"))); - result.setHandlerParameter(toString(source.get("handlerParameter"))); - result.setHandlerScript(toString(source.get("handlerScript"))); - result.setId(toString(source.get("id"))); - result.setName(toString(source.get("name"))); - result.setSortOrder(toInteger(source.get("sortOrder"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); + result.setAvailable(DfTypeUtil.toBoolean(source.get("available"))); + result.setBoost(DfTypeUtil.toFloat(source.get("boost"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setHandlerName(DfTypeUtil.toString(source.get("handlerName"))); + result.setHandlerParameter(DfTypeUtil.toString(source.get("handlerParameter"))); + result.setHandlerScript(DfTypeUtil.toString(source.get("handlerScript"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + result.setSortOrder(DfTypeUtil.toInteger(source.get("sortOrder"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -229,4 +230,9 @@ public abstract class BsDataConfigBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setDataConfigId(toString(source.get("dataConfigId"))); - result.setId(toString(source.get("id"))); - result.setLabelTypeId(toString(source.get("labelTypeId"))); + result.setDataConfigId(DfTypeUtil.toString(source.get("dataConfigId"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setLabelTypeId(DfTypeUtil.toString(source.get("labelTypeId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -221,4 +222,9 @@ public abstract class BsDataConfigToLabelBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setDataConfigId(toString(source.get("dataConfigId"))); - result.setId(toString(source.get("id"))); - result.setRoleTypeId(toString(source.get("roleTypeId"))); + result.setDataConfigId(DfTypeUtil.toString(source.get("dataConfigId"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setRoleTypeId(DfTypeUtil.toString(source.get("roleTypeId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -221,4 +222,9 @@ public abstract class BsDataConfigToRoleBhv extends AbstractBehavior { + + @Override + public String asTableDbName() { + return asEsIndexType(); + } + + @Override + protected String asEsIndex() { + return "fess_log"; + } + + @Override + public String asEsIndexType() { + return "event_log"; + } + + @Override + public String asEsSearchType() { + return "event_log"; + } + + @Override + public EventLogDbm asDBMeta() { + return EventLogDbm.getInstance(); + } + + @Override + protected RESULT createEntity(Map source, Class entityType) { + try { + final RESULT result = entityType.newInstance(); + result.setCreatedAt(DfTypeUtil.toLocalDateTime(source.get("createdAt"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setEventType(DfTypeUtil.toString(source.get("eventType"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setMessage(DfTypeUtil.toString(source.get("message"))); + result.setPath(DfTypeUtil.toString(source.get("path"))); + return result; + } catch (InstantiationException | IllegalAccessException e) { + final String msg = "Cannot create a new instance: " + entityType.getName(); + throw new IllegalBehaviorStateException(msg, e); + } + } + + public int selectCount(CBCall cbLambda) { + return facadeSelectCount(createCB(cbLambda)); + } + + public OptionalEntity selectEntity(CBCall cbLambda) { + return facadeSelectEntity(createCB(cbLambda)); + } + + protected OptionalEntity facadeSelectEntity(EventLogCB cb) { + return doSelectOptionalEntity(cb, typeOfSelectedEntity()); + } + + protected OptionalEntity doSelectOptionalEntity(EventLogCB cb, Class tp) { + return createOptionalEntity(doSelectEntity(cb, tp), cb); + } + + @Override + public EventLogCB newConditionBean() { + return new EventLogCB(); + } + + @Override + protected Entity doReadEntity(ConditionBean cb) { + return facadeSelectEntity(downcast(cb)).orElse(null); + } + + public EventLog selectEntityWithDeletedCheck(CBCall cbLambda) { + return facadeSelectEntityWithDeletedCheck(createCB(cbLambda)); + } + + public OptionalEntity selectByPK(String id) { + return facadeSelectByPK(id); + } + + protected OptionalEntity facadeSelectByPK(String id) { + return doSelectOptionalByPK(id, typeOfSelectedEntity()); + } + + protected ENTITY doSelectByPK(String id, Class tp) { + return doSelectEntity(xprepareCBAsPK(id), tp); + } + + protected EventLogCB xprepareCBAsPK(String id) { + assertObjectNotNull("id", id); + return newConditionBean().acceptPK(id); + } + + protected OptionalEntity doSelectOptionalByPK(String id, Class tp) { + return createOptionalEntity(doSelectByPK(id, tp), id); + } + + @Override + protected Class typeOfSelectedEntity() { + return EventLog.class; + } + + @Override + protected Class typeOfHandlingEntity() { + return EventLog.class; + } + + @Override + protected Class typeOfHandlingConditionBean() { + return EventLogCB.class; + } + + public ListResultBean selectList(CBCall cbLambda) { + return facadeSelectList(createCB(cbLambda)); + } + + public PagingResultBean selectPage(CBCall cbLambda) { + // TODO same? + return (PagingResultBean) facadeSelectList(createCB(cbLambda)); + } + + public void selectCursor(CBCall cbLambda, EntityRowHandler entityLambda) { + facadeSelectCursor(createCB(cbLambda), entityLambda); + } + + public void selectBulk(CBCall cbLambda, EntityRowHandler> entityLambda) { + delegateSelectBulk(createCB(cbLambda), entityLambda, typeOfSelectedEntity()); + } + + public void insert(EventLog entity) { + doInsert(entity, null); + } + + public void insert(EventLog entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doInsert(entity, null); + } + + public void update(EventLog entity) { + doUpdate(entity, null); + } + + public void update(EventLog entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doUpdate(entity, null); + } + + public void insertOrUpdate(EventLog entity) { + doInsertOrUpdate(entity, null, null); + } + + public void insertOrUpdate(EventLog entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doInsertOrUpdate(entity, null, null); + } + + public void delete(EventLog entity) { + doDelete(entity, null); + } + + public void delete(EventLog entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().deleteOption(opLambda); + } + doDelete(entity, null); + } + + public int queryDelete(CBCall cbLambda) { + return doQueryDelete(createCB(cbLambda), null); + } + + public int[] batchInsert(List list) { + return batchInsert(list, null); + } + + public int[] batchInsert(List list, RequestOptionCall call) { + return doBatchInsert(new BulkList<>(list, call), null); + } + + public int[] batchUpdate(List list) { + return batchUpdate(list, null); + } + + public int[] batchUpdate(List list, RequestOptionCall call) { + return doBatchUpdate(new BulkList<>(list, call), null); + } + + public int[] batchDelete(List list) { + return batchDelete(list, null); + } + + public int[] batchDelete(List list, RequestOptionCall call) { + return doBatchDelete(new BulkList<>(list, call), null); + } + + // TODO create, modify, remove + + @Override + protected boolean isCompatibleBatchInsertDefaultEveryColumn() { + return true; + } +} diff --git a/src/main/java/org/codelibs/fess/es/bsbhv/BsFailureUrlBhv.java b/src/main/java/org/codelibs/fess/es/bsbhv/BsFailureUrlBhv.java index ee1ebd1e8..8adbca099 100644 --- a/src/main/java/org/codelibs/fess/es/bsbhv/BsFailureUrlBhv.java +++ b/src/main/java/org/codelibs/fess/es/bsbhv/BsFailureUrlBhv.java @@ -16,6 +16,7 @@ import org.dbflute.cbean.result.ListResultBean; import org.dbflute.cbean.result.PagingResultBean; import org.dbflute.exception.IllegalBehaviorStateException; import org.dbflute.optional.OptionalEntity; +import org.dbflute.util.DfTypeUtil; import org.elasticsearch.action.bulk.BulkRequestBuilder; import org.elasticsearch.action.delete.DeleteRequestBuilder; import org.elasticsearch.action.index.IndexRequestBuilder; @@ -54,14 +55,14 @@ public abstract class BsFailureUrlBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setConfigId(toString(source.get("configId"))); - result.setErrorCount(toInteger(source.get("errorCount"))); - result.setErrorLog(toString(source.get("errorLog"))); - result.setErrorName(toString(source.get("errorName"))); - result.setId(toString(source.get("id"))); - result.setLastAccessTime(toLong(source.get("lastAccessTime"))); - result.setThreadName(toString(source.get("threadName"))); - result.setUrl(toString(source.get("url"))); + result.setConfigId(DfTypeUtil.toString(source.get("configId"))); + result.setErrorCount(DfTypeUtil.toInteger(source.get("errorCount"))); + result.setErrorLog(DfTypeUtil.toString(source.get("errorLog"))); + result.setErrorName(DfTypeUtil.toString(source.get("errorName"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setLastAccessTime(DfTypeUtil.toLong(source.get("lastAccessTime"))); + result.setThreadName(DfTypeUtil.toString(source.get("threadName"))); + result.setUrl(DfTypeUtil.toString(source.get("url"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -225,4 +226,9 @@ public abstract class BsFailureUrlBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setId(toString(source.get("id"))); - result.setUrl(toString(source.get("url"))); - result.setUserInfoId(toString(source.get("userInfoId"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setUrl(DfTypeUtil.toString(source.get("url"))); + result.setUserInfoId(DfTypeUtil.toString(source.get("userInfoId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -221,4 +222,9 @@ public abstract class BsFavoriteLogBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setFileConfigId(toString(source.get("fileConfigId"))); - result.setHostname(toString(source.get("hostname"))); - result.setId(toString(source.get("id"))); - result.setParameters(toString(source.get("parameters"))); - result.setPassword(toString(source.get("password"))); - result.setPort(toInteger(source.get("port"))); - result.setProtocolScheme(toString(source.get("protocolScheme"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); - result.setUsername(toString(source.get("username"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setFileConfigId(DfTypeUtil.toString(source.get("fileConfigId"))); + result.setHostname(DfTypeUtil.toString(source.get("hostname"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setParameters(DfTypeUtil.toString(source.get("parameters"))); + result.setPassword(DfTypeUtil.toString(source.get("password"))); + result.setPort(DfTypeUtil.toInteger(source.get("port"))); + result.setProtocolScheme(DfTypeUtil.toString(source.get("protocolScheme"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); + result.setUsername(DfTypeUtil.toString(source.get("username"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -230,4 +231,9 @@ public abstract class BsFileAuthenticationBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setAvailable(toBoolean(source.get("available"))); - result.setBoost(toFloat(source.get("boost"))); - result.setConfigParameter(toString(source.get("configParameter"))); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setDepth(toInteger(source.get("depth"))); - result.setExcludedDocPaths(toString(source.get("excludedDocPaths"))); - result.setExcludedPaths(toString(source.get("excludedPaths"))); - result.setId(toString(source.get("id"))); - result.setIncludedDocPaths(toString(source.get("includedDocPaths"))); - result.setIncludedPaths(toString(source.get("includedPaths"))); - result.setIntervalTime(toInteger(source.get("intervalTime"))); - result.setMaxAccessCount(toLong(source.get("maxAccessCount"))); - result.setName(toString(source.get("name"))); - result.setNumOfThread(toInteger(source.get("numOfThread"))); - result.setPaths(toString(source.get("paths"))); - result.setSortOrder(toInteger(source.get("sortOrder"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); + result.setAvailable(DfTypeUtil.toBoolean(source.get("available"))); + result.setBoost(DfTypeUtil.toFloat(source.get("boost"))); + result.setConfigParameter(DfTypeUtil.toString(source.get("configParameter"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setDepth(DfTypeUtil.toInteger(source.get("depth"))); + result.setExcludedDocPaths(DfTypeUtil.toString(source.get("excludedDocPaths"))); + result.setExcludedPaths(DfTypeUtil.toString(source.get("excludedPaths"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setIncludedDocPaths(DfTypeUtil.toString(source.get("includedDocPaths"))); + result.setIncludedPaths(DfTypeUtil.toString(source.get("includedPaths"))); + result.setIntervalTime(DfTypeUtil.toInteger(source.get("intervalTime"))); + result.setMaxAccessCount(DfTypeUtil.toLong(source.get("maxAccessCount"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + result.setNumOfThread(DfTypeUtil.toInteger(source.get("numOfThread"))); + result.setPaths(DfTypeUtil.toString(source.get("paths"))); + result.setSortOrder(DfTypeUtil.toInteger(source.get("sortOrder"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -236,4 +237,9 @@ public abstract class BsFileConfigBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setFileConfigId(toString(source.get("fileConfigId"))); - result.setId(toString(source.get("id"))); - result.setLabelTypeId(toString(source.get("labelTypeId"))); + result.setFileConfigId(DfTypeUtil.toString(source.get("fileConfigId"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setLabelTypeId(DfTypeUtil.toString(source.get("labelTypeId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -221,4 +222,9 @@ public abstract class BsFileConfigToLabelBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setFileConfigId(toString(source.get("fileConfigId"))); - result.setId(toString(source.get("id"))); - result.setRoleTypeId(toString(source.get("roleTypeId"))); + result.setFileConfigId(DfTypeUtil.toString(source.get("fileConfigId"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setRoleTypeId(DfTypeUtil.toString(source.get("roleTypeId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -221,4 +222,9 @@ public abstract class BsFileConfigToRoleBhv extends AbstractBehavior { + + @Override + public String asTableDbName() { + return asEsIndexType(); + } + + @Override + protected String asEsIndex() { + return ".fess_user"; + } + + @Override + public String asEsIndexType() { + return "group"; + } + + @Override + public String asEsSearchType() { + return "group"; + } + + @Override + public GroupDbm asDBMeta() { + return GroupDbm.getInstance(); + } + + @Override + protected RESULT createEntity(Map source, Class entityType) { + try { + final RESULT result = entityType.newInstance(); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + return result; + } catch (InstantiationException | IllegalAccessException e) { + final String msg = "Cannot create a new instance: " + entityType.getName(); + throw new IllegalBehaviorStateException(msg, e); + } + } + + public int selectCount(CBCall cbLambda) { + return facadeSelectCount(createCB(cbLambda)); + } + + public OptionalEntity selectEntity(CBCall cbLambda) { + return facadeSelectEntity(createCB(cbLambda)); + } + + protected OptionalEntity facadeSelectEntity(GroupCB cb) { + return doSelectOptionalEntity(cb, typeOfSelectedEntity()); + } + + protected OptionalEntity doSelectOptionalEntity(GroupCB cb, Class tp) { + return createOptionalEntity(doSelectEntity(cb, tp), cb); + } + + @Override + public GroupCB newConditionBean() { + return new GroupCB(); + } + + @Override + protected Entity doReadEntity(ConditionBean cb) { + return facadeSelectEntity(downcast(cb)).orElse(null); + } + + public Group selectEntityWithDeletedCheck(CBCall cbLambda) { + return facadeSelectEntityWithDeletedCheck(createCB(cbLambda)); + } + + public OptionalEntity selectByPK(String id) { + return facadeSelectByPK(id); + } + + protected OptionalEntity facadeSelectByPK(String id) { + return doSelectOptionalByPK(id, typeOfSelectedEntity()); + } + + protected ENTITY doSelectByPK(String id, Class tp) { + return doSelectEntity(xprepareCBAsPK(id), tp); + } + + protected GroupCB xprepareCBAsPK(String id) { + assertObjectNotNull("id", id); + return newConditionBean().acceptPK(id); + } + + protected OptionalEntity doSelectOptionalByPK(String id, Class tp) { + return createOptionalEntity(doSelectByPK(id, tp), id); + } + + @Override + protected Class typeOfSelectedEntity() { + return Group.class; + } + + @Override + protected Class typeOfHandlingEntity() { + return Group.class; + } + + @Override + protected Class typeOfHandlingConditionBean() { + return GroupCB.class; + } + + public ListResultBean selectList(CBCall cbLambda) { + return facadeSelectList(createCB(cbLambda)); + } + + public PagingResultBean selectPage(CBCall cbLambda) { + // TODO same? + return (PagingResultBean) facadeSelectList(createCB(cbLambda)); + } + + public void selectCursor(CBCall cbLambda, EntityRowHandler entityLambda) { + facadeSelectCursor(createCB(cbLambda), entityLambda); + } + + public void selectBulk(CBCall cbLambda, EntityRowHandler> entityLambda) { + delegateSelectBulk(createCB(cbLambda), entityLambda, typeOfSelectedEntity()); + } + + public void insert(Group entity) { + doInsert(entity, null); + } + + public void insert(Group entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doInsert(entity, null); + } + + public void update(Group entity) { + doUpdate(entity, null); + } + + public void update(Group entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doUpdate(entity, null); + } + + public void insertOrUpdate(Group entity) { + doInsertOrUpdate(entity, null, null); + } + + public void insertOrUpdate(Group entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doInsertOrUpdate(entity, null, null); + } + + public void delete(Group entity) { + doDelete(entity, null); + } + + public void delete(Group entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().deleteOption(opLambda); + } + doDelete(entity, null); + } + + public int queryDelete(CBCall cbLambda) { + return doQueryDelete(createCB(cbLambda), null); + } + + public int[] batchInsert(List list) { + return batchInsert(list, null); + } + + public int[] batchInsert(List list, RequestOptionCall call) { + return doBatchInsert(new BulkList<>(list, call), null); + } + + public int[] batchUpdate(List list) { + return batchUpdate(list, null); + } + + public int[] batchUpdate(List list, RequestOptionCall call) { + return doBatchUpdate(new BulkList<>(list, call), null); + } + + public int[] batchDelete(List list) { + return batchDelete(list, null); + } + + public int[] batchDelete(List list, RequestOptionCall call) { + return doBatchDelete(new BulkList<>(list, call), null); + } + + // TODO create, modify, remove + + @Override + protected boolean isCompatibleBatchInsertDefaultEveryColumn() { + return true; + } +} diff --git a/src/main/java/org/codelibs/fess/es/bsbhv/BsJobLogBhv.java b/src/main/java/org/codelibs/fess/es/bsbhv/BsJobLogBhv.java index 86c51965c..d32126abb 100644 --- a/src/main/java/org/codelibs/fess/es/bsbhv/BsJobLogBhv.java +++ b/src/main/java/org/codelibs/fess/es/bsbhv/BsJobLogBhv.java @@ -16,6 +16,7 @@ import org.dbflute.cbean.result.ListResultBean; import org.dbflute.cbean.result.PagingResultBean; import org.dbflute.exception.IllegalBehaviorStateException; import org.dbflute.optional.OptionalEntity; +import org.dbflute.util.DfTypeUtil; import org.elasticsearch.action.bulk.BulkRequestBuilder; import org.elasticsearch.action.delete.DeleteRequestBuilder; import org.elasticsearch.action.index.IndexRequestBuilder; @@ -54,15 +55,15 @@ public abstract class BsJobLogBhv extends AbstractBehavior { protected RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setEndTime(toLong(source.get("endTime"))); - result.setId(toString(source.get("id"))); - result.setJobName(toString(source.get("jobName"))); - result.setJobStatus(toString(source.get("jobStatus"))); - result.setScriptData(toString(source.get("scriptData"))); - result.setScriptResult(toString(source.get("scriptResult"))); - result.setScriptType(toString(source.get("scriptType"))); - result.setStartTime(toLong(source.get("startTime"))); - result.setTarget(toString(source.get("target"))); + result.setEndTime(DfTypeUtil.toLong(source.get("endTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setJobName(DfTypeUtil.toString(source.get("jobName"))); + result.setJobStatus(DfTypeUtil.toString(source.get("jobStatus"))); + result.setScriptData(DfTypeUtil.toString(source.get("scriptData"))); + result.setScriptResult(DfTypeUtil.toString(source.get("scriptResult"))); + result.setScriptType(DfTypeUtil.toString(source.get("scriptType"))); + result.setStartTime(DfTypeUtil.toLong(source.get("startTime"))); + result.setTarget(DfTypeUtil.toString(source.get("target"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -226,4 +227,9 @@ public abstract class BsJobLogBhv extends AbstractBehavior { } // TODO create, modify, remove + + @Override + protected boolean isCompatibleBatchInsertDefaultEveryColumn() { + return true; + } } diff --git a/src/main/java/org/codelibs/fess/es/bsbhv/BsKeyMatchBhv.java b/src/main/java/org/codelibs/fess/es/bsbhv/BsKeyMatchBhv.java index 57b8e52b8..3feb37755 100644 --- a/src/main/java/org/codelibs/fess/es/bsbhv/BsKeyMatchBhv.java +++ b/src/main/java/org/codelibs/fess/es/bsbhv/BsKeyMatchBhv.java @@ -16,6 +16,7 @@ import org.dbflute.cbean.result.ListResultBean; import org.dbflute.cbean.result.PagingResultBean; import org.dbflute.exception.IllegalBehaviorStateException; import org.dbflute.optional.OptionalEntity; +import org.dbflute.util.DfTypeUtil; import org.elasticsearch.action.bulk.BulkRequestBuilder; import org.elasticsearch.action.delete.DeleteRequestBuilder; import org.elasticsearch.action.index.IndexRequestBuilder; @@ -54,15 +55,15 @@ public abstract class BsKeyMatchBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setBoost(toFloat(source.get("boost"))); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setId(toString(source.get("id"))); - result.setMaxSize(toInteger(source.get("maxSize"))); - result.setQuery(toString(source.get("query"))); - result.setTerm(toString(source.get("term"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); + result.setBoost(DfTypeUtil.toFloat(source.get("boost"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setMaxSize(DfTypeUtil.toInteger(source.get("maxSize"))); + result.setQuery(DfTypeUtil.toString(source.get("query"))); + result.setTerm(DfTypeUtil.toString(source.get("term"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -226,4 +227,9 @@ public abstract class BsKeyMatchBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setId(toString(source.get("id"))); - result.setLabelTypeId(toString(source.get("labelTypeId"))); - result.setRoleTypeId(toString(source.get("roleTypeId"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setLabelTypeId(DfTypeUtil.toString(source.get("labelTypeId"))); + result.setRoleTypeId(DfTypeUtil.toString(source.get("roleTypeId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -220,4 +221,9 @@ public abstract class BsLabelToRoleBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setExcludedPaths(toString(source.get("excludedPaths"))); - result.setId(toString(source.get("id"))); - result.setIncludedPaths(toString(source.get("includedPaths"))); - result.setName(toString(source.get("name"))); - result.setSortOrder(toInteger(source.get("sortOrder"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); - result.setValue(toString(source.get("value"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setExcludedPaths(DfTypeUtil.toString(source.get("excludedPaths"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setIncludedPaths(DfTypeUtil.toString(source.get("includedPaths"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + result.setSortOrder(DfTypeUtil.toInteger(source.get("sortOrder"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); + result.setValue(DfTypeUtil.toString(source.get("value"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -227,4 +228,9 @@ public abstract class BsLabelTypeBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setId(toString(source.get("id"))); - result.setOverlappingName(toString(source.get("overlappingName"))); - result.setRegularName(toString(source.get("regularName"))); - result.setSortOrder(toInteger(source.get("sortOrder"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setOverlappingName(DfTypeUtil.toString(source.get("overlappingName"))); + result.setRegularName(DfTypeUtil.toString(source.get("regularName"))); + result.setSortOrder(DfTypeUtil.toInteger(source.get("sortOrder"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -226,4 +227,9 @@ public abstract class BsOverlappingHostBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setId(toString(source.get("id"))); - result.setProcessType(toString(source.get("processType"))); - result.setRegex(toString(source.get("regex"))); - result.setReplacement(toString(source.get("replacement"))); - result.setSortOrder(toInteger(source.get("sortOrder"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setProcessType(DfTypeUtil.toString(source.get("processType"))); + result.setRegex(DfTypeUtil.toString(source.get("regex"))); + result.setReplacement(DfTypeUtil.toString(source.get("replacement"))); + result.setSortOrder(DfTypeUtil.toInteger(source.get("sortOrder"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -226,4 +227,9 @@ public abstract class BsPathMappingBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setId(toString(source.get("id"))); - result.setName(toString(source.get("name"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); - result.setValue(toString(source.get("value"))); - result.setWebConfigId(toString(source.get("webConfigId"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); + result.setValue(DfTypeUtil.toString(source.get("value"))); + result.setWebConfigId(DfTypeUtil.toString(source.get("webConfigId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -225,4 +226,9 @@ public abstract class BsRequestHeaderBhv extends AbstractBehavior { + + @Override + public String asTableDbName() { + return asEsIndexType(); + } + + @Override + protected String asEsIndex() { + return ".fess_user"; + } + + @Override + public String asEsIndexType() { + return "role"; + } + + @Override + public String asEsSearchType() { + return "role"; + } + + @Override + public RoleDbm asDBMeta() { + return RoleDbm.getInstance(); + } + + @Override + protected RESULT createEntity(Map source, Class entityType) { + try { + final RESULT result = entityType.newInstance(); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + return result; + } catch (InstantiationException | IllegalAccessException e) { + final String msg = "Cannot create a new instance: " + entityType.getName(); + throw new IllegalBehaviorStateException(msg, e); + } + } + + public int selectCount(CBCall cbLambda) { + return facadeSelectCount(createCB(cbLambda)); + } + + public OptionalEntity selectEntity(CBCall cbLambda) { + return facadeSelectEntity(createCB(cbLambda)); + } + + protected OptionalEntity facadeSelectEntity(RoleCB cb) { + return doSelectOptionalEntity(cb, typeOfSelectedEntity()); + } + + protected OptionalEntity doSelectOptionalEntity(RoleCB cb, Class tp) { + return createOptionalEntity(doSelectEntity(cb, tp), cb); + } + + @Override + public RoleCB newConditionBean() { + return new RoleCB(); + } + + @Override + protected Entity doReadEntity(ConditionBean cb) { + return facadeSelectEntity(downcast(cb)).orElse(null); + } + + public Role selectEntityWithDeletedCheck(CBCall cbLambda) { + return facadeSelectEntityWithDeletedCheck(createCB(cbLambda)); + } + + public OptionalEntity selectByPK(String id) { + return facadeSelectByPK(id); + } + + protected OptionalEntity facadeSelectByPK(String id) { + return doSelectOptionalByPK(id, typeOfSelectedEntity()); + } + + protected ENTITY doSelectByPK(String id, Class tp) { + return doSelectEntity(xprepareCBAsPK(id), tp); + } + + protected RoleCB xprepareCBAsPK(String id) { + assertObjectNotNull("id", id); + return newConditionBean().acceptPK(id); + } + + protected OptionalEntity doSelectOptionalByPK(String id, Class tp) { + return createOptionalEntity(doSelectByPK(id, tp), id); + } + + @Override + protected Class typeOfSelectedEntity() { + return Role.class; + } + + @Override + protected Class typeOfHandlingEntity() { + return Role.class; + } + + @Override + protected Class typeOfHandlingConditionBean() { + return RoleCB.class; + } + + public ListResultBean selectList(CBCall cbLambda) { + return facadeSelectList(createCB(cbLambda)); + } + + public PagingResultBean selectPage(CBCall cbLambda) { + // TODO same? + return (PagingResultBean) facadeSelectList(createCB(cbLambda)); + } + + public void selectCursor(CBCall cbLambda, EntityRowHandler entityLambda) { + facadeSelectCursor(createCB(cbLambda), entityLambda); + } + + public void selectBulk(CBCall cbLambda, EntityRowHandler> entityLambda) { + delegateSelectBulk(createCB(cbLambda), entityLambda, typeOfSelectedEntity()); + } + + public void insert(Role entity) { + doInsert(entity, null); + } + + public void insert(Role entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doInsert(entity, null); + } + + public void update(Role entity) { + doUpdate(entity, null); + } + + public void update(Role entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doUpdate(entity, null); + } + + public void insertOrUpdate(Role entity) { + doInsertOrUpdate(entity, null, null); + } + + public void insertOrUpdate(Role entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doInsertOrUpdate(entity, null, null); + } + + public void delete(Role entity) { + doDelete(entity, null); + } + + public void delete(Role entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().deleteOption(opLambda); + } + doDelete(entity, null); + } + + public int queryDelete(CBCall cbLambda) { + return doQueryDelete(createCB(cbLambda), null); + } + + public int[] batchInsert(List list) { + return batchInsert(list, null); + } + + public int[] batchInsert(List list, RequestOptionCall call) { + return doBatchInsert(new BulkList<>(list, call), null); + } + + public int[] batchUpdate(List list) { + return batchUpdate(list, null); + } + + public int[] batchUpdate(List list, RequestOptionCall call) { + return doBatchUpdate(new BulkList<>(list, call), null); + } + + public int[] batchDelete(List list) { + return batchDelete(list, null); + } + + public int[] batchDelete(List list, RequestOptionCall call) { + return doBatchDelete(new BulkList<>(list, call), null); + } + + // TODO create, modify, remove + + @Override + protected boolean isCompatibleBatchInsertDefaultEveryColumn() { + return true; + } +} diff --git a/src/main/java/org/codelibs/fess/es/bsbhv/BsRoleTypeBhv.java b/src/main/java/org/codelibs/fess/es/bsbhv/BsRoleTypeBhv.java index 4f2c5982c..0a74ae61a 100644 --- a/src/main/java/org/codelibs/fess/es/bsbhv/BsRoleTypeBhv.java +++ b/src/main/java/org/codelibs/fess/es/bsbhv/BsRoleTypeBhv.java @@ -16,6 +16,7 @@ import org.dbflute.cbean.result.ListResultBean; import org.dbflute.cbean.result.PagingResultBean; import org.dbflute.exception.IllegalBehaviorStateException; import org.dbflute.optional.OptionalEntity; +import org.dbflute.util.DfTypeUtil; import org.elasticsearch.action.bulk.BulkRequestBuilder; import org.elasticsearch.action.delete.DeleteRequestBuilder; import org.elasticsearch.action.index.IndexRequestBuilder; @@ -54,14 +55,14 @@ public abstract class BsRoleTypeBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setId(toString(source.get("id"))); - result.setName(toString(source.get("name"))); - result.setSortOrder(toInteger(source.get("sortOrder"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); - result.setValue(toString(source.get("value"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + result.setSortOrder(DfTypeUtil.toInteger(source.get("sortOrder"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); + result.setValue(DfTypeUtil.toString(source.get("value"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -225,4 +226,9 @@ public abstract class BsRoleTypeBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setAvailable(toBoolean(source.get("available"))); - result.setCrawler(toBoolean(source.get("crawler"))); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setCronExpression(toString(source.get("cronExpression"))); - result.setId(toString(source.get("id"))); - result.setJobLogging(toBoolean(source.get("jobLogging"))); - result.setName(toString(source.get("name"))); - result.setScriptData(toString(source.get("scriptData"))); - result.setScriptType(toString(source.get("scriptType"))); - result.setSortOrder(toInteger(source.get("sortOrder"))); - result.setTarget(toString(source.get("target"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); + result.setAvailable(DfTypeUtil.toBoolean(source.get("available"))); + result.setCrawler(DfTypeUtil.toBoolean(source.get("crawler"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setCronExpression(DfTypeUtil.toString(source.get("cronExpression"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setJobLogging(DfTypeUtil.toBoolean(source.get("jobLogging"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + result.setScriptData(DfTypeUtil.toString(source.get("scriptData"))); + result.setScriptType(DfTypeUtil.toString(source.get("scriptType"))); + result.setSortOrder(DfTypeUtil.toInteger(source.get("sortOrder"))); + result.setTarget(DfTypeUtil.toString(source.get("target"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -231,4 +232,9 @@ public abstract class BsScheduledJobBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setId(toString(source.get("id"))); - result.setName(toString(source.get("name"))); - result.setSearchLogId(toString(source.get("searchLogId"))); - result.setValue(toString(source.get("value"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + result.setSearchLogId(DfTypeUtil.toString(source.get("searchLogId"))); + result.setValue(DfTypeUtil.toString(source.get("value"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -221,4 +222,9 @@ public abstract class BsSearchFieldLogBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setAccessType(toString(source.get("accessType"))); - result.setClientIp(toString(source.get("clientIp"))); - result.setHitCount(toLong(source.get("hitCount"))); - result.setId(toString(source.get("id"))); - result.setQueryOffset(toInteger(source.get("queryOffset"))); - result.setQueryPageSize(toInteger(source.get("queryPageSize"))); - result.setReferer(toString(source.get("referer"))); - result.setRequestedTime(toLong(source.get("requestedTime"))); - result.setResponseTime(toInteger(source.get("responseTime"))); - result.setSearchWord(toString(source.get("searchWord"))); - result.setUserAgent(toString(source.get("userAgent"))); - result.setUserInfoId(toString(source.get("userInfoId"))); - result.setUserSessionId(toString(source.get("userSessionId"))); + result.setAccessType(DfTypeUtil.toString(source.get("accessType"))); + result.setClientIp(DfTypeUtil.toString(source.get("clientIp"))); + result.setHitCount(DfTypeUtil.toLong(source.get("hitCount"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setQueryOffset(DfTypeUtil.toInteger(source.get("queryOffset"))); + result.setQueryPageSize(DfTypeUtil.toInteger(source.get("queryPageSize"))); + result.setReferer(DfTypeUtil.toString(source.get("referer"))); + result.setRequestedTime(DfTypeUtil.toLong(source.get("requestedTime"))); + result.setResponseTime(DfTypeUtil.toInteger(source.get("responseTime"))); + result.setSearchWord(DfTypeUtil.toString(source.get("searchWord"))); + result.setUserAgent(DfTypeUtil.toString(source.get("userAgent"))); + result.setUserInfoId(DfTypeUtil.toString(source.get("userInfoId"))); + result.setUserSessionId(DfTypeUtil.toString(source.get("userSessionId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -230,4 +231,9 @@ public abstract class BsSearchLogBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setId(toString(source.get("id"))); - result.setSuggestWord(toString(source.get("suggestWord"))); - result.setTargetLabel(toString(source.get("targetLabel"))); - result.setTargetRole(toString(source.get("targetRole"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setSuggestWord(DfTypeUtil.toString(source.get("suggestWord"))); + result.setTargetLabel(DfTypeUtil.toString(source.get("targetLabel"))); + result.setTargetRole(DfTypeUtil.toString(source.get("targetRole"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -225,4 +226,9 @@ public abstract class BsSuggestBadWordBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setBoost(toFloat(source.get("boost"))); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setId(toString(source.get("id"))); - result.setReading(toString(source.get("reading"))); - result.setSuggestWord(toString(source.get("suggestWord"))); - result.setTargetLabel(toString(source.get("targetLabel"))); - result.setTargetRole(toString(source.get("targetRole"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); + result.setBoost(DfTypeUtil.toFloat(source.get("boost"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setReading(DfTypeUtil.toString(source.get("reading"))); + result.setSuggestWord(DfTypeUtil.toString(source.get("suggestWord"))); + result.setTargetLabel(DfTypeUtil.toString(source.get("targetLabel"))); + result.setTargetRole(DfTypeUtil.toString(source.get("targetRole"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -228,4 +229,9 @@ public abstract class BsSuggestElevateWordBhv extends AbstractBehavior { + + @Override + public String asTableDbName() { + return asEsIndexType(); + } + + @Override + protected String asEsIndex() { + return ".fess_user"; + } + + @Override + public String asEsIndexType() { + return "user"; + } + + @Override + public String asEsSearchType() { + return "user"; + } + + @Override + public UserDbm asDBMeta() { + return UserDbm.getInstance(); + } + + @Override + protected RESULT createEntity(Map source, Class entityType) { + try { + final RESULT result = entityType.newInstance(); + result.setGroups(toStringArray(source.get("groups"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + result.setPassword(DfTypeUtil.toString(source.get("password"))); + result.setRoles(toStringArray(source.get("roles"))); + return result; + } catch (InstantiationException | IllegalAccessException e) { + final String msg = "Cannot create a new instance: " + entityType.getName(); + throw new IllegalBehaviorStateException(msg, e); + } + } + + public int selectCount(CBCall cbLambda) { + return facadeSelectCount(createCB(cbLambda)); + } + + public OptionalEntity selectEntity(CBCall cbLambda) { + return facadeSelectEntity(createCB(cbLambda)); + } + + protected OptionalEntity facadeSelectEntity(UserCB cb) { + return doSelectOptionalEntity(cb, typeOfSelectedEntity()); + } + + protected OptionalEntity doSelectOptionalEntity(UserCB cb, Class tp) { + return createOptionalEntity(doSelectEntity(cb, tp), cb); + } + + @Override + public UserCB newConditionBean() { + return new UserCB(); + } + + @Override + protected Entity doReadEntity(ConditionBean cb) { + return facadeSelectEntity(downcast(cb)).orElse(null); + } + + public User selectEntityWithDeletedCheck(CBCall cbLambda) { + return facadeSelectEntityWithDeletedCheck(createCB(cbLambda)); + } + + public OptionalEntity selectByPK(String id) { + return facadeSelectByPK(id); + } + + protected OptionalEntity facadeSelectByPK(String id) { + return doSelectOptionalByPK(id, typeOfSelectedEntity()); + } + + protected ENTITY doSelectByPK(String id, Class tp) { + return doSelectEntity(xprepareCBAsPK(id), tp); + } + + protected UserCB xprepareCBAsPK(String id) { + assertObjectNotNull("id", id); + return newConditionBean().acceptPK(id); + } + + protected OptionalEntity doSelectOptionalByPK(String id, Class tp) { + return createOptionalEntity(doSelectByPK(id, tp), id); + } + + @Override + protected Class typeOfSelectedEntity() { + return User.class; + } + + @Override + protected Class typeOfHandlingEntity() { + return User.class; + } + + @Override + protected Class typeOfHandlingConditionBean() { + return UserCB.class; + } + + public ListResultBean selectList(CBCall cbLambda) { + return facadeSelectList(createCB(cbLambda)); + } + + public PagingResultBean selectPage(CBCall cbLambda) { + // TODO same? + return (PagingResultBean) facadeSelectList(createCB(cbLambda)); + } + + public void selectCursor(CBCall cbLambda, EntityRowHandler entityLambda) { + facadeSelectCursor(createCB(cbLambda), entityLambda); + } + + public void selectBulk(CBCall cbLambda, EntityRowHandler> entityLambda) { + delegateSelectBulk(createCB(cbLambda), entityLambda, typeOfSelectedEntity()); + } + + public void insert(User entity) { + doInsert(entity, null); + } + + public void insert(User entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doInsert(entity, null); + } + + public void update(User entity) { + doUpdate(entity, null); + } + + public void update(User entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doUpdate(entity, null); + } + + public void insertOrUpdate(User entity) { + doInsertOrUpdate(entity, null, null); + } + + public void insertOrUpdate(User entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().indexOption(opLambda); + } + doInsertOrUpdate(entity, null, null); + } + + public void delete(User entity) { + doDelete(entity, null); + } + + public void delete(User entity, RequestOptionCall opLambda) { + if (entity instanceof AbstractEntity) { + entity.asDocMeta().deleteOption(opLambda); + } + doDelete(entity, null); + } + + public int queryDelete(CBCall cbLambda) { + return doQueryDelete(createCB(cbLambda), null); + } + + public int[] batchInsert(List list) { + return batchInsert(list, null); + } + + public int[] batchInsert(List list, RequestOptionCall call) { + return doBatchInsert(new BulkList<>(list, call), null); + } + + public int[] batchUpdate(List list) { + return batchUpdate(list, null); + } + + public int[] batchUpdate(List list, RequestOptionCall call) { + return doBatchUpdate(new BulkList<>(list, call), null); + } + + public int[] batchDelete(List list) { + return batchDelete(list, null); + } + + public int[] batchDelete(List list, RequestOptionCall call) { + return doBatchDelete(new BulkList<>(list, call), null); + } + + // TODO create, modify, remove + + @Override + protected boolean isCompatibleBatchInsertDefaultEveryColumn() { + return true; + } +} diff --git a/src/main/java/org/codelibs/fess/es/bsbhv/BsUserInfoBhv.java b/src/main/java/org/codelibs/fess/es/bsbhv/BsUserInfoBhv.java index 08c50ccf1..5e0629394 100644 --- a/src/main/java/org/codelibs/fess/es/bsbhv/BsUserInfoBhv.java +++ b/src/main/java/org/codelibs/fess/es/bsbhv/BsUserInfoBhv.java @@ -16,6 +16,7 @@ import org.dbflute.cbean.result.ListResultBean; import org.dbflute.cbean.result.PagingResultBean; import org.dbflute.exception.IllegalBehaviorStateException; import org.dbflute.optional.OptionalEntity; +import org.dbflute.util.DfTypeUtil; import org.elasticsearch.action.bulk.BulkRequestBuilder; import org.elasticsearch.action.delete.DeleteRequestBuilder; import org.elasticsearch.action.index.IndexRequestBuilder; @@ -32,7 +33,7 @@ public abstract class BsUserInfoBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setCode(toString(source.get("code"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setId(toString(source.get("id"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); + result.setCode(DfTypeUtil.toString(source.get("code"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -221,4 +222,9 @@ public abstract class BsUserInfoBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setAuthRealm(toString(source.get("authRealm"))); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setHostname(toString(source.get("hostname"))); - result.setId(toString(source.get("id"))); - result.setParameters(toString(source.get("parameters"))); - result.setPassword(toString(source.get("password"))); - result.setPort(toInteger(source.get("port"))); - result.setProtocolScheme(toString(source.get("protocolScheme"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); - result.setUsername(toString(source.get("username"))); - result.setWebConfigId(toString(source.get("webConfigId"))); + result.setAuthRealm(DfTypeUtil.toString(source.get("authRealm"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setHostname(DfTypeUtil.toString(source.get("hostname"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setParameters(DfTypeUtil.toString(source.get("parameters"))); + result.setPassword(DfTypeUtil.toString(source.get("password"))); + result.setPort(DfTypeUtil.toInteger(source.get("port"))); + result.setProtocolScheme(DfTypeUtil.toString(source.get("protocolScheme"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); + result.setUsername(DfTypeUtil.toString(source.get("username"))); + result.setWebConfigId(DfTypeUtil.toString(source.get("webConfigId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -231,4 +232,9 @@ public abstract class BsWebAuthenticationBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setAvailable(toBoolean(source.get("available"))); - result.setBoost(toFloat(source.get("boost"))); - result.setConfigParameter(toString(source.get("configParameter"))); - result.setCreatedBy(toString(source.get("createdBy"))); - result.setCreatedTime(toLong(source.get("createdTime"))); - result.setDepth(toInteger(source.get("depth"))); - result.setExcludedDocUrls(toString(source.get("excludedDocUrls"))); - result.setExcludedUrls(toString(source.get("excludedUrls"))); - result.setId(toString(source.get("id"))); - result.setIncludedDocUrls(toString(source.get("includedDocUrls"))); - result.setIncludedUrls(toString(source.get("includedUrls"))); - result.setIntervalTime(toInteger(source.get("intervalTime"))); - result.setMaxAccessCount(toLong(source.get("maxAccessCount"))); - result.setName(toString(source.get("name"))); - result.setNumOfThread(toInteger(source.get("numOfThread"))); - result.setSortOrder(toInteger(source.get("sortOrder"))); - result.setUpdatedBy(toString(source.get("updatedBy"))); - result.setUpdatedTime(toLong(source.get("updatedTime"))); - result.setUrls(toString(source.get("urls"))); - result.setUserAgent(toString(source.get("userAgent"))); + result.setAvailable(DfTypeUtil.toBoolean(source.get("available"))); + result.setBoost(DfTypeUtil.toFloat(source.get("boost"))); + result.setConfigParameter(DfTypeUtil.toString(source.get("configParameter"))); + result.setCreatedBy(DfTypeUtil.toString(source.get("createdBy"))); + result.setCreatedTime(DfTypeUtil.toLong(source.get("createdTime"))); + result.setDepth(DfTypeUtil.toInteger(source.get("depth"))); + result.setExcludedDocUrls(DfTypeUtil.toString(source.get("excludedDocUrls"))); + result.setExcludedUrls(DfTypeUtil.toString(source.get("excludedUrls"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setIncludedDocUrls(DfTypeUtil.toString(source.get("includedDocUrls"))); + result.setIncludedUrls(DfTypeUtil.toString(source.get("includedUrls"))); + result.setIntervalTime(DfTypeUtil.toInteger(source.get("intervalTime"))); + result.setMaxAccessCount(DfTypeUtil.toLong(source.get("maxAccessCount"))); + result.setName(DfTypeUtil.toString(source.get("name"))); + result.setNumOfThread(DfTypeUtil.toInteger(source.get("numOfThread"))); + result.setSortOrder(DfTypeUtil.toInteger(source.get("sortOrder"))); + result.setUpdatedBy(DfTypeUtil.toString(source.get("updatedBy"))); + result.setUpdatedTime(DfTypeUtil.toLong(source.get("updatedTime"))); + result.setUrls(DfTypeUtil.toString(source.get("urls"))); + result.setUserAgent(DfTypeUtil.toString(source.get("userAgent"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -237,4 +238,9 @@ public abstract class BsWebConfigBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setId(toString(source.get("id"))); - result.setLabelTypeId(toString(source.get("labelTypeId"))); - result.setWebConfigId(toString(source.get("webConfigId"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setLabelTypeId(DfTypeUtil.toString(source.get("labelTypeId"))); + result.setWebConfigId(DfTypeUtil.toString(source.get("webConfigId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -221,4 +222,9 @@ public abstract class BsWebConfigToLabelBhv extends AbstractBehavior RESULT createEntity(Map source, Class entityType) { try { final RESULT result = entityType.newInstance(); - result.setId(toString(source.get("id"))); - result.setRoleTypeId(toString(source.get("roleTypeId"))); - result.setWebConfigId(toString(source.get("webConfigId"))); + result.setId(DfTypeUtil.toString(source.get("id"))); + result.setRoleTypeId(DfTypeUtil.toString(source.get("roleTypeId"))); + result.setWebConfigId(DfTypeUtil.toString(source.get("webConfigId"))); return result; } catch (InstantiationException | IllegalAccessException e) { final String msg = "Cannot create a new instance: " + entityType.getName(); @@ -221,4 +222,9 @@ public abstract class BsWebConfigToRoleBhv extends AbstractBehavior toSource(); - public class DocMeta { + public class DocMeta implements Serializable { + + private static final long serialVersionUID = 1L; protected String id; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsBoostDocumentRule.java b/src/main/java/org/codelibs/fess/es/bsentity/BsBoostDocumentRule.java index 04cc5ae8c..a1df38e89 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsBoostDocumentRule.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsBoostDocumentRule.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsClickLog.java b/src/main/java/org/codelibs/fess/es/bsentity/BsClickLog.java index 47fbc1663..b0c63a33b 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsClickLog.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsClickLog.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsCrawlingSession.java b/src/main/java/org/codelibs/fess/es/bsentity/BsCrawlingSession.java index 5cf3ad383..baf3c50fb 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsCrawlingSession.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsCrawlingSession.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsCrawlingSessionInfo.java b/src/main/java/org/codelibs/fess/es/bsentity/BsCrawlingSessionInfo.java index 276abda61..4bb99f473 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsCrawlingSessionInfo.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsCrawlingSessionInfo.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfig.java b/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfig.java index ccb9673e2..a1a7e198d 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfig.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfig.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfigToLabel.java b/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfigToLabel.java index 6466685b1..a86f19cbf 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfigToLabel.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfigToLabel.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfigToRole.java b/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfigToRole.java index af4de0936..33ce7be15 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfigToRole.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsDataConfigToRole.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsEventLog.java b/src/main/java/org/codelibs/fess/es/bsentity/BsEventLog.java new file mode 100644 index 000000000..c2642a218 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsEventLog.java @@ -0,0 +1,133 @@ +package org.codelibs.fess.es.bsentity; + +import java.time.LocalDateTime; +import java.util.HashMap; +import java.util.Map; + +import org.codelibs.fess.es.bsentity.dbmeta.EventLogDbm; + +/** + * ${table.comment} + * @author FreeGen + */ +public class BsEventLog extends AbstractEntity { + + private static final long serialVersionUID = 1L; + + @Override + public EventLogDbm asDBMeta() { + return EventLogDbm.getInstance(); + } + + @Override + public String asTableDbName() { + return "event_log"; + } + + // =================================================================================== + // Attribute + // ========= + /** createdAt */ + protected LocalDateTime createdAt; + + /** createdBy */ + protected String createdBy; + + /** eventType */ + protected String eventType; + + /** message */ + protected String message; + + /** path */ + protected String path; + + // [Referrers] *comment only + + // =================================================================================== + // Accessor + // ======== + public LocalDateTime getCreatedAt() { + checkSpecifiedProperty("createdAt"); + return createdAt; + } + + public void setCreatedAt(LocalDateTime value) { + registerModifiedProperty("createdAt"); + this.createdAt = value; + } + + public String getCreatedBy() { + checkSpecifiedProperty("createdBy"); + return createdBy; + } + + public void setCreatedBy(String value) { + registerModifiedProperty("createdBy"); + this.createdBy = value; + } + + public String getEventType() { + checkSpecifiedProperty("eventType"); + return eventType; + } + + public void setEventType(String value) { + registerModifiedProperty("eventType"); + this.eventType = value; + } + + public String getId() { + checkSpecifiedProperty("id"); + return asDocMeta().id(); + } + + public void setId(String value) { + registerModifiedProperty("id"); + asDocMeta().id(value); + } + + public String getMessage() { + checkSpecifiedProperty("message"); + return message; + } + + public void setMessage(String value) { + registerModifiedProperty("message"); + this.message = value; + } + + public String getPath() { + checkSpecifiedProperty("path"); + return path; + } + + public void setPath(String value) { + registerModifiedProperty("path"); + this.path = value; + } + + @Override + public Map toSource() { + Map sourceMap = new HashMap<>(); + if (createdAt != null) { + sourceMap.put("createdAt", createdAt); + } + if (createdBy != null) { + sourceMap.put("createdBy", createdBy); + } + if (eventType != null) { + sourceMap.put("eventType", eventType); + } + if (asDocMeta().id() != null) { + sourceMap.put("id", asDocMeta().id()); + } + if (message != null) { + sourceMap.put("message", message); + } + if (path != null) { + sourceMap.put("path", path); + } + return sourceMap; + } +} diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsFailureUrl.java b/src/main/java/org/codelibs/fess/es/bsentity/BsFailureUrl.java index 7c057d97d..4e26b1521 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsFailureUrl.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsFailureUrl.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsFavoriteLog.java b/src/main/java/org/codelibs/fess/es/bsentity/BsFavoriteLog.java index 25eef1311..df13b5393 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsFavoriteLog.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsFavoriteLog.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsFileAuthentication.java b/src/main/java/org/codelibs/fess/es/bsentity/BsFileAuthentication.java index a7f4c4acd..5b601eff7 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsFileAuthentication.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsFileAuthentication.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfig.java b/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfig.java index 8f59c8abb..fc6f446cd 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfig.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfig.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfigToLabel.java b/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfigToLabel.java index 390c6e37a..158d10c07 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfigToLabel.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfigToLabel.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfigToRole.java b/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfigToRole.java index 855ae1917..9846be12d 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfigToRole.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsFileConfigToRole.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsGroup.java b/src/main/java/org/codelibs/fess/es/bsentity/BsGroup.java new file mode 100644 index 000000000..53d94a621 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsGroup.java @@ -0,0 +1,68 @@ +package org.codelibs.fess.es.bsentity; + +import java.util.HashMap; +import java.util.Map; + +import org.codelibs.fess.es.bsentity.dbmeta.GroupDbm; + +/** + * ${table.comment} + * @author FreeGen + */ +public class BsGroup extends AbstractEntity { + + private static final long serialVersionUID = 1L; + + @Override + public GroupDbm asDBMeta() { + return GroupDbm.getInstance(); + } + + @Override + public String asTableDbName() { + return "group"; + } + + // =================================================================================== + // Attribute + // ========= + /** name */ + protected String name; + + // [Referrers] *comment only + + // =================================================================================== + // Accessor + // ======== + public String getId() { + checkSpecifiedProperty("id"); + return asDocMeta().id(); + } + + public void setId(String value) { + registerModifiedProperty("id"); + asDocMeta().id(value); + } + + public String getName() { + checkSpecifiedProperty("name"); + return name; + } + + public void setName(String value) { + registerModifiedProperty("name"); + this.name = value; + } + + @Override + public Map toSource() { + Map sourceMap = new HashMap<>(); + if (asDocMeta().id() != null) { + sourceMap.put("id", asDocMeta().id()); + } + if (name != null) { + sourceMap.put("name", name); + } + return sourceMap; + } +} diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsJobLog.java b/src/main/java/org/codelibs/fess/es/bsentity/BsJobLog.java index b5f1f49b6..ba9d5c01f 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsJobLog.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsJobLog.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsKeyMatch.java b/src/main/java/org/codelibs/fess/es/bsentity/BsKeyMatch.java index a76d3137f..24ddf955e 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsKeyMatch.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsKeyMatch.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsLabelToRole.java b/src/main/java/org/codelibs/fess/es/bsentity/BsLabelToRole.java index babafb786..e22a058a5 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsLabelToRole.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsLabelToRole.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsLabelType.java b/src/main/java/org/codelibs/fess/es/bsentity/BsLabelType.java index 91e1e53e0..0a0ef45b9 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsLabelType.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsLabelType.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsOverlappingHost.java b/src/main/java/org/codelibs/fess/es/bsentity/BsOverlappingHost.java index b7c14be1c..ecf143428 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsOverlappingHost.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsOverlappingHost.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsPathMapping.java b/src/main/java/org/codelibs/fess/es/bsentity/BsPathMapping.java index 287a8e5f1..9c3b898ac 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsPathMapping.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsPathMapping.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsRequestHeader.java b/src/main/java/org/codelibs/fess/es/bsentity/BsRequestHeader.java index 3e1d7aa8c..011fdb16b 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsRequestHeader.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsRequestHeader.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsRole.java b/src/main/java/org/codelibs/fess/es/bsentity/BsRole.java new file mode 100644 index 000000000..34f27defe --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsRole.java @@ -0,0 +1,68 @@ +package org.codelibs.fess.es.bsentity; + +import java.util.HashMap; +import java.util.Map; + +import org.codelibs.fess.es.bsentity.dbmeta.RoleDbm; + +/** + * ${table.comment} + * @author FreeGen + */ +public class BsRole extends AbstractEntity { + + private static final long serialVersionUID = 1L; + + @Override + public RoleDbm asDBMeta() { + return RoleDbm.getInstance(); + } + + @Override + public String asTableDbName() { + return "role"; + } + + // =================================================================================== + // Attribute + // ========= + /** name */ + protected String name; + + // [Referrers] *comment only + + // =================================================================================== + // Accessor + // ======== + public String getId() { + checkSpecifiedProperty("id"); + return asDocMeta().id(); + } + + public void setId(String value) { + registerModifiedProperty("id"); + asDocMeta().id(value); + } + + public String getName() { + checkSpecifiedProperty("name"); + return name; + } + + public void setName(String value) { + registerModifiedProperty("name"); + this.name = value; + } + + @Override + public Map toSource() { + Map sourceMap = new HashMap<>(); + if (asDocMeta().id() != null) { + sourceMap.put("id", asDocMeta().id()); + } + if (name != null) { + sourceMap.put("name", name); + } + return sourceMap; + } +} diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsRoleType.java b/src/main/java/org/codelibs/fess/es/bsentity/BsRoleType.java index abbe6dbce..e788179b8 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsRoleType.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsRoleType.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsScheduledJob.java b/src/main/java/org/codelibs/fess/es/bsentity/BsScheduledJob.java index f4575527f..61f05ae85 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsScheduledJob.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsScheduledJob.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsSearchFieldLog.java b/src/main/java/org/codelibs/fess/es/bsentity/BsSearchFieldLog.java index 4331176d3..e25b90b3c 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsSearchFieldLog.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsSearchFieldLog.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsSearchLog.java b/src/main/java/org/codelibs/fess/es/bsentity/BsSearchLog.java index 5802c8e23..f050d77d3 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsSearchLog.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsSearchLog.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsSuggestBadWord.java b/src/main/java/org/codelibs/fess/es/bsentity/BsSuggestBadWord.java index 8153cafc5..5c9f8285c 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsSuggestBadWord.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsSuggestBadWord.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsSuggestElevateWord.java b/src/main/java/org/codelibs/fess/es/bsentity/BsSuggestElevateWord.java index c1cc0c61e..cf9b03e72 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsSuggestElevateWord.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsSuggestElevateWord.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsUser.java b/src/main/java/org/codelibs/fess/es/bsentity/BsUser.java new file mode 100644 index 000000000..aa78453ef --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsUser.java @@ -0,0 +1,116 @@ +package org.codelibs.fess.es.bsentity; + +import java.util.HashMap; +import java.util.Map; + +import org.codelibs.fess.es.bsentity.dbmeta.UserDbm; + +/** + * ${table.comment} + * @author FreeGen + */ +public class BsUser extends AbstractEntity { + + private static final long serialVersionUID = 1L; + + @Override + public UserDbm asDBMeta() { + return UserDbm.getInstance(); + } + + @Override + public String asTableDbName() { + return "user"; + } + + // =================================================================================== + // Attribute + // ========= + /** groups */ + protected String[] groups; + + /** name */ + protected String name; + + /** password */ + protected String password; + + /** roles */ + protected String[] roles; + + // [Referrers] *comment only + + // =================================================================================== + // Accessor + // ======== + public String[] getGroups() { + checkSpecifiedProperty("groups"); + return groups; + } + + public void setGroups(String[] value) { + registerModifiedProperty("groups"); + this.groups = value; + } + + public String getId() { + checkSpecifiedProperty("id"); + return asDocMeta().id(); + } + + public void setId(String value) { + registerModifiedProperty("id"); + asDocMeta().id(value); + } + + public String getName() { + checkSpecifiedProperty("name"); + return name; + } + + public void setName(String value) { + registerModifiedProperty("name"); + this.name = value; + } + + public String getPassword() { + checkSpecifiedProperty("password"); + return password; + } + + public void setPassword(String value) { + registerModifiedProperty("password"); + this.password = value; + } + + public String[] getRoles() { + checkSpecifiedProperty("roles"); + return roles; + } + + public void setRoles(String[] value) { + registerModifiedProperty("roles"); + this.roles = value; + } + + @Override + public Map toSource() { + Map sourceMap = new HashMap<>(); + if (groups != null) { + sourceMap.put("groups", groups); + } + if (asDocMeta().id() != null) { + sourceMap.put("id", asDocMeta().id()); + } + if (name != null) { + sourceMap.put("name", name); + } + if (password != null) { + sourceMap.put("password", password); + } + if (roles != null) { + sourceMap.put("roles", roles); + } + return sourceMap; + } +} diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsUserInfo.java b/src/main/java/org/codelibs/fess/es/bsentity/BsUserInfo.java index db72313c2..25eb2a8b4 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsUserInfo.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsUserInfo.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsWebAuthentication.java b/src/main/java/org/codelibs/fess/es/bsentity/BsWebAuthentication.java index 5b8afa1f3..1e92f873b 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsWebAuthentication.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsWebAuthentication.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfig.java b/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfig.java index 5a0176846..bca819ebd 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfig.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfig.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfigToLabel.java b/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfigToLabel.java index 368fc2264..0e9e2a748 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfigToLabel.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfigToLabel.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfigToRole.java b/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfigToRole.java index 9e79081fc..ac3dfc6eb 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfigToRole.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/BsWebConfigToRole.java @@ -1,6 +1,5 @@ package org.codelibs.fess.es.bsentity; -import java.time.LocalDateTime; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/BoostDocumentRuleDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/BoostDocumentRuleDbm.java index 6f9214e4f..7e3a84fdf 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/BoostDocumentRuleDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/BoostDocumentRuleDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.BoostDocumentRule; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class BoostDocumentRuleDbm extends AbstractDBMeta { @@ -24,6 +27,127 @@ public class BoostDocumentRuleDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((BoostDocumentRule) et).getBoostExpr(), + (et, vl) -> ((BoostDocumentRule) et).setBoostExpr(DfTypeUtil.toString(vl)), "boostExpr"); + setupEpg(_epgMap, et -> ((BoostDocumentRule) et).getCreatedBy(), + (et, vl) -> ((BoostDocumentRule) et).setCreatedBy(DfTypeUtil.toString(vl)), "createdBy"); + setupEpg(_epgMap, et -> ((BoostDocumentRule) et).getCreatedTime(), + (et, vl) -> ((BoostDocumentRule) et).setCreatedTime(DfTypeUtil.toLong(vl)), "createdTime"); + setupEpg(_epgMap, et -> ((BoostDocumentRule) et).getId(), (et, vl) -> ((BoostDocumentRule) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((BoostDocumentRule) et).getSortOrder(), + (et, vl) -> ((BoostDocumentRule) et).setSortOrder(DfTypeUtil.toInteger(vl)), "sortOrder"); + setupEpg(_epgMap, et -> ((BoostDocumentRule) et).getUpdatedBy(), + (et, vl) -> ((BoostDocumentRule) et).setUpdatedBy(DfTypeUtil.toString(vl)), "updatedBy"); + setupEpg(_epgMap, et -> ((BoostDocumentRule) et).getUpdatedTime(), + (et, vl) -> ((BoostDocumentRule) et).setUpdatedTime(DfTypeUtil.toLong(vl)), "updatedTime"); + setupEpg(_epgMap, et -> ((BoostDocumentRule) et).getUrlExpr(), + (et, vl) -> ((BoostDocumentRule) et).setUrlExpr(DfTypeUtil.toString(vl)), "urlExpr"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnBoostExpr = cci("boostExpr", "boostExpr", null, null, String.class, "boostExpr", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnSortOrder = cci("sortOrder", "sortOrder", null, null, Integer.class, "sortOrder", null, false, false, + false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUrlExpr = cci("urlExpr", "urlExpr", null, null, String.class, "urlExpr", null, false, false, false, + "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnBoostExpr() { + return _columnBoostExpr; + } + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnSortOrder() { + return _columnSortOrder; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + public ColumnInfo columnUrlExpr() { + return _columnUrlExpr; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnBoostExpr()); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnId()); + ls.add(columnSortOrder()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + ls.add(columnUrlExpr()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "boost_document_rule"; + protected final String _tableDispName = "boost_document_rule"; + protected final String _tablePropertyName = "BoostDocumentRule"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +172,6 @@ public class BoostDocumentRuleDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +186,27 @@ public class BoostDocumentRuleDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.BoostDocumentRule"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.BoostDocumentRuleCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.BoostDocumentRuleBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return BoostDocumentRule.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new BoostDocumentRule(); } @Override @@ -138,12 +233,6 @@ public class BoostDocumentRuleDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/ClickLogDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/ClickLogDbm.java index fdd73e5a8..259eac5ae 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/ClickLogDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/ClickLogDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.ClickLog; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class ClickLogDbm extends AbstractDBMeta { @@ -24,6 +27,90 @@ public class ClickLogDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((ClickLog) et).getId(), (et, vl) -> ((ClickLog) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((ClickLog) et).getRequestedTime(), (et, vl) -> ((ClickLog) et).setRequestedTime(DfTypeUtil.toLong(vl)), + "requestedTime"); + setupEpg(_epgMap, et -> ((ClickLog) et).getSearchLogId(), (et, vl) -> ((ClickLog) et).setSearchLogId(DfTypeUtil.toString(vl)), + "searchLogId"); + setupEpg(_epgMap, et -> ((ClickLog) et).getUrl(), (et, vl) -> ((ClickLog) et).setUrl(DfTypeUtil.toString(vl)), "url"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnRequestedTime = cci("requestedTime", "requestedTime", null, null, Long.class, "requestedTime", null, + false, false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSearchLogId = cci("searchLogId", "searchLogId", null, null, String.class, "searchLogId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUrl = cci("url", "url", null, null, String.class, "url", null, false, false, false, "String", 0, 0, + null, false, null, null, null, null, null, false); + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnRequestedTime() { + return _columnRequestedTime; + } + + public ColumnInfo columnSearchLogId() { + return _columnSearchLogId; + } + + public ColumnInfo columnUrl() { + return _columnUrl; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnId()); + ls.add(columnRequestedTime()); + ls.add(columnSearchLogId()); + ls.add(columnUrl()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "click_log"; + protected final String _tableDispName = "click_log"; + protected final String _tablePropertyName = "ClickLog"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +135,6 @@ public class ClickLogDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +149,27 @@ public class ClickLogDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.ClickLog"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.ClickLogCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.ClickLogBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return ClickLog.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new ClickLog(); } @Override @@ -138,12 +196,6 @@ public class ClickLogDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/CrawlingSessionDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/CrawlingSessionDbm.java index 0fdf43a65..69c402d13 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/CrawlingSessionDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/CrawlingSessionDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.CrawlingSession; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class CrawlingSessionDbm extends AbstractDBMeta { @@ -24,6 +27,100 @@ public class CrawlingSessionDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((CrawlingSession) et).getCreatedTime(), + (et, vl) -> ((CrawlingSession) et).setCreatedTime(DfTypeUtil.toLong(vl)), "createdTime"); + setupEpg(_epgMap, et -> ((CrawlingSession) et).getExpiredTime(), + (et, vl) -> ((CrawlingSession) et).setExpiredTime(DfTypeUtil.toLong(vl)), "expiredTime"); + setupEpg(_epgMap, et -> ((CrawlingSession) et).getId(), (et, vl) -> ((CrawlingSession) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((CrawlingSession) et).getName(), (et, vl) -> ((CrawlingSession) et).setName(DfTypeUtil.toString(vl)), + "name"); + setupEpg(_epgMap, et -> ((CrawlingSession) et).getSessionId(), + (et, vl) -> ((CrawlingSession) et).setSessionId(DfTypeUtil.toString(vl)), "sessionId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnExpiredTime = cci("expiredTime", "expiredTime", null, null, Long.class, "expiredTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSessionId = cci("sessionId", "sessionId", null, null, String.class, "sessionId", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnExpiredTime() { + return _columnExpiredTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnName() { + return _columnName; + } + + public ColumnInfo columnSessionId() { + return _columnSessionId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCreatedTime()); + ls.add(columnExpiredTime()); + ls.add(columnId()); + ls.add(columnName()); + ls.add(columnSessionId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "crawling_session"; + protected final String _tableDispName = "crawling_session"; + protected final String _tablePropertyName = "CrawlingSession"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +145,6 @@ public class CrawlingSessionDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +159,27 @@ public class CrawlingSessionDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.CrawlingSession"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.CrawlingSessionCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.CrawlingSessionBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return CrawlingSession.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new CrawlingSession(); } @Override @@ -138,12 +206,6 @@ public class CrawlingSessionDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/CrawlingSessionInfoDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/CrawlingSessionInfoDbm.java index 41ef889b3..31e5456c6 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/CrawlingSessionInfoDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/CrawlingSessionInfoDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.CrawlingSessionInfo; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class CrawlingSessionInfoDbm extends AbstractDBMeta { @@ -24,6 +27,101 @@ public class CrawlingSessionInfoDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((CrawlingSessionInfo) et).getCrawlingSessionId(), + (et, vl) -> ((CrawlingSessionInfo) et).setCrawlingSessionId(DfTypeUtil.toString(vl)), "crawlingSessionId"); + setupEpg(_epgMap, et -> ((CrawlingSessionInfo) et).getCreatedTime(), + (et, vl) -> ((CrawlingSessionInfo) et).setCreatedTime(DfTypeUtil.toLong(vl)), "createdTime"); + setupEpg(_epgMap, et -> ((CrawlingSessionInfo) et).getId(), (et, vl) -> ((CrawlingSessionInfo) et).setId(DfTypeUtil.toString(vl)), + "id"); + setupEpg(_epgMap, et -> ((CrawlingSessionInfo) et).getKey(), + (et, vl) -> ((CrawlingSessionInfo) et).setKey(DfTypeUtil.toString(vl)), "key"); + setupEpg(_epgMap, et -> ((CrawlingSessionInfo) et).getValue(), + (et, vl) -> ((CrawlingSessionInfo) et).setValue(DfTypeUtil.toString(vl)), "value"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCrawlingSessionId = cci("crawlingSessionId", "crawlingSessionId", null, null, String.class, + "crawlingSessionId", null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnKey = cci("key", "key", null, null, String.class, "key", null, false, false, false, "String", 0, 0, + null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnValue = cci("value", "value", null, null, String.class, "value", null, false, false, false, "String", + 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCrawlingSessionId() { + return _columnCrawlingSessionId; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnKey() { + return _columnKey; + } + + public ColumnInfo columnValue() { + return _columnValue; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCrawlingSessionId()); + ls.add(columnCreatedTime()); + ls.add(columnId()); + ls.add(columnKey()); + ls.add(columnValue()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "crawling_session_info"; + protected final String _tableDispName = "crawling_session_info"; + protected final String _tablePropertyName = "CrawlingSessionInfo"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +146,6 @@ public class CrawlingSessionInfoDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +160,27 @@ public class CrawlingSessionInfoDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.CrawlingSessionInfo"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.CrawlingSessionInfoCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.CrawlingSessionInfoBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return CrawlingSessionInfo.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new CrawlingSessionInfo(); } @Override @@ -138,12 +207,6 @@ public class CrawlingSessionInfoDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigDbm.java index 0ca9d89f9..d72fda9ad 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.DataConfig; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class DataConfigDbm extends AbstractDBMeta { @@ -24,6 +27,161 @@ public class DataConfigDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((DataConfig) et).getAvailable(), (et, vl) -> ((DataConfig) et).setAvailable(DfTypeUtil.toBoolean(vl)), + "available"); + setupEpg(_epgMap, et -> ((DataConfig) et).getBoost(), (et, vl) -> ((DataConfig) et).setBoost(DfTypeUtil.toFloat(vl)), "boost"); + setupEpg(_epgMap, et -> ((DataConfig) et).getCreatedBy(), (et, vl) -> ((DataConfig) et).setCreatedBy(DfTypeUtil.toString(vl)), + "createdBy"); + setupEpg(_epgMap, et -> ((DataConfig) et).getCreatedTime(), (et, vl) -> ((DataConfig) et).setCreatedTime(DfTypeUtil.toLong(vl)), + "createdTime"); + setupEpg(_epgMap, et -> ((DataConfig) et).getHandlerName(), (et, vl) -> ((DataConfig) et).setHandlerName(DfTypeUtil.toString(vl)), + "handlerName"); + setupEpg(_epgMap, et -> ((DataConfig) et).getHandlerParameter(), + (et, vl) -> ((DataConfig) et).setHandlerParameter(DfTypeUtil.toString(vl)), "handlerParameter"); + setupEpg(_epgMap, et -> ((DataConfig) et).getHandlerScript(), + (et, vl) -> ((DataConfig) et).setHandlerScript(DfTypeUtil.toString(vl)), "handlerScript"); + setupEpg(_epgMap, et -> ((DataConfig) et).getId(), (et, vl) -> ((DataConfig) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((DataConfig) et).getName(), (et, vl) -> ((DataConfig) et).setName(DfTypeUtil.toString(vl)), "name"); + setupEpg(_epgMap, et -> ((DataConfig) et).getSortOrder(), (et, vl) -> ((DataConfig) et).setSortOrder(DfTypeUtil.toInteger(vl)), + "sortOrder"); + setupEpg(_epgMap, et -> ((DataConfig) et).getUpdatedBy(), (et, vl) -> ((DataConfig) et).setUpdatedBy(DfTypeUtil.toString(vl)), + "updatedBy"); + setupEpg(_epgMap, et -> ((DataConfig) et).getUpdatedTime(), (et, vl) -> ((DataConfig) et).setUpdatedTime(DfTypeUtil.toLong(vl)), + "updatedTime"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnAvailable = cci("available", "available", null, null, Boolean.class, "available", null, false, false, + false, "Boolean", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnBoost = cci("boost", "boost", null, null, Float.class, "boost", null, false, false, false, "Float", + 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnHandlerName = cci("handlerName", "handlerName", null, null, String.class, "handlerName", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnHandlerParameter = cci("handlerParameter", "handlerParameter", null, null, String.class, + "handlerParameter", null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnHandlerScript = cci("handlerScript", "handlerScript", null, null, String.class, "handlerScript", + null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSortOrder = cci("sortOrder", "sortOrder", null, null, Integer.class, "sortOrder", null, false, false, + false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnAvailable() { + return _columnAvailable; + } + + public ColumnInfo columnBoost() { + return _columnBoost; + } + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnHandlerName() { + return _columnHandlerName; + } + + public ColumnInfo columnHandlerParameter() { + return _columnHandlerParameter; + } + + public ColumnInfo columnHandlerScript() { + return _columnHandlerScript; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnName() { + return _columnName; + } + + public ColumnInfo columnSortOrder() { + return _columnSortOrder; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnAvailable()); + ls.add(columnBoost()); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnHandlerName()); + ls.add(columnHandlerParameter()); + ls.add(columnHandlerScript()); + ls.add(columnId()); + ls.add(columnName()); + ls.add(columnSortOrder()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "data_config"; + protected final String _tableDispName = "data_config"; + protected final String _tablePropertyName = "DataConfig"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +206,6 @@ public class DataConfigDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +220,27 @@ public class DataConfigDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.DataConfig"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.DataConfigCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.DataConfigBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return DataConfig.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new DataConfig(); } @Override @@ -138,12 +267,6 @@ public class DataConfigDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigToLabelDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigToLabelDbm.java index 33fb87d92..f88e01a54 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigToLabelDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigToLabelDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.DataConfigToLabel; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class DataConfigToLabelDbm extends AbstractDBMeta { @@ -24,6 +27,82 @@ public class DataConfigToLabelDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((DataConfigToLabel) et).getDataConfigId(), + (et, vl) -> ((DataConfigToLabel) et).setDataConfigId(DfTypeUtil.toString(vl)), "dataConfigId"); + setupEpg(_epgMap, et -> ((DataConfigToLabel) et).getId(), (et, vl) -> ((DataConfigToLabel) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((DataConfigToLabel) et).getLabelTypeId(), + (et, vl) -> ((DataConfigToLabel) et).setLabelTypeId(DfTypeUtil.toString(vl)), "labelTypeId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnDataConfigId = cci("dataConfigId", "dataConfigId", null, null, String.class, "dataConfigId", null, + false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnLabelTypeId = cci("labelTypeId", "labelTypeId", null, null, String.class, "labelTypeId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnDataConfigId() { + return _columnDataConfigId; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnLabelTypeId() { + return _columnLabelTypeId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnDataConfigId()); + ls.add(columnId()); + ls.add(columnLabelTypeId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "data_config_to_label"; + protected final String _tableDispName = "data_config_to_label"; + protected final String _tablePropertyName = "DataConfigToLabel"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +127,6 @@ public class DataConfigToLabelDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +141,27 @@ public class DataConfigToLabelDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.DataConfigToLabel"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.DataConfigToLabelCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.DataConfigToLabelBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return DataConfigToLabel.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new DataConfigToLabel(); } @Override @@ -138,12 +188,6 @@ public class DataConfigToLabelDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigToRoleDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigToRoleDbm.java index ad6ff3176..7294a5c5a 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigToRoleDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/DataConfigToRoleDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.DataConfigToRole; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class DataConfigToRoleDbm extends AbstractDBMeta { @@ -24,6 +27,82 @@ public class DataConfigToRoleDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((DataConfigToRole) et).getDataConfigId(), + (et, vl) -> ((DataConfigToRole) et).setDataConfigId(DfTypeUtil.toString(vl)), "dataConfigId"); + setupEpg(_epgMap, et -> ((DataConfigToRole) et).getId(), (et, vl) -> ((DataConfigToRole) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((DataConfigToRole) et).getRoleTypeId(), + (et, vl) -> ((DataConfigToRole) et).setRoleTypeId(DfTypeUtil.toString(vl)), "roleTypeId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnDataConfigId = cci("dataConfigId", "dataConfigId", null, null, String.class, "dataConfigId", null, + false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnRoleTypeId = cci("roleTypeId", "roleTypeId", null, null, String.class, "roleTypeId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnDataConfigId() { + return _columnDataConfigId; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnRoleTypeId() { + return _columnRoleTypeId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnDataConfigId()); + ls.add(columnId()); + ls.add(columnRoleTypeId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "data_config_to_role"; + protected final String _tableDispName = "data_config_to_role"; + protected final String _tablePropertyName = "DataConfigToRole"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +127,6 @@ public class DataConfigToRoleDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +141,27 @@ public class DataConfigToRoleDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.DataConfigToRole"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.DataConfigToRoleCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.DataConfigToRoleBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return DataConfigToRole.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new DataConfigToRole(); } @Override @@ -138,12 +188,6 @@ public class DataConfigToRoleDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/EventLogDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/EventLogDbm.java new file mode 100644 index 000000000..0523fff4e --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/EventLogDbm.java @@ -0,0 +1,223 @@ +package org.codelibs.fess.es.bsentity.dbmeta; + +import java.time.LocalDateTime; +import java.util.List; +import java.util.Map; + +import org.codelibs.fess.es.exentity.EventLog; +import org.dbflute.Entity; +import org.dbflute.dbmeta.AbstractDBMeta; +import org.dbflute.dbmeta.info.ColumnInfo; +import org.dbflute.dbmeta.info.UniqueInfo; +import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; +import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; + +public class EventLogDbm extends AbstractDBMeta { + + // =================================================================================== + // Singleton + // ========= + private static final EventLogDbm _instance = new EventLogDbm(); + + private EventLogDbm() { + } + + public static EventLogDbm getInstance() { + return _instance; + } + + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((EventLog) et).getCreatedAt(), (et, vl) -> ((EventLog) et).setCreatedAt(DfTypeUtil.toLocalDateTime(vl)), + "createdAt"); + setupEpg(_epgMap, et -> ((EventLog) et).getCreatedBy(), (et, vl) -> ((EventLog) et).setCreatedBy(DfTypeUtil.toString(vl)), + "createdBy"); + setupEpg(_epgMap, et -> ((EventLog) et).getEventType(), (et, vl) -> ((EventLog) et).setEventType(DfTypeUtil.toString(vl)), + "eventType"); + setupEpg(_epgMap, et -> ((EventLog) et).getId(), (et, vl) -> ((EventLog) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((EventLog) et).getMessage(), (et, vl) -> ((EventLog) et).setMessage(DfTypeUtil.toString(vl)), "message"); + setupEpg(_epgMap, et -> ((EventLog) et).getPath(), (et, vl) -> ((EventLog) et).setPath(DfTypeUtil.toString(vl)), "path"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCreatedAt = cci("createdAt", "createdAt", null, null, LocalDateTime.class, "createdAt", null, false, + false, false, "LocalDateTime", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnEventType = cci("eventType", "eventType", null, null, String.class, "eventType", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnMessage = cci("message", "message", null, null, String.class, "message", null, false, false, false, + "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnPath = cci("path", "path", null, null, String.class, "path", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCreatedAt() { + return _columnCreatedAt; + } + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnEventType() { + return _columnEventType; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnMessage() { + return _columnMessage; + } + + public ColumnInfo columnPath() { + return _columnPath; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCreatedAt()); + ls.add(columnCreatedBy()); + ls.add(columnEventType()); + ls.add(columnId()); + ls.add(columnMessage()); + ls.add(columnPath()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "event_log"; + protected final String _tableDispName = "event_log"; + protected final String _tablePropertyName = "EventLog"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + + @Override + public String getProjectName() { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getProjectPrefix() { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getGenerationGapBasePrefix() { + // TODO Auto-generated method stub + return null; + } + + @Override + public DBDef getCurrentDBDef() { + // TODO Auto-generated method stub + return null; + } + + @Override + public boolean hasPrimaryKey() { + // TODO Auto-generated method stub + return false; + } + + @Override + public boolean hasCompoundPrimaryKey() { + // TODO Auto-generated method stub + return false; + } + + @Override + public String getEntityTypeName() { + return "org.codelibs.fess.es.exentity.EventLog"; + } + + @Override + public String getConditionBeanTypeName() { + return "org.codelibs.fess.es.cbean.EventLogCB"; + } + + @Override + public String getBehaviorTypeName() { + return "org.codelibs.fess.es.exbhv.EventLogBhv"; + } + + @Override + public Class getEntityType() { + return EventLog.class; + } + + @Override + public Entity newEntity() { + return new EventLog(); + } + + @Override + public void acceptPrimaryKeyMap(Entity entity, Map primaryKeyMap) { + // TODO Auto-generated method stub + + } + + @Override + public void acceptAllColumnMap(Entity entity, Map allColumnMap) { + // TODO Auto-generated method stub + + } + + @Override + public Map extractPrimaryKeyMap(Entity entity) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Map extractAllColumnMap(Entity entity) { + // TODO Auto-generated method stub + return null; + } + + @Override + protected UniqueInfo cpui() { + // TODO Auto-generated method stub + return null; + } + +} diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FailureUrlDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FailureUrlDbm.java index 39f63804e..663a30843 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FailureUrlDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FailureUrlDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.FailureUrl; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class FailureUrlDbm extends AbstractDBMeta { @@ -24,6 +27,126 @@ public class FailureUrlDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((FailureUrl) et).getConfigId(), (et, vl) -> ((FailureUrl) et).setConfigId(DfTypeUtil.toString(vl)), + "configId"); + setupEpg(_epgMap, et -> ((FailureUrl) et).getErrorCount(), (et, vl) -> ((FailureUrl) et).setErrorCount(DfTypeUtil.toInteger(vl)), + "errorCount"); + setupEpg(_epgMap, et -> ((FailureUrl) et).getErrorLog(), (et, vl) -> ((FailureUrl) et).setErrorLog(DfTypeUtil.toString(vl)), + "errorLog"); + setupEpg(_epgMap, et -> ((FailureUrl) et).getErrorName(), (et, vl) -> ((FailureUrl) et).setErrorName(DfTypeUtil.toString(vl)), + "errorName"); + setupEpg(_epgMap, et -> ((FailureUrl) et).getId(), (et, vl) -> ((FailureUrl) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((FailureUrl) et).getLastAccessTime(), + (et, vl) -> ((FailureUrl) et).setLastAccessTime(DfTypeUtil.toLong(vl)), "lastAccessTime"); + setupEpg(_epgMap, et -> ((FailureUrl) et).getThreadName(), (et, vl) -> ((FailureUrl) et).setThreadName(DfTypeUtil.toString(vl)), + "threadName"); + setupEpg(_epgMap, et -> ((FailureUrl) et).getUrl(), (et, vl) -> ((FailureUrl) et).setUrl(DfTypeUtil.toString(vl)), "url"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnConfigId = cci("configId", "configId", null, null, String.class, "configId", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnErrorCount = cci("errorCount", "errorCount", null, null, Integer.class, "errorCount", null, false, + false, false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnErrorLog = cci("errorLog", "errorLog", null, null, String.class, "errorLog", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnErrorName = cci("errorName", "errorName", null, null, String.class, "errorName", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnLastAccessTime = cci("lastAccessTime", "lastAccessTime", null, null, Long.class, "lastAccessTime", + null, false, false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnThreadName = cci("threadName", "threadName", null, null, String.class, "threadName", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUrl = cci("url", "url", null, null, String.class, "url", null, false, false, false, "String", 0, 0, + null, false, null, null, null, null, null, false); + + public ColumnInfo columnConfigId() { + return _columnConfigId; + } + + public ColumnInfo columnErrorCount() { + return _columnErrorCount; + } + + public ColumnInfo columnErrorLog() { + return _columnErrorLog; + } + + public ColumnInfo columnErrorName() { + return _columnErrorName; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnLastAccessTime() { + return _columnLastAccessTime; + } + + public ColumnInfo columnThreadName() { + return _columnThreadName; + } + + public ColumnInfo columnUrl() { + return _columnUrl; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnConfigId()); + ls.add(columnErrorCount()); + ls.add(columnErrorLog()); + ls.add(columnErrorName()); + ls.add(columnId()); + ls.add(columnLastAccessTime()); + ls.add(columnThreadName()); + ls.add(columnUrl()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "failure_url"; + protected final String _tableDispName = "failure_url"; + protected final String _tablePropertyName = "FailureUrl"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +171,6 @@ public class FailureUrlDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +185,27 @@ public class FailureUrlDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.FailureUrl"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.FailureUrlCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.FailureUrlBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return FailureUrl.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new FailureUrl(); } @Override @@ -138,12 +232,6 @@ public class FailureUrlDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FavoriteLogDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FavoriteLogDbm.java index 681b97d54..112ae94dc 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FavoriteLogDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FavoriteLogDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.FavoriteLog; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class FavoriteLogDbm extends AbstractDBMeta { @@ -24,6 +27,90 @@ public class FavoriteLogDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((FavoriteLog) et).getCreatedTime(), (et, vl) -> ((FavoriteLog) et).setCreatedTime(DfTypeUtil.toLong(vl)), + "createdTime"); + setupEpg(_epgMap, et -> ((FavoriteLog) et).getId(), (et, vl) -> ((FavoriteLog) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((FavoriteLog) et).getUrl(), (et, vl) -> ((FavoriteLog) et).setUrl(DfTypeUtil.toString(vl)), "url"); + setupEpg(_epgMap, et -> ((FavoriteLog) et).getUserInfoId(), (et, vl) -> ((FavoriteLog) et).setUserInfoId(DfTypeUtil.toString(vl)), + "userInfoId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnUrl = cci("url", "url", null, null, String.class, "url", null, false, false, false, "String", 0, 0, + null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUserInfoId = cci("userInfoId", "userInfoId", null, null, String.class, "userInfoId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnUrl() { + return _columnUrl; + } + + public ColumnInfo columnUserInfoId() { + return _columnUserInfoId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCreatedTime()); + ls.add(columnId()); + ls.add(columnUrl()); + ls.add(columnUserInfoId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "favorite_log"; + protected final String _tableDispName = "favorite_log"; + protected final String _tablePropertyName = "FavoriteLog"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +135,6 @@ public class FavoriteLogDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +149,27 @@ public class FavoriteLogDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.FavoriteLog"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.FavoriteLogCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.FavoriteLogBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return FavoriteLog.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new FavoriteLog(); } @Override @@ -138,12 +196,6 @@ public class FavoriteLogDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileAuthenticationDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileAuthenticationDbm.java index b0445d2eb..ff2187f79 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileAuthenticationDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileAuthenticationDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.FileAuthentication; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class FileAuthenticationDbm extends AbstractDBMeta { @@ -24,6 +27,164 @@ public class FileAuthenticationDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((FileAuthentication) et).getCreatedBy(), + (et, vl) -> ((FileAuthentication) et).setCreatedBy(DfTypeUtil.toString(vl)), "createdBy"); + setupEpg(_epgMap, et -> ((FileAuthentication) et).getCreatedTime(), + (et, vl) -> ((FileAuthentication) et).setCreatedTime(DfTypeUtil.toLong(vl)), "createdTime"); + setupEpg(_epgMap, et -> ((FileAuthentication) et).getFileConfigId(), + (et, vl) -> ((FileAuthentication) et).setFileConfigId(DfTypeUtil.toString(vl)), "fileConfigId"); + setupEpg(_epgMap, et -> ((FileAuthentication) et).getHostname(), + (et, vl) -> ((FileAuthentication) et).setHostname(DfTypeUtil.toString(vl)), "hostname"); + setupEpg(_epgMap, et -> ((FileAuthentication) et).getId(), (et, vl) -> ((FileAuthentication) et).setId(DfTypeUtil.toString(vl)), + "id"); + setupEpg(_epgMap, et -> ((FileAuthentication) et).getParameters(), + (et, vl) -> ((FileAuthentication) et).setParameters(DfTypeUtil.toString(vl)), "parameters"); + setupEpg(_epgMap, et -> ((FileAuthentication) et).getPassword(), + (et, vl) -> ((FileAuthentication) et).setPassword(DfTypeUtil.toString(vl)), "password"); + setupEpg(_epgMap, et -> ((FileAuthentication) et).getPort(), + (et, vl) -> ((FileAuthentication) et).setPort(DfTypeUtil.toInteger(vl)), "port"); + setupEpg(_epgMap, et -> ((FileAuthentication) et).getProtocolScheme(), + (et, vl) -> ((FileAuthentication) et).setProtocolScheme(DfTypeUtil.toString(vl)), "protocolScheme"); + setupEpg(_epgMap, et -> ((FileAuthentication) et).getUpdatedBy(), + (et, vl) -> ((FileAuthentication) et).setUpdatedBy(DfTypeUtil.toString(vl)), "updatedBy"); + setupEpg(_epgMap, et -> ((FileAuthentication) et).getUpdatedTime(), + (et, vl) -> ((FileAuthentication) et).setUpdatedTime(DfTypeUtil.toLong(vl)), "updatedTime"); + setupEpg(_epgMap, et -> ((FileAuthentication) et).getUsername(), + (et, vl) -> ((FileAuthentication) et).setUsername(DfTypeUtil.toString(vl)), "username"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnFileConfigId = cci("fileConfigId", "fileConfigId", null, null, String.class, "fileConfigId", null, + false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnHostname = cci("hostname", "hostname", null, null, String.class, "hostname", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnParameters = cci("parameters", "parameters", null, null, String.class, "parameters", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnPassword = cci("password", "password", null, null, String.class, "password", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnPort = cci("port", "port", null, null, Integer.class, "port", null, false, false, false, "Integer", + 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnProtocolScheme = cci("protocolScheme", "protocolScheme", null, null, String.class, "protocolScheme", + null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUsername = cci("username", "username", null, null, String.class, "username", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnFileConfigId() { + return _columnFileConfigId; + } + + public ColumnInfo columnHostname() { + return _columnHostname; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnParameters() { + return _columnParameters; + } + + public ColumnInfo columnPassword() { + return _columnPassword; + } + + public ColumnInfo columnPort() { + return _columnPort; + } + + public ColumnInfo columnProtocolScheme() { + return _columnProtocolScheme; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + public ColumnInfo columnUsername() { + return _columnUsername; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnFileConfigId()); + ls.add(columnHostname()); + ls.add(columnId()); + ls.add(columnParameters()); + ls.add(columnPassword()); + ls.add(columnPort()); + ls.add(columnProtocolScheme()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + ls.add(columnUsername()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "file_authentication"; + protected final String _tableDispName = "file_authentication"; + protected final String _tablePropertyName = "FileAuthentication"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +209,6 @@ public class FileAuthenticationDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +223,27 @@ public class FileAuthenticationDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.FileAuthentication"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.FileAuthenticationCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.FileAuthenticationBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return FileAuthentication.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new FileAuthentication(); } @Override @@ -138,12 +270,6 @@ public class FileAuthenticationDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigDbm.java index 20b07b4f1..ca569f244 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.FileConfig; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class FileConfigDbm extends AbstractDBMeta { @@ -24,6 +27,222 @@ public class FileConfigDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((FileConfig) et).getAvailable(), (et, vl) -> ((FileConfig) et).setAvailable(DfTypeUtil.toBoolean(vl)), + "available"); + setupEpg(_epgMap, et -> ((FileConfig) et).getBoost(), (et, vl) -> ((FileConfig) et).setBoost(DfTypeUtil.toFloat(vl)), "boost"); + setupEpg(_epgMap, et -> ((FileConfig) et).getConfigParameter(), + (et, vl) -> ((FileConfig) et).setConfigParameter(DfTypeUtil.toString(vl)), "configParameter"); + setupEpg(_epgMap, et -> ((FileConfig) et).getCreatedBy(), (et, vl) -> ((FileConfig) et).setCreatedBy(DfTypeUtil.toString(vl)), + "createdBy"); + setupEpg(_epgMap, et -> ((FileConfig) et).getCreatedTime(), (et, vl) -> ((FileConfig) et).setCreatedTime(DfTypeUtil.toLong(vl)), + "createdTime"); + setupEpg(_epgMap, et -> ((FileConfig) et).getDepth(), (et, vl) -> ((FileConfig) et).setDepth(DfTypeUtil.toInteger(vl)), "depth"); + setupEpg(_epgMap, et -> ((FileConfig) et).getExcludedDocPaths(), + (et, vl) -> ((FileConfig) et).setExcludedDocPaths(DfTypeUtil.toString(vl)), "excludedDocPaths"); + setupEpg(_epgMap, et -> ((FileConfig) et).getExcludedPaths(), + (et, vl) -> ((FileConfig) et).setExcludedPaths(DfTypeUtil.toString(vl)), "excludedPaths"); + setupEpg(_epgMap, et -> ((FileConfig) et).getId(), (et, vl) -> ((FileConfig) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((FileConfig) et).getIncludedDocPaths(), + (et, vl) -> ((FileConfig) et).setIncludedDocPaths(DfTypeUtil.toString(vl)), "includedDocPaths"); + setupEpg(_epgMap, et -> ((FileConfig) et).getIncludedPaths(), + (et, vl) -> ((FileConfig) et).setIncludedPaths(DfTypeUtil.toString(vl)), "includedPaths"); + setupEpg(_epgMap, et -> ((FileConfig) et).getIntervalTime(), + (et, vl) -> ((FileConfig) et).setIntervalTime(DfTypeUtil.toInteger(vl)), "intervalTime"); + setupEpg(_epgMap, et -> ((FileConfig) et).getMaxAccessCount(), + (et, vl) -> ((FileConfig) et).setMaxAccessCount(DfTypeUtil.toLong(vl)), "maxAccessCount"); + setupEpg(_epgMap, et -> ((FileConfig) et).getName(), (et, vl) -> ((FileConfig) et).setName(DfTypeUtil.toString(vl)), "name"); + setupEpg(_epgMap, et -> ((FileConfig) et).getNumOfThread(), (et, vl) -> ((FileConfig) et).setNumOfThread(DfTypeUtil.toInteger(vl)), + "numOfThread"); + setupEpg(_epgMap, et -> ((FileConfig) et).getPaths(), (et, vl) -> ((FileConfig) et).setPaths(DfTypeUtil.toString(vl)), "paths"); + setupEpg(_epgMap, et -> ((FileConfig) et).getSortOrder(), (et, vl) -> ((FileConfig) et).setSortOrder(DfTypeUtil.toInteger(vl)), + "sortOrder"); + setupEpg(_epgMap, et -> ((FileConfig) et).getUpdatedBy(), (et, vl) -> ((FileConfig) et).setUpdatedBy(DfTypeUtil.toString(vl)), + "updatedBy"); + setupEpg(_epgMap, et -> ((FileConfig) et).getUpdatedTime(), (et, vl) -> ((FileConfig) et).setUpdatedTime(DfTypeUtil.toLong(vl)), + "updatedTime"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnAvailable = cci("available", "available", null, null, Boolean.class, "available", null, false, false, + false, "Boolean", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnBoost = cci("boost", "boost", null, null, Float.class, "boost", null, false, false, false, "Float", + 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnConfigParameter = cci("configParameter", "configParameter", null, null, String.class, + "configParameter", null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnDepth = cci("depth", "depth", null, null, Integer.class, "depth", null, false, false, false, + "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnExcludedDocPaths = cci("excludedDocPaths", "excludedDocPaths", null, null, String.class, + "excludedDocPaths", null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnExcludedPaths = cci("excludedPaths", "excludedPaths", null, null, String.class, "excludedPaths", + null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnIncludedDocPaths = cci("includedDocPaths", "includedDocPaths", null, null, String.class, + "includedDocPaths", null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnIncludedPaths = cci("includedPaths", "includedPaths", null, null, String.class, "includedPaths", + null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnIntervalTime = cci("intervalTime", "intervalTime", null, null, Integer.class, "intervalTime", null, + false, false, false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnMaxAccessCount = cci("maxAccessCount", "maxAccessCount", null, null, Long.class, "maxAccessCount", + null, false, false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnNumOfThread = cci("numOfThread", "numOfThread", null, null, Integer.class, "numOfThread", null, + false, false, false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnPaths = cci("paths", "paths", null, null, String.class, "paths", null, false, false, false, "String", + 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSortOrder = cci("sortOrder", "sortOrder", null, null, Integer.class, "sortOrder", null, false, false, + false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnAvailable() { + return _columnAvailable; + } + + public ColumnInfo columnBoost() { + return _columnBoost; + } + + public ColumnInfo columnConfigParameter() { + return _columnConfigParameter; + } + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnDepth() { + return _columnDepth; + } + + public ColumnInfo columnExcludedDocPaths() { + return _columnExcludedDocPaths; + } + + public ColumnInfo columnExcludedPaths() { + return _columnExcludedPaths; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnIncludedDocPaths() { + return _columnIncludedDocPaths; + } + + public ColumnInfo columnIncludedPaths() { + return _columnIncludedPaths; + } + + public ColumnInfo columnIntervalTime() { + return _columnIntervalTime; + } + + public ColumnInfo columnMaxAccessCount() { + return _columnMaxAccessCount; + } + + public ColumnInfo columnName() { + return _columnName; + } + + public ColumnInfo columnNumOfThread() { + return _columnNumOfThread; + } + + public ColumnInfo columnPaths() { + return _columnPaths; + } + + public ColumnInfo columnSortOrder() { + return _columnSortOrder; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnAvailable()); + ls.add(columnBoost()); + ls.add(columnConfigParameter()); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnDepth()); + ls.add(columnExcludedDocPaths()); + ls.add(columnExcludedPaths()); + ls.add(columnId()); + ls.add(columnIncludedDocPaths()); + ls.add(columnIncludedPaths()); + ls.add(columnIntervalTime()); + ls.add(columnMaxAccessCount()); + ls.add(columnName()); + ls.add(columnNumOfThread()); + ls.add(columnPaths()); + ls.add(columnSortOrder()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "file_config"; + protected final String _tableDispName = "file_config"; + protected final String _tablePropertyName = "FileConfig"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +267,6 @@ public class FileConfigDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +281,27 @@ public class FileConfigDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.FileConfig"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.FileConfigCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.FileConfigBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return FileConfig.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new FileConfig(); } @Override @@ -138,12 +328,6 @@ public class FileConfigDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigToLabelDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigToLabelDbm.java index ebd471724..5efe70c83 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigToLabelDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigToLabelDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.FileConfigToLabel; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class FileConfigToLabelDbm extends AbstractDBMeta { @@ -24,6 +27,82 @@ public class FileConfigToLabelDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((FileConfigToLabel) et).getFileConfigId(), + (et, vl) -> ((FileConfigToLabel) et).setFileConfigId(DfTypeUtil.toString(vl)), "fileConfigId"); + setupEpg(_epgMap, et -> ((FileConfigToLabel) et).getId(), (et, vl) -> ((FileConfigToLabel) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((FileConfigToLabel) et).getLabelTypeId(), + (et, vl) -> ((FileConfigToLabel) et).setLabelTypeId(DfTypeUtil.toString(vl)), "labelTypeId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnFileConfigId = cci("fileConfigId", "fileConfigId", null, null, String.class, "fileConfigId", null, + false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnLabelTypeId = cci("labelTypeId", "labelTypeId", null, null, String.class, "labelTypeId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnFileConfigId() { + return _columnFileConfigId; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnLabelTypeId() { + return _columnLabelTypeId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnFileConfigId()); + ls.add(columnId()); + ls.add(columnLabelTypeId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "file_config_to_label"; + protected final String _tableDispName = "file_config_to_label"; + protected final String _tablePropertyName = "FileConfigToLabel"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +127,6 @@ public class FileConfigToLabelDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +141,27 @@ public class FileConfigToLabelDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.FileConfigToLabel"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.FileConfigToLabelCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.FileConfigToLabelBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return FileConfigToLabel.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new FileConfigToLabel(); } @Override @@ -138,12 +188,6 @@ public class FileConfigToLabelDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigToRoleDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigToRoleDbm.java index e4f8cfc09..134636802 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigToRoleDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/FileConfigToRoleDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.FileConfigToRole; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class FileConfigToRoleDbm extends AbstractDBMeta { @@ -24,6 +27,82 @@ public class FileConfigToRoleDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((FileConfigToRole) et).getFileConfigId(), + (et, vl) -> ((FileConfigToRole) et).setFileConfigId(DfTypeUtil.toString(vl)), "fileConfigId"); + setupEpg(_epgMap, et -> ((FileConfigToRole) et).getId(), (et, vl) -> ((FileConfigToRole) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((FileConfigToRole) et).getRoleTypeId(), + (et, vl) -> ((FileConfigToRole) et).setRoleTypeId(DfTypeUtil.toString(vl)), "roleTypeId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnFileConfigId = cci("fileConfigId", "fileConfigId", null, null, String.class, "fileConfigId", null, + false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnRoleTypeId = cci("roleTypeId", "roleTypeId", null, null, String.class, "roleTypeId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnFileConfigId() { + return _columnFileConfigId; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnRoleTypeId() { + return _columnRoleTypeId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnFileConfigId()); + ls.add(columnId()); + ls.add(columnRoleTypeId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "file_config_to_role"; + protected final String _tableDispName = "file_config_to_role"; + protected final String _tablePropertyName = "FileConfigToRole"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +127,6 @@ public class FileConfigToRoleDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +141,27 @@ public class FileConfigToRoleDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.FileConfigToRole"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.FileConfigToRoleCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.FileConfigToRoleBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return FileConfigToRole.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new FileConfigToRole(); } @Override @@ -138,12 +188,6 @@ public class FileConfigToRoleDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/GroupDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/GroupDbm.java new file mode 100644 index 000000000..aa4bfefe3 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/GroupDbm.java @@ -0,0 +1,187 @@ +package org.codelibs.fess.es.bsentity.dbmeta; + +import java.util.List; +import java.util.Map; + +import org.codelibs.fess.es.exentity.Group; +import org.dbflute.Entity; +import org.dbflute.dbmeta.AbstractDBMeta; +import org.dbflute.dbmeta.info.ColumnInfo; +import org.dbflute.dbmeta.info.UniqueInfo; +import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; +import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; + +public class GroupDbm extends AbstractDBMeta { + + // =================================================================================== + // Singleton + // ========= + private static final GroupDbm _instance = new GroupDbm(); + + private GroupDbm() { + } + + public static GroupDbm getInstance() { + return _instance; + } + + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((Group) et).getId(), (et, vl) -> ((Group) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((Group) et).getName(), (et, vl) -> ((Group) et).setName(DfTypeUtil.toString(vl)), "name"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnName() { + return _columnName; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnId()); + ls.add(columnName()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "group"; + protected final String _tableDispName = "group"; + protected final String _tablePropertyName = "Group"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + + @Override + public String getProjectName() { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getProjectPrefix() { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getGenerationGapBasePrefix() { + // TODO Auto-generated method stub + return null; + } + + @Override + public DBDef getCurrentDBDef() { + // TODO Auto-generated method stub + return null; + } + + @Override + public boolean hasPrimaryKey() { + // TODO Auto-generated method stub + return false; + } + + @Override + public boolean hasCompoundPrimaryKey() { + // TODO Auto-generated method stub + return false; + } + + @Override + public String getEntityTypeName() { + return "org.codelibs.fess.es.exentity.Group"; + } + + @Override + public String getConditionBeanTypeName() { + return "org.codelibs.fess.es.cbean.GroupCB"; + } + + @Override + public String getBehaviorTypeName() { + return "org.codelibs.fess.es.exbhv.GroupBhv"; + } + + @Override + public Class getEntityType() { + return Group.class; + } + + @Override + public Entity newEntity() { + return new Group(); + } + + @Override + public void acceptPrimaryKeyMap(Entity entity, Map primaryKeyMap) { + // TODO Auto-generated method stub + + } + + @Override + public void acceptAllColumnMap(Entity entity, Map allColumnMap) { + // TODO Auto-generated method stub + + } + + @Override + public Map extractPrimaryKeyMap(Entity entity) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Map extractAllColumnMap(Entity entity) { + // TODO Auto-generated method stub + return null; + } + + @Override + protected UniqueInfo cpui() { + // TODO Auto-generated method stub + return null; + } + +} diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/JobLogDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/JobLogDbm.java index 48bcb520f..1ebda142f 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/JobLogDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/JobLogDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.JobLog; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class JobLogDbm extends AbstractDBMeta { @@ -24,6 +27,131 @@ public class JobLogDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((JobLog) et).getEndTime(), (et, vl) -> ((JobLog) et).setEndTime(DfTypeUtil.toLong(vl)), "endTime"); + setupEpg(_epgMap, et -> ((JobLog) et).getId(), (et, vl) -> ((JobLog) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((JobLog) et).getJobName(), (et, vl) -> ((JobLog) et).setJobName(DfTypeUtil.toString(vl)), "jobName"); + setupEpg(_epgMap, et -> ((JobLog) et).getJobStatus(), (et, vl) -> ((JobLog) et).setJobStatus(DfTypeUtil.toString(vl)), "jobStatus"); + setupEpg(_epgMap, et -> ((JobLog) et).getScriptData(), (et, vl) -> ((JobLog) et).setScriptData(DfTypeUtil.toString(vl)), + "scriptData"); + setupEpg(_epgMap, et -> ((JobLog) et).getScriptResult(), (et, vl) -> ((JobLog) et).setScriptResult(DfTypeUtil.toString(vl)), + "scriptResult"); + setupEpg(_epgMap, et -> ((JobLog) et).getScriptType(), (et, vl) -> ((JobLog) et).setScriptType(DfTypeUtil.toString(vl)), + "scriptType"); + setupEpg(_epgMap, et -> ((JobLog) et).getStartTime(), (et, vl) -> ((JobLog) et).setStartTime(DfTypeUtil.toLong(vl)), "startTime"); + setupEpg(_epgMap, et -> ((JobLog) et).getTarget(), (et, vl) -> ((JobLog) et).setTarget(DfTypeUtil.toString(vl)), "target"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnEndTime = cci("endTime", "endTime", null, null, Long.class, "endTime", null, false, false, false, + "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnJobName = cci("jobName", "jobName", null, null, String.class, "jobName", null, false, false, false, + "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnJobStatus = cci("jobStatus", "jobStatus", null, null, String.class, "jobStatus", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnScriptData = cci("scriptData", "scriptData", null, null, String.class, "scriptData", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnScriptResult = cci("scriptResult", "scriptResult", null, null, String.class, "scriptResult", null, + false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnScriptType = cci("scriptType", "scriptType", null, null, String.class, "scriptType", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnStartTime = cci("startTime", "startTime", null, null, Long.class, "startTime", null, false, false, + false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnTarget = cci("target", "target", null, null, String.class, "target", null, false, false, false, + "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnEndTime() { + return _columnEndTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnJobName() { + return _columnJobName; + } + + public ColumnInfo columnJobStatus() { + return _columnJobStatus; + } + + public ColumnInfo columnScriptData() { + return _columnScriptData; + } + + public ColumnInfo columnScriptResult() { + return _columnScriptResult; + } + + public ColumnInfo columnScriptType() { + return _columnScriptType; + } + + public ColumnInfo columnStartTime() { + return _columnStartTime; + } + + public ColumnInfo columnTarget() { + return _columnTarget; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnEndTime()); + ls.add(columnId()); + ls.add(columnJobName()); + ls.add(columnJobStatus()); + ls.add(columnScriptData()); + ls.add(columnScriptResult()); + ls.add(columnScriptType()); + ls.add(columnStartTime()); + ls.add(columnTarget()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "job_log"; + protected final String _tableDispName = "job_log"; + protected final String _tablePropertyName = "JobLog"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +176,6 @@ public class JobLogDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +190,27 @@ public class JobLogDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.JobLog"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.JobLogCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.JobLogBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return JobLog.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new JobLog(); } @Override @@ -138,12 +237,6 @@ public class JobLogDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/KeyMatchDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/KeyMatchDbm.java index 9ebb9c4f4..338e3cf58 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/KeyMatchDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/KeyMatchDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.KeyMatch; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class KeyMatchDbm extends AbstractDBMeta { @@ -24,6 +27,132 @@ public class KeyMatchDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((KeyMatch) et).getBoost(), (et, vl) -> ((KeyMatch) et).setBoost(DfTypeUtil.toFloat(vl)), "boost"); + setupEpg(_epgMap, et -> ((KeyMatch) et).getCreatedBy(), (et, vl) -> ((KeyMatch) et).setCreatedBy(DfTypeUtil.toString(vl)), + "createdBy"); + setupEpg(_epgMap, et -> ((KeyMatch) et).getCreatedTime(), (et, vl) -> ((KeyMatch) et).setCreatedTime(DfTypeUtil.toLong(vl)), + "createdTime"); + setupEpg(_epgMap, et -> ((KeyMatch) et).getId(), (et, vl) -> ((KeyMatch) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((KeyMatch) et).getMaxSize(), (et, vl) -> ((KeyMatch) et).setMaxSize(DfTypeUtil.toInteger(vl)), "maxSize"); + setupEpg(_epgMap, et -> ((KeyMatch) et).getQuery(), (et, vl) -> ((KeyMatch) et).setQuery(DfTypeUtil.toString(vl)), "query"); + setupEpg(_epgMap, et -> ((KeyMatch) et).getTerm(), (et, vl) -> ((KeyMatch) et).setTerm(DfTypeUtil.toString(vl)), "term"); + setupEpg(_epgMap, et -> ((KeyMatch) et).getUpdatedBy(), (et, vl) -> ((KeyMatch) et).setUpdatedBy(DfTypeUtil.toString(vl)), + "updatedBy"); + setupEpg(_epgMap, et -> ((KeyMatch) et).getUpdatedTime(), (et, vl) -> ((KeyMatch) et).setUpdatedTime(DfTypeUtil.toLong(vl)), + "updatedTime"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnBoost = cci("boost", "boost", null, null, Float.class, "boost", null, false, false, false, "Float", + 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnMaxSize = cci("maxSize", "maxSize", null, null, Integer.class, "maxSize", null, false, false, false, + "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnQuery = cci("query", "query", null, null, String.class, "query", null, false, false, false, "String", + 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnTerm = cci("term", "term", null, null, String.class, "term", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnBoost() { + return _columnBoost; + } + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnMaxSize() { + return _columnMaxSize; + } + + public ColumnInfo columnQuery() { + return _columnQuery; + } + + public ColumnInfo columnTerm() { + return _columnTerm; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnBoost()); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnId()); + ls.add(columnMaxSize()); + ls.add(columnQuery()); + ls.add(columnTerm()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "key_match"; + protected final String _tableDispName = "key_match"; + protected final String _tablePropertyName = "KeyMatch"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +177,6 @@ public class KeyMatchDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +191,27 @@ public class KeyMatchDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.KeyMatch"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.KeyMatchCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.KeyMatchBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return KeyMatch.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new KeyMatch(); } @Override @@ -138,12 +238,6 @@ public class KeyMatchDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/LabelToRoleDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/LabelToRoleDbm.java index 508b25673..d103d5d15 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/LabelToRoleDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/LabelToRoleDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.LabelToRole; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class LabelToRoleDbm extends AbstractDBMeta { @@ -24,6 +27,82 @@ public class LabelToRoleDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((LabelToRole) et).getId(), (et, vl) -> ((LabelToRole) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((LabelToRole) et).getLabelTypeId(), + (et, vl) -> ((LabelToRole) et).setLabelTypeId(DfTypeUtil.toString(vl)), "labelTypeId"); + setupEpg(_epgMap, et -> ((LabelToRole) et).getRoleTypeId(), (et, vl) -> ((LabelToRole) et).setRoleTypeId(DfTypeUtil.toString(vl)), + "roleTypeId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnLabelTypeId = cci("labelTypeId", "labelTypeId", null, null, String.class, "labelTypeId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnRoleTypeId = cci("roleTypeId", "roleTypeId", null, null, String.class, "roleTypeId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnLabelTypeId() { + return _columnLabelTypeId; + } + + public ColumnInfo columnRoleTypeId() { + return _columnRoleTypeId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnId()); + ls.add(columnLabelTypeId()); + ls.add(columnRoleTypeId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "label_to_role"; + protected final String _tableDispName = "label_to_role"; + protected final String _tablePropertyName = "LabelToRole"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +127,6 @@ public class LabelToRoleDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +141,27 @@ public class LabelToRoleDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.LabelToRole"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.LabelToRoleCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.LabelToRoleBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return LabelToRole.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new LabelToRole(); } @Override @@ -138,12 +188,6 @@ public class LabelToRoleDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/LabelTypeDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/LabelTypeDbm.java index a5408052e..196ac3b78 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/LabelTypeDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/LabelTypeDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.LabelType; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class LabelTypeDbm extends AbstractDBMeta { @@ -24,6 +27,143 @@ public class LabelTypeDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((LabelType) et).getCreatedBy(), (et, vl) -> ((LabelType) et).setCreatedBy(DfTypeUtil.toString(vl)), + "createdBy"); + setupEpg(_epgMap, et -> ((LabelType) et).getCreatedTime(), (et, vl) -> ((LabelType) et).setCreatedTime(DfTypeUtil.toLong(vl)), + "createdTime"); + setupEpg(_epgMap, et -> ((LabelType) et).getExcludedPaths(), + (et, vl) -> ((LabelType) et).setExcludedPaths(DfTypeUtil.toString(vl)), "excludedPaths"); + setupEpg(_epgMap, et -> ((LabelType) et).getId(), (et, vl) -> ((LabelType) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((LabelType) et).getIncludedPaths(), + (et, vl) -> ((LabelType) et).setIncludedPaths(DfTypeUtil.toString(vl)), "includedPaths"); + setupEpg(_epgMap, et -> ((LabelType) et).getName(), (et, vl) -> ((LabelType) et).setName(DfTypeUtil.toString(vl)), "name"); + setupEpg(_epgMap, et -> ((LabelType) et).getSortOrder(), (et, vl) -> ((LabelType) et).setSortOrder(DfTypeUtil.toInteger(vl)), + "sortOrder"); + setupEpg(_epgMap, et -> ((LabelType) et).getUpdatedBy(), (et, vl) -> ((LabelType) et).setUpdatedBy(DfTypeUtil.toString(vl)), + "updatedBy"); + setupEpg(_epgMap, et -> ((LabelType) et).getUpdatedTime(), (et, vl) -> ((LabelType) et).setUpdatedTime(DfTypeUtil.toLong(vl)), + "updatedTime"); + setupEpg(_epgMap, et -> ((LabelType) et).getValue(), (et, vl) -> ((LabelType) et).setValue(DfTypeUtil.toString(vl)), "value"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnExcludedPaths = cci("excludedPaths", "excludedPaths", null, null, String.class, "excludedPaths", + null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnIncludedPaths = cci("includedPaths", "includedPaths", null, null, String.class, "includedPaths", + null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSortOrder = cci("sortOrder", "sortOrder", null, null, Integer.class, "sortOrder", null, false, false, + false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnValue = cci("value", "value", null, null, String.class, "value", null, false, false, false, "String", + 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnExcludedPaths() { + return _columnExcludedPaths; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnIncludedPaths() { + return _columnIncludedPaths; + } + + public ColumnInfo columnName() { + return _columnName; + } + + public ColumnInfo columnSortOrder() { + return _columnSortOrder; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + public ColumnInfo columnValue() { + return _columnValue; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnExcludedPaths()); + ls.add(columnId()); + ls.add(columnIncludedPaths()); + ls.add(columnName()); + ls.add(columnSortOrder()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + ls.add(columnValue()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "label_type"; + protected final String _tableDispName = "label_type"; + protected final String _tablePropertyName = "LabelType"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +188,6 @@ public class LabelTypeDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +202,27 @@ public class LabelTypeDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.LabelType"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.LabelTypeCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.LabelTypeBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return LabelType.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new LabelType(); } @Override @@ -138,12 +249,6 @@ public class LabelTypeDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/OverlappingHostDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/OverlappingHostDbm.java index 441a30d25..b88f42f21 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/OverlappingHostDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/OverlappingHostDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.OverlappingHost; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class OverlappingHostDbm extends AbstractDBMeta { @@ -24,6 +27,127 @@ public class OverlappingHostDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((OverlappingHost) et).getCreatedBy(), + (et, vl) -> ((OverlappingHost) et).setCreatedBy(DfTypeUtil.toString(vl)), "createdBy"); + setupEpg(_epgMap, et -> ((OverlappingHost) et).getCreatedTime(), + (et, vl) -> ((OverlappingHost) et).setCreatedTime(DfTypeUtil.toLong(vl)), "createdTime"); + setupEpg(_epgMap, et -> ((OverlappingHost) et).getId(), (et, vl) -> ((OverlappingHost) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((OverlappingHost) et).getOverlappingName(), + (et, vl) -> ((OverlappingHost) et).setOverlappingName(DfTypeUtil.toString(vl)), "overlappingName"); + setupEpg(_epgMap, et -> ((OverlappingHost) et).getRegularName(), + (et, vl) -> ((OverlappingHost) et).setRegularName(DfTypeUtil.toString(vl)), "regularName"); + setupEpg(_epgMap, et -> ((OverlappingHost) et).getSortOrder(), + (et, vl) -> ((OverlappingHost) et).setSortOrder(DfTypeUtil.toInteger(vl)), "sortOrder"); + setupEpg(_epgMap, et -> ((OverlappingHost) et).getUpdatedBy(), + (et, vl) -> ((OverlappingHost) et).setUpdatedBy(DfTypeUtil.toString(vl)), "updatedBy"); + setupEpg(_epgMap, et -> ((OverlappingHost) et).getUpdatedTime(), + (et, vl) -> ((OverlappingHost) et).setUpdatedTime(DfTypeUtil.toLong(vl)), "updatedTime"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnOverlappingName = cci("overlappingName", "overlappingName", null, null, String.class, + "overlappingName", null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnRegularName = cci("regularName", "regularName", null, null, String.class, "regularName", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSortOrder = cci("sortOrder", "sortOrder", null, null, Integer.class, "sortOrder", null, false, false, + false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnOverlappingName() { + return _columnOverlappingName; + } + + public ColumnInfo columnRegularName() { + return _columnRegularName; + } + + public ColumnInfo columnSortOrder() { + return _columnSortOrder; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnId()); + ls.add(columnOverlappingName()); + ls.add(columnRegularName()); + ls.add(columnSortOrder()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "overlapping_host"; + protected final String _tableDispName = "overlapping_host"; + protected final String _tablePropertyName = "OverlappingHost"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +172,6 @@ public class OverlappingHostDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +186,27 @@ public class OverlappingHostDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.OverlappingHost"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.OverlappingHostCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.OverlappingHostBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return OverlappingHost.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new OverlappingHost(); } @Override @@ -138,12 +233,6 @@ public class OverlappingHostDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/PathMappingDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/PathMappingDbm.java index cc02ac22e..e3db61280 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/PathMappingDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/PathMappingDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.PathMapping; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class PathMappingDbm extends AbstractDBMeta { @@ -24,6 +27,135 @@ public class PathMappingDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((PathMapping) et).getCreatedBy(), (et, vl) -> ((PathMapping) et).setCreatedBy(DfTypeUtil.toString(vl)), + "createdBy"); + setupEpg(_epgMap, et -> ((PathMapping) et).getCreatedTime(), (et, vl) -> ((PathMapping) et).setCreatedTime(DfTypeUtil.toLong(vl)), + "createdTime"); + setupEpg(_epgMap, et -> ((PathMapping) et).getId(), (et, vl) -> ((PathMapping) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((PathMapping) et).getProcessType(), + (et, vl) -> ((PathMapping) et).setProcessType(DfTypeUtil.toString(vl)), "processType"); + setupEpg(_epgMap, et -> ((PathMapping) et).getRegex(), (et, vl) -> ((PathMapping) et).setRegex(DfTypeUtil.toString(vl)), "regex"); + setupEpg(_epgMap, et -> ((PathMapping) et).getReplacement(), + (et, vl) -> ((PathMapping) et).setReplacement(DfTypeUtil.toString(vl)), "replacement"); + setupEpg(_epgMap, et -> ((PathMapping) et).getSortOrder(), (et, vl) -> ((PathMapping) et).setSortOrder(DfTypeUtil.toInteger(vl)), + "sortOrder"); + setupEpg(_epgMap, et -> ((PathMapping) et).getUpdatedBy(), (et, vl) -> ((PathMapping) et).setUpdatedBy(DfTypeUtil.toString(vl)), + "updatedBy"); + setupEpg(_epgMap, et -> ((PathMapping) et).getUpdatedTime(), (et, vl) -> ((PathMapping) et).setUpdatedTime(DfTypeUtil.toLong(vl)), + "updatedTime"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnProcessType = cci("processType", "processType", null, null, String.class, "processType", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnRegex = cci("regex", "regex", null, null, String.class, "regex", null, false, false, false, "String", + 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnReplacement = cci("replacement", "replacement", null, null, String.class, "replacement", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSortOrder = cci("sortOrder", "sortOrder", null, null, Integer.class, "sortOrder", null, false, false, + false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnProcessType() { + return _columnProcessType; + } + + public ColumnInfo columnRegex() { + return _columnRegex; + } + + public ColumnInfo columnReplacement() { + return _columnReplacement; + } + + public ColumnInfo columnSortOrder() { + return _columnSortOrder; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnId()); + ls.add(columnProcessType()); + ls.add(columnRegex()); + ls.add(columnReplacement()); + ls.add(columnSortOrder()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "path_mapping"; + protected final String _tableDispName = "path_mapping"; + protected final String _tablePropertyName = "PathMapping"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +180,6 @@ public class PathMappingDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +194,27 @@ public class PathMappingDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.PathMapping"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.PathMappingCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.PathMappingBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return PathMapping.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new PathMapping(); } @Override @@ -138,12 +241,6 @@ public class PathMappingDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RequestHeaderDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RequestHeaderDbm.java index c489dcaba..c48c10938 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RequestHeaderDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RequestHeaderDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.RequestHeader; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class RequestHeaderDbm extends AbstractDBMeta { @@ -24,6 +27,126 @@ public class RequestHeaderDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((RequestHeader) et).getCreatedBy(), + (et, vl) -> ((RequestHeader) et).setCreatedBy(DfTypeUtil.toString(vl)), "createdBy"); + setupEpg(_epgMap, et -> ((RequestHeader) et).getCreatedTime(), + (et, vl) -> ((RequestHeader) et).setCreatedTime(DfTypeUtil.toLong(vl)), "createdTime"); + setupEpg(_epgMap, et -> ((RequestHeader) et).getId(), (et, vl) -> ((RequestHeader) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((RequestHeader) et).getName(), (et, vl) -> ((RequestHeader) et).setName(DfTypeUtil.toString(vl)), "name"); + setupEpg(_epgMap, et -> ((RequestHeader) et).getUpdatedBy(), + (et, vl) -> ((RequestHeader) et).setUpdatedBy(DfTypeUtil.toString(vl)), "updatedBy"); + setupEpg(_epgMap, et -> ((RequestHeader) et).getUpdatedTime(), + (et, vl) -> ((RequestHeader) et).setUpdatedTime(DfTypeUtil.toLong(vl)), "updatedTime"); + setupEpg(_epgMap, et -> ((RequestHeader) et).getValue(), (et, vl) -> ((RequestHeader) et).setValue(DfTypeUtil.toString(vl)), + "value"); + setupEpg(_epgMap, et -> ((RequestHeader) et).getWebConfigId(), + (et, vl) -> ((RequestHeader) et).setWebConfigId(DfTypeUtil.toString(vl)), "webConfigId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnValue = cci("value", "value", null, null, String.class, "value", null, false, false, false, "String", + 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnWebConfigId = cci("webConfigId", "webConfigId", null, null, String.class, "webConfigId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnName() { + return _columnName; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + public ColumnInfo columnValue() { + return _columnValue; + } + + public ColumnInfo columnWebConfigId() { + return _columnWebConfigId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnId()); + ls.add(columnName()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + ls.add(columnValue()); + ls.add(columnWebConfigId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "request_header"; + protected final String _tableDispName = "request_header"; + protected final String _tablePropertyName = "RequestHeader"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +171,6 @@ public class RequestHeaderDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +185,27 @@ public class RequestHeaderDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.RequestHeader"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.RequestHeaderCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.RequestHeaderBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return RequestHeader.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new RequestHeader(); } @Override @@ -138,12 +232,6 @@ public class RequestHeaderDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RoleDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RoleDbm.java new file mode 100644 index 000000000..d3319c39b --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RoleDbm.java @@ -0,0 +1,187 @@ +package org.codelibs.fess.es.bsentity.dbmeta; + +import java.util.List; +import java.util.Map; + +import org.codelibs.fess.es.exentity.Role; +import org.dbflute.Entity; +import org.dbflute.dbmeta.AbstractDBMeta; +import org.dbflute.dbmeta.info.ColumnInfo; +import org.dbflute.dbmeta.info.UniqueInfo; +import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; +import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; + +public class RoleDbm extends AbstractDBMeta { + + // =================================================================================== + // Singleton + // ========= + private static final RoleDbm _instance = new RoleDbm(); + + private RoleDbm() { + } + + public static RoleDbm getInstance() { + return _instance; + } + + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((Role) et).getId(), (et, vl) -> ((Role) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((Role) et).getName(), (et, vl) -> ((Role) et).setName(DfTypeUtil.toString(vl)), "name"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnName() { + return _columnName; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnId()); + ls.add(columnName()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "role"; + protected final String _tableDispName = "role"; + protected final String _tablePropertyName = "Role"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + + @Override + public String getProjectName() { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getProjectPrefix() { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getGenerationGapBasePrefix() { + // TODO Auto-generated method stub + return null; + } + + @Override + public DBDef getCurrentDBDef() { + // TODO Auto-generated method stub + return null; + } + + @Override + public boolean hasPrimaryKey() { + // TODO Auto-generated method stub + return false; + } + + @Override + public boolean hasCompoundPrimaryKey() { + // TODO Auto-generated method stub + return false; + } + + @Override + public String getEntityTypeName() { + return "org.codelibs.fess.es.exentity.Role"; + } + + @Override + public String getConditionBeanTypeName() { + return "org.codelibs.fess.es.cbean.RoleCB"; + } + + @Override + public String getBehaviorTypeName() { + return "org.codelibs.fess.es.exbhv.RoleBhv"; + } + + @Override + public Class getEntityType() { + return Role.class; + } + + @Override + public Entity newEntity() { + return new Role(); + } + + @Override + public void acceptPrimaryKeyMap(Entity entity, Map primaryKeyMap) { + // TODO Auto-generated method stub + + } + + @Override + public void acceptAllColumnMap(Entity entity, Map allColumnMap) { + // TODO Auto-generated method stub + + } + + @Override + public Map extractPrimaryKeyMap(Entity entity) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Map extractAllColumnMap(Entity entity) { + // TODO Auto-generated method stub + return null; + } + + @Override + protected UniqueInfo cpui() { + // TODO Auto-generated method stub + return null; + } + +} diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RoleTypeDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RoleTypeDbm.java index bc70b0615..70959ee53 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RoleTypeDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RoleTypeDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.RoleType; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class RoleTypeDbm extends AbstractDBMeta { @@ -24,6 +27,125 @@ public class RoleTypeDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((RoleType) et).getCreatedBy(), (et, vl) -> ((RoleType) et).setCreatedBy(DfTypeUtil.toString(vl)), + "createdBy"); + setupEpg(_epgMap, et -> ((RoleType) et).getCreatedTime(), (et, vl) -> ((RoleType) et).setCreatedTime(DfTypeUtil.toLong(vl)), + "createdTime"); + setupEpg(_epgMap, et -> ((RoleType) et).getId(), (et, vl) -> ((RoleType) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((RoleType) et).getName(), (et, vl) -> ((RoleType) et).setName(DfTypeUtil.toString(vl)), "name"); + setupEpg(_epgMap, et -> ((RoleType) et).getSortOrder(), (et, vl) -> ((RoleType) et).setSortOrder(DfTypeUtil.toInteger(vl)), + "sortOrder"); + setupEpg(_epgMap, et -> ((RoleType) et).getUpdatedBy(), (et, vl) -> ((RoleType) et).setUpdatedBy(DfTypeUtil.toString(vl)), + "updatedBy"); + setupEpg(_epgMap, et -> ((RoleType) et).getUpdatedTime(), (et, vl) -> ((RoleType) et).setUpdatedTime(DfTypeUtil.toLong(vl)), + "updatedTime"); + setupEpg(_epgMap, et -> ((RoleType) et).getValue(), (et, vl) -> ((RoleType) et).setValue(DfTypeUtil.toString(vl)), "value"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSortOrder = cci("sortOrder", "sortOrder", null, null, Integer.class, "sortOrder", null, false, false, + false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnValue = cci("value", "value", null, null, String.class, "value", null, false, false, false, "String", + 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnName() { + return _columnName; + } + + public ColumnInfo columnSortOrder() { + return _columnSortOrder; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + public ColumnInfo columnValue() { + return _columnValue; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnId()); + ls.add(columnName()); + ls.add(columnSortOrder()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + ls.add(columnValue()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "role_type"; + protected final String _tableDispName = "role_type"; + protected final String _tablePropertyName = "RoleType"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +170,6 @@ public class RoleTypeDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +184,27 @@ public class RoleTypeDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.RoleType"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.RoleTypeCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.RoleTypeBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return RoleType.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new RoleType(); } @Override @@ -138,12 +231,6 @@ public class RoleTypeDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/ScheduledJobDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/ScheduledJobDbm.java index 032db1d83..fe5b419f4 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/ScheduledJobDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/ScheduledJobDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.ScheduledJob; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class ScheduledJobDbm extends AbstractDBMeta { @@ -24,6 +27,180 @@ public class ScheduledJobDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((ScheduledJob) et).getAvailable(), (et, vl) -> ((ScheduledJob) et).setAvailable(DfTypeUtil.toBoolean(vl)), + "available"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getCrawler(), (et, vl) -> ((ScheduledJob) et).setCrawler(DfTypeUtil.toBoolean(vl)), + "crawler"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getCreatedBy(), (et, vl) -> ((ScheduledJob) et).setCreatedBy(DfTypeUtil.toString(vl)), + "createdBy"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getCreatedTime(), + (et, vl) -> ((ScheduledJob) et).setCreatedTime(DfTypeUtil.toLong(vl)), "createdTime"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getCronExpression(), + (et, vl) -> ((ScheduledJob) et).setCronExpression(DfTypeUtil.toString(vl)), "cronExpression"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getId(), (et, vl) -> ((ScheduledJob) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getJobLogging(), + (et, vl) -> ((ScheduledJob) et).setJobLogging(DfTypeUtil.toBoolean(vl)), "jobLogging"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getName(), (et, vl) -> ((ScheduledJob) et).setName(DfTypeUtil.toString(vl)), "name"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getScriptData(), + (et, vl) -> ((ScheduledJob) et).setScriptData(DfTypeUtil.toString(vl)), "scriptData"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getScriptType(), + (et, vl) -> ((ScheduledJob) et).setScriptType(DfTypeUtil.toString(vl)), "scriptType"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getSortOrder(), (et, vl) -> ((ScheduledJob) et).setSortOrder(DfTypeUtil.toInteger(vl)), + "sortOrder"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getTarget(), (et, vl) -> ((ScheduledJob) et).setTarget(DfTypeUtil.toString(vl)), + "target"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getUpdatedBy(), (et, vl) -> ((ScheduledJob) et).setUpdatedBy(DfTypeUtil.toString(vl)), + "updatedBy"); + setupEpg(_epgMap, et -> ((ScheduledJob) et).getUpdatedTime(), + (et, vl) -> ((ScheduledJob) et).setUpdatedTime(DfTypeUtil.toLong(vl)), "updatedTime"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnAvailable = cci("available", "available", null, null, Boolean.class, "available", null, false, false, + false, "Boolean", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCrawler = cci("crawler", "crawler", null, null, Boolean.class, "crawler", null, false, false, false, + "Boolean", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCronExpression = cci("cronExpression", "cronExpression", null, null, String.class, "cronExpression", + null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnJobLogging = cci("jobLogging", "jobLogging", null, null, Boolean.class, "jobLogging", null, false, + false, false, "Boolean", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnScriptData = cci("scriptData", "scriptData", null, null, String.class, "scriptData", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnScriptType = cci("scriptType", "scriptType", null, null, String.class, "scriptType", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSortOrder = cci("sortOrder", "sortOrder", null, null, Integer.class, "sortOrder", null, false, false, + false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnTarget = cci("target", "target", null, null, String.class, "target", null, false, false, false, + "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnAvailable() { + return _columnAvailable; + } + + public ColumnInfo columnCrawler() { + return _columnCrawler; + } + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnCronExpression() { + return _columnCronExpression; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnJobLogging() { + return _columnJobLogging; + } + + public ColumnInfo columnName() { + return _columnName; + } + + public ColumnInfo columnScriptData() { + return _columnScriptData; + } + + public ColumnInfo columnScriptType() { + return _columnScriptType; + } + + public ColumnInfo columnSortOrder() { + return _columnSortOrder; + } + + public ColumnInfo columnTarget() { + return _columnTarget; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnAvailable()); + ls.add(columnCrawler()); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnCronExpression()); + ls.add(columnId()); + ls.add(columnJobLogging()); + ls.add(columnName()); + ls.add(columnScriptData()); + ls.add(columnScriptType()); + ls.add(columnSortOrder()); + ls.add(columnTarget()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "scheduled_job"; + protected final String _tableDispName = "scheduled_job"; + protected final String _tablePropertyName = "ScheduledJob"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +225,6 @@ public class ScheduledJobDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +239,27 @@ public class ScheduledJobDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.ScheduledJob"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.ScheduledJobCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.ScheduledJobBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return ScheduledJob.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new ScheduledJob(); } @Override @@ -138,12 +286,6 @@ public class ScheduledJobDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SearchFieldLogDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SearchFieldLogDbm.java index 52b8859d0..b8ae45d9a 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SearchFieldLogDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SearchFieldLogDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.SearchFieldLog; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class SearchFieldLogDbm extends AbstractDBMeta { @@ -24,6 +27,90 @@ public class SearchFieldLogDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((SearchFieldLog) et).getId(), (et, vl) -> ((SearchFieldLog) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((SearchFieldLog) et).getName(), (et, vl) -> ((SearchFieldLog) et).setName(DfTypeUtil.toString(vl)), "name"); + setupEpg(_epgMap, et -> ((SearchFieldLog) et).getSearchLogId(), + (et, vl) -> ((SearchFieldLog) et).setSearchLogId(DfTypeUtil.toString(vl)), "searchLogId"); + setupEpg(_epgMap, et -> ((SearchFieldLog) et).getValue(), (et, vl) -> ((SearchFieldLog) et).setValue(DfTypeUtil.toString(vl)), + "value"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSearchLogId = cci("searchLogId", "searchLogId", null, null, String.class, "searchLogId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnValue = cci("value", "value", null, null, String.class, "value", null, false, false, false, "String", + 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnName() { + return _columnName; + } + + public ColumnInfo columnSearchLogId() { + return _columnSearchLogId; + } + + public ColumnInfo columnValue() { + return _columnValue; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnId()); + ls.add(columnName()); + ls.add(columnSearchLogId()); + ls.add(columnValue()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "search_field_log"; + protected final String _tableDispName = "search_field_log"; + protected final String _tablePropertyName = "SearchFieldLog"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +135,6 @@ public class SearchFieldLogDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +149,27 @@ public class SearchFieldLogDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.SearchFieldLog"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.SearchFieldLogCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.SearchFieldLogBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return SearchFieldLog.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new SearchFieldLog(); } @Override @@ -138,12 +196,6 @@ public class SearchFieldLogDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SearchLogDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SearchLogDbm.java index 7d9f18734..13fde897b 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SearchLogDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SearchLogDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.SearchLog; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class SearchLogDbm extends AbstractDBMeta { @@ -24,6 +27,170 @@ public class SearchLogDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((SearchLog) et).getAccessType(), (et, vl) -> ((SearchLog) et).setAccessType(DfTypeUtil.toString(vl)), + "accessType"); + setupEpg(_epgMap, et -> ((SearchLog) et).getClientIp(), (et, vl) -> ((SearchLog) et).setClientIp(DfTypeUtil.toString(vl)), + "clientIp"); + setupEpg(_epgMap, et -> ((SearchLog) et).getHitCount(), (et, vl) -> ((SearchLog) et).setHitCount(DfTypeUtil.toLong(vl)), "hitCount"); + setupEpg(_epgMap, et -> ((SearchLog) et).getId(), (et, vl) -> ((SearchLog) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((SearchLog) et).getQueryOffset(), (et, vl) -> ((SearchLog) et).setQueryOffset(DfTypeUtil.toInteger(vl)), + "queryOffset"); + setupEpg(_epgMap, et -> ((SearchLog) et).getQueryPageSize(), + (et, vl) -> ((SearchLog) et).setQueryPageSize(DfTypeUtil.toInteger(vl)), "queryPageSize"); + setupEpg(_epgMap, et -> ((SearchLog) et).getReferer(), (et, vl) -> ((SearchLog) et).setReferer(DfTypeUtil.toString(vl)), "referer"); + setupEpg(_epgMap, et -> ((SearchLog) et).getRequestedTime(), (et, vl) -> ((SearchLog) et).setRequestedTime(DfTypeUtil.toLong(vl)), + "requestedTime"); + setupEpg(_epgMap, et -> ((SearchLog) et).getResponseTime(), (et, vl) -> ((SearchLog) et).setResponseTime(DfTypeUtil.toInteger(vl)), + "responseTime"); + setupEpg(_epgMap, et -> ((SearchLog) et).getSearchWord(), (et, vl) -> ((SearchLog) et).setSearchWord(DfTypeUtil.toString(vl)), + "searchWord"); + setupEpg(_epgMap, et -> ((SearchLog) et).getUserAgent(), (et, vl) -> ((SearchLog) et).setUserAgent(DfTypeUtil.toString(vl)), + "userAgent"); + setupEpg(_epgMap, et -> ((SearchLog) et).getUserInfoId(), (et, vl) -> ((SearchLog) et).setUserInfoId(DfTypeUtil.toString(vl)), + "userInfoId"); + setupEpg(_epgMap, et -> ((SearchLog) et).getUserSessionId(), + (et, vl) -> ((SearchLog) et).setUserSessionId(DfTypeUtil.toString(vl)), "userSessionId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnAccessType = cci("accessType", "accessType", null, null, String.class, "accessType", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnClientIp = cci("clientIp", "clientIp", null, null, String.class, "clientIp", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnHitCount = cci("hitCount", "hitCount", null, null, Long.class, "hitCount", null, false, false, false, + "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnQueryOffset = cci("queryOffset", "queryOffset", null, null, Integer.class, "queryOffset", null, + false, false, false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnQueryPageSize = cci("queryPageSize", "queryPageSize", null, null, Integer.class, "queryPageSize", + null, false, false, false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnReferer = cci("referer", "referer", null, null, String.class, "referer", null, false, false, false, + "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnRequestedTime = cci("requestedTime", "requestedTime", null, null, Long.class, "requestedTime", null, + false, false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnResponseTime = cci("responseTime", "responseTime", null, null, Integer.class, "responseTime", null, + false, false, false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSearchWord = cci("searchWord", "searchWord", null, null, String.class, "searchWord", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUserAgent = cci("userAgent", "userAgent", null, null, String.class, "userAgent", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUserInfoId = cci("userInfoId", "userInfoId", null, null, String.class, "userInfoId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUserSessionId = cci("userSessionId", "userSessionId", null, null, String.class, "userSessionId", + null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnAccessType() { + return _columnAccessType; + } + + public ColumnInfo columnClientIp() { + return _columnClientIp; + } + + public ColumnInfo columnHitCount() { + return _columnHitCount; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnQueryOffset() { + return _columnQueryOffset; + } + + public ColumnInfo columnQueryPageSize() { + return _columnQueryPageSize; + } + + public ColumnInfo columnReferer() { + return _columnReferer; + } + + public ColumnInfo columnRequestedTime() { + return _columnRequestedTime; + } + + public ColumnInfo columnResponseTime() { + return _columnResponseTime; + } + + public ColumnInfo columnSearchWord() { + return _columnSearchWord; + } + + public ColumnInfo columnUserAgent() { + return _columnUserAgent; + } + + public ColumnInfo columnUserInfoId() { + return _columnUserInfoId; + } + + public ColumnInfo columnUserSessionId() { + return _columnUserSessionId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnAccessType()); + ls.add(columnClientIp()); + ls.add(columnHitCount()); + ls.add(columnId()); + ls.add(columnQueryOffset()); + ls.add(columnQueryPageSize()); + ls.add(columnReferer()); + ls.add(columnRequestedTime()); + ls.add(columnResponseTime()); + ls.add(columnSearchWord()); + ls.add(columnUserAgent()); + ls.add(columnUserInfoId()); + ls.add(columnUserSessionId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "search_log"; + protected final String _tableDispName = "search_log"; + protected final String _tablePropertyName = "SearchLog"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +215,6 @@ public class SearchLogDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +229,27 @@ public class SearchLogDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.SearchLog"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.SearchLogCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.SearchLogBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return SearchLog.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new SearchLog(); } @Override @@ -138,12 +276,6 @@ public class SearchLogDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SuggestBadWordDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SuggestBadWordDbm.java index 18c369864..546506fb8 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SuggestBadWordDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SuggestBadWordDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.SuggestBadWord; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class SuggestBadWordDbm extends AbstractDBMeta { @@ -24,6 +27,127 @@ public class SuggestBadWordDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((SuggestBadWord) et).getCreatedBy(), + (et, vl) -> ((SuggestBadWord) et).setCreatedBy(DfTypeUtil.toString(vl)), "createdBy"); + setupEpg(_epgMap, et -> ((SuggestBadWord) et).getCreatedTime(), + (et, vl) -> ((SuggestBadWord) et).setCreatedTime(DfTypeUtil.toLong(vl)), "createdTime"); + setupEpg(_epgMap, et -> ((SuggestBadWord) et).getId(), (et, vl) -> ((SuggestBadWord) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((SuggestBadWord) et).getSuggestWord(), + (et, vl) -> ((SuggestBadWord) et).setSuggestWord(DfTypeUtil.toString(vl)), "suggestWord"); + setupEpg(_epgMap, et -> ((SuggestBadWord) et).getTargetLabel(), + (et, vl) -> ((SuggestBadWord) et).setTargetLabel(DfTypeUtil.toString(vl)), "targetLabel"); + setupEpg(_epgMap, et -> ((SuggestBadWord) et).getTargetRole(), + (et, vl) -> ((SuggestBadWord) et).setTargetRole(DfTypeUtil.toString(vl)), "targetRole"); + setupEpg(_epgMap, et -> ((SuggestBadWord) et).getUpdatedBy(), + (et, vl) -> ((SuggestBadWord) et).setUpdatedBy(DfTypeUtil.toString(vl)), "updatedBy"); + setupEpg(_epgMap, et -> ((SuggestBadWord) et).getUpdatedTime(), + (et, vl) -> ((SuggestBadWord) et).setUpdatedTime(DfTypeUtil.toLong(vl)), "updatedTime"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnSuggestWord = cci("suggestWord", "suggestWord", null, null, String.class, "suggestWord", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnTargetLabel = cci("targetLabel", "targetLabel", null, null, String.class, "targetLabel", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnTargetRole = cci("targetRole", "targetRole", null, null, String.class, "targetRole", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnSuggestWord() { + return _columnSuggestWord; + } + + public ColumnInfo columnTargetLabel() { + return _columnTargetLabel; + } + + public ColumnInfo columnTargetRole() { + return _columnTargetRole; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnId()); + ls.add(columnSuggestWord()); + ls.add(columnTargetLabel()); + ls.add(columnTargetRole()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "suggest_bad_word"; + protected final String _tableDispName = "suggest_bad_word"; + protected final String _tablePropertyName = "SuggestBadWord"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +172,6 @@ public class SuggestBadWordDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +186,27 @@ public class SuggestBadWordDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.SuggestBadWord"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.SuggestBadWordCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.SuggestBadWordBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return SuggestBadWord.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new SuggestBadWord(); } @Override @@ -138,12 +233,6 @@ public class SuggestBadWordDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SuggestElevateWordDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SuggestElevateWordDbm.java index 54241f4de..9f8a657ae 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SuggestElevateWordDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/SuggestElevateWordDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.SuggestElevateWord; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class SuggestElevateWordDbm extends AbstractDBMeta { @@ -24,6 +27,146 @@ public class SuggestElevateWordDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((SuggestElevateWord) et).getBoost(), + (et, vl) -> ((SuggestElevateWord) et).setBoost(DfTypeUtil.toFloat(vl)), "boost"); + setupEpg(_epgMap, et -> ((SuggestElevateWord) et).getCreatedBy(), + (et, vl) -> ((SuggestElevateWord) et).setCreatedBy(DfTypeUtil.toString(vl)), "createdBy"); + setupEpg(_epgMap, et -> ((SuggestElevateWord) et).getCreatedTime(), + (et, vl) -> ((SuggestElevateWord) et).setCreatedTime(DfTypeUtil.toLong(vl)), "createdTime"); + setupEpg(_epgMap, et -> ((SuggestElevateWord) et).getId(), (et, vl) -> ((SuggestElevateWord) et).setId(DfTypeUtil.toString(vl)), + "id"); + setupEpg(_epgMap, et -> ((SuggestElevateWord) et).getReading(), + (et, vl) -> ((SuggestElevateWord) et).setReading(DfTypeUtil.toString(vl)), "reading"); + setupEpg(_epgMap, et -> ((SuggestElevateWord) et).getSuggestWord(), + (et, vl) -> ((SuggestElevateWord) et).setSuggestWord(DfTypeUtil.toString(vl)), "suggestWord"); + setupEpg(_epgMap, et -> ((SuggestElevateWord) et).getTargetLabel(), + (et, vl) -> ((SuggestElevateWord) et).setTargetLabel(DfTypeUtil.toString(vl)), "targetLabel"); + setupEpg(_epgMap, et -> ((SuggestElevateWord) et).getTargetRole(), + (et, vl) -> ((SuggestElevateWord) et).setTargetRole(DfTypeUtil.toString(vl)), "targetRole"); + setupEpg(_epgMap, et -> ((SuggestElevateWord) et).getUpdatedBy(), + (et, vl) -> ((SuggestElevateWord) et).setUpdatedBy(DfTypeUtil.toString(vl)), "updatedBy"); + setupEpg(_epgMap, et -> ((SuggestElevateWord) et).getUpdatedTime(), + (et, vl) -> ((SuggestElevateWord) et).setUpdatedTime(DfTypeUtil.toLong(vl)), "updatedTime"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnBoost = cci("boost", "boost", null, null, Float.class, "boost", null, false, false, false, "Float", + 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnReading = cci("reading", "reading", null, null, String.class, "reading", null, false, false, false, + "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSuggestWord = cci("suggestWord", "suggestWord", null, null, String.class, "suggestWord", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnTargetLabel = cci("targetLabel", "targetLabel", null, null, String.class, "targetLabel", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnTargetRole = cci("targetRole", "targetRole", null, null, String.class, "targetRole", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnBoost() { + return _columnBoost; + } + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnReading() { + return _columnReading; + } + + public ColumnInfo columnSuggestWord() { + return _columnSuggestWord; + } + + public ColumnInfo columnTargetLabel() { + return _columnTargetLabel; + } + + public ColumnInfo columnTargetRole() { + return _columnTargetRole; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnBoost()); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnId()); + ls.add(columnReading()); + ls.add(columnSuggestWord()); + ls.add(columnTargetLabel()); + ls.add(columnTargetRole()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "suggest_elevate_word"; + protected final String _tableDispName = "suggest_elevate_word"; + protected final String _tablePropertyName = "SuggestElevateWord"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +191,6 @@ public class SuggestElevateWordDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +205,27 @@ public class SuggestElevateWordDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.SuggestElevateWord"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.SuggestElevateWordCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.SuggestElevateWordBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return SuggestElevateWord.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new SuggestElevateWord(); } @Override @@ -138,12 +252,6 @@ public class SuggestElevateWordDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/UserDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/UserDbm.java new file mode 100644 index 000000000..257434528 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/UserDbm.java @@ -0,0 +1,211 @@ +package org.codelibs.fess.es.bsentity.dbmeta; + +import java.util.List; +import java.util.Map; + +import org.codelibs.fess.es.exentity.User; +import org.dbflute.Entity; +import org.dbflute.dbmeta.AbstractDBMeta; +import org.dbflute.dbmeta.info.ColumnInfo; +import org.dbflute.dbmeta.info.UniqueInfo; +import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; +import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; + +public class UserDbm extends AbstractDBMeta { + + // =================================================================================== + // Singleton + // ========= + private static final UserDbm _instance = new UserDbm(); + + private UserDbm() { + } + + public static UserDbm getInstance() { + return _instance; + } + + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((User) et).getGroups(), (et, vl) -> ((User) et).setGroups((String[]) vl), "groups"); + setupEpg(_epgMap, et -> ((User) et).getId(), (et, vl) -> ((User) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((User) et).getName(), (et, vl) -> ((User) et).setName(DfTypeUtil.toString(vl)), "name"); + setupEpg(_epgMap, et -> ((User) et).getPassword(), (et, vl) -> ((User) et).setPassword(DfTypeUtil.toString(vl)), "password"); + setupEpg(_epgMap, et -> ((User) et).getRoles(), (et, vl) -> ((User) et).setRoles((String[]) vl), "roles"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnGroups = cci("groups", "groups", null, null, String[].class, "groups", null, false, false, false, + "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnPassword = cci("password", "password", null, null, String.class, "password", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnRoles = cci("roles", "roles", null, null, String[].class, "roles", null, false, false, false, + "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnGroups() { + return _columnGroups; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnName() { + return _columnName; + } + + public ColumnInfo columnPassword() { + return _columnPassword; + } + + public ColumnInfo columnRoles() { + return _columnRoles; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnGroups()); + ls.add(columnId()); + ls.add(columnName()); + ls.add(columnPassword()); + ls.add(columnRoles()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "user"; + protected final String _tableDispName = "user"; + protected final String _tablePropertyName = "User"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + + @Override + public String getProjectName() { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getProjectPrefix() { + // TODO Auto-generated method stub + return null; + } + + @Override + public String getGenerationGapBasePrefix() { + // TODO Auto-generated method stub + return null; + } + + @Override + public DBDef getCurrentDBDef() { + // TODO Auto-generated method stub + return null; + } + + @Override + public boolean hasPrimaryKey() { + // TODO Auto-generated method stub + return false; + } + + @Override + public boolean hasCompoundPrimaryKey() { + // TODO Auto-generated method stub + return false; + } + + @Override + public String getEntityTypeName() { + return "org.codelibs.fess.es.exentity.User"; + } + + @Override + public String getConditionBeanTypeName() { + return "org.codelibs.fess.es.cbean.UserCB"; + } + + @Override + public String getBehaviorTypeName() { + return "org.codelibs.fess.es.exbhv.UserBhv"; + } + + @Override + public Class getEntityType() { + return User.class; + } + + @Override + public Entity newEntity() { + return new User(); + } + + @Override + public void acceptPrimaryKeyMap(Entity entity, Map primaryKeyMap) { + // TODO Auto-generated method stub + + } + + @Override + public void acceptAllColumnMap(Entity entity, Map allColumnMap) { + // TODO Auto-generated method stub + + } + + @Override + public Map extractPrimaryKeyMap(Entity entity) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Map extractAllColumnMap(Entity entity) { + // TODO Auto-generated method stub + return null; + } + + @Override + protected UniqueInfo cpui() { + // TODO Auto-generated method stub + return null; + } + +} diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/UserInfoDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/UserInfoDbm.java index 11ef483c7..d99b4f142 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/UserInfoDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/UserInfoDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.UserInfo; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class UserInfoDbm extends AbstractDBMeta { @@ -24,6 +27,90 @@ public class UserInfoDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((UserInfo) et).getCode(), (et, vl) -> ((UserInfo) et).setCode(DfTypeUtil.toString(vl)), "code"); + setupEpg(_epgMap, et -> ((UserInfo) et).getCreatedTime(), (et, vl) -> ((UserInfo) et).setCreatedTime(DfTypeUtil.toLong(vl)), + "createdTime"); + setupEpg(_epgMap, et -> ((UserInfo) et).getId(), (et, vl) -> ((UserInfo) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((UserInfo) et).getUpdatedTime(), (et, vl) -> ((UserInfo) et).setUpdatedTime(DfTypeUtil.toLong(vl)), + "updatedTime"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnCode = cci("code", "code", null, null, String.class, "code", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnCode() { + return _columnCode; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnCode()); + ls.add(columnCreatedTime()); + ls.add(columnId()); + ls.add(columnUpdatedTime()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "user_info"; + protected final String _tableDispName = "user_info"; + protected final String _tablePropertyName = "UserInfo"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +135,6 @@ public class UserInfoDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +149,27 @@ public class UserInfoDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.UserInfo"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.UserInfoCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.UserInfoBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return UserInfo.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new UserInfo(); } @Override @@ -138,12 +196,6 @@ public class UserInfoDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebAuthenticationDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebAuthenticationDbm.java index 24153e3cb..60f285295 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebAuthenticationDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebAuthenticationDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.WebAuthentication; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class WebAuthenticationDbm extends AbstractDBMeta { @@ -24,6 +27,172 @@ public class WebAuthenticationDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((WebAuthentication) et).getAuthRealm(), + (et, vl) -> ((WebAuthentication) et).setAuthRealm(DfTypeUtil.toString(vl)), "authRealm"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getCreatedBy(), + (et, vl) -> ((WebAuthentication) et).setCreatedBy(DfTypeUtil.toString(vl)), "createdBy"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getCreatedTime(), + (et, vl) -> ((WebAuthentication) et).setCreatedTime(DfTypeUtil.toLong(vl)), "createdTime"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getHostname(), + (et, vl) -> ((WebAuthentication) et).setHostname(DfTypeUtil.toString(vl)), "hostname"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getId(), (et, vl) -> ((WebAuthentication) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getParameters(), + (et, vl) -> ((WebAuthentication) et).setParameters(DfTypeUtil.toString(vl)), "parameters"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getPassword(), + (et, vl) -> ((WebAuthentication) et).setPassword(DfTypeUtil.toString(vl)), "password"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getPort(), (et, vl) -> ((WebAuthentication) et).setPort(DfTypeUtil.toInteger(vl)), + "port"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getProtocolScheme(), + (et, vl) -> ((WebAuthentication) et).setProtocolScheme(DfTypeUtil.toString(vl)), "protocolScheme"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getUpdatedBy(), + (et, vl) -> ((WebAuthentication) et).setUpdatedBy(DfTypeUtil.toString(vl)), "updatedBy"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getUpdatedTime(), + (et, vl) -> ((WebAuthentication) et).setUpdatedTime(DfTypeUtil.toLong(vl)), "updatedTime"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getUsername(), + (et, vl) -> ((WebAuthentication) et).setUsername(DfTypeUtil.toString(vl)), "username"); + setupEpg(_epgMap, et -> ((WebAuthentication) et).getWebConfigId(), + (et, vl) -> ((WebAuthentication) et).setWebConfigId(DfTypeUtil.toString(vl)), "webConfigId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnAuthRealm = cci("authRealm", "authRealm", null, null, String.class, "authRealm", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnHostname = cci("hostname", "hostname", null, null, String.class, "hostname", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnParameters = cci("parameters", "parameters", null, null, String.class, "parameters", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnPassword = cci("password", "password", null, null, String.class, "password", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnPort = cci("port", "port", null, null, Integer.class, "port", null, false, false, false, "Integer", + 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnProtocolScheme = cci("protocolScheme", "protocolScheme", null, null, String.class, "protocolScheme", + null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUsername = cci("username", "username", null, null, String.class, "username", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnWebConfigId = cci("webConfigId", "webConfigId", null, null, String.class, "webConfigId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnAuthRealm() { + return _columnAuthRealm; + } + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnHostname() { + return _columnHostname; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnParameters() { + return _columnParameters; + } + + public ColumnInfo columnPassword() { + return _columnPassword; + } + + public ColumnInfo columnPort() { + return _columnPort; + } + + public ColumnInfo columnProtocolScheme() { + return _columnProtocolScheme; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + public ColumnInfo columnUsername() { + return _columnUsername; + } + + public ColumnInfo columnWebConfigId() { + return _columnWebConfigId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnAuthRealm()); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnHostname()); + ls.add(columnId()); + ls.add(columnParameters()); + ls.add(columnPassword()); + ls.add(columnPort()); + ls.add(columnProtocolScheme()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + ls.add(columnUsername()); + ls.add(columnWebConfigId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "web_authentication"; + protected final String _tableDispName = "web_authentication"; + protected final String _tablePropertyName = "WebAuthentication"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +217,6 @@ public class WebAuthenticationDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +231,27 @@ public class WebAuthenticationDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.WebAuthentication"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.WebAuthenticationCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.WebAuthenticationBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return WebAuthentication.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new WebAuthentication(); } @Override @@ -138,12 +278,6 @@ public class WebAuthenticationDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigDbm.java index e8eb8b7a6..39b7634ba 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.WebConfig; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class WebConfigDbm extends AbstractDBMeta { @@ -24,6 +27,231 @@ public class WebConfigDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((WebConfig) et).getAvailable(), (et, vl) -> ((WebConfig) et).setAvailable(DfTypeUtil.toBoolean(vl)), + "available"); + setupEpg(_epgMap, et -> ((WebConfig) et).getBoost(), (et, vl) -> ((WebConfig) et).setBoost(DfTypeUtil.toFloat(vl)), "boost"); + setupEpg(_epgMap, et -> ((WebConfig) et).getConfigParameter(), + (et, vl) -> ((WebConfig) et).setConfigParameter(DfTypeUtil.toString(vl)), "configParameter"); + setupEpg(_epgMap, et -> ((WebConfig) et).getCreatedBy(), (et, vl) -> ((WebConfig) et).setCreatedBy(DfTypeUtil.toString(vl)), + "createdBy"); + setupEpg(_epgMap, et -> ((WebConfig) et).getCreatedTime(), (et, vl) -> ((WebConfig) et).setCreatedTime(DfTypeUtil.toLong(vl)), + "createdTime"); + setupEpg(_epgMap, et -> ((WebConfig) et).getDepth(), (et, vl) -> ((WebConfig) et).setDepth(DfTypeUtil.toInteger(vl)), "depth"); + setupEpg(_epgMap, et -> ((WebConfig) et).getExcludedDocUrls(), + (et, vl) -> ((WebConfig) et).setExcludedDocUrls(DfTypeUtil.toString(vl)), "excludedDocUrls"); + setupEpg(_epgMap, et -> ((WebConfig) et).getExcludedUrls(), (et, vl) -> ((WebConfig) et).setExcludedUrls(DfTypeUtil.toString(vl)), + "excludedUrls"); + setupEpg(_epgMap, et -> ((WebConfig) et).getId(), (et, vl) -> ((WebConfig) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((WebConfig) et).getIncludedDocUrls(), + (et, vl) -> ((WebConfig) et).setIncludedDocUrls(DfTypeUtil.toString(vl)), "includedDocUrls"); + setupEpg(_epgMap, et -> ((WebConfig) et).getIncludedUrls(), (et, vl) -> ((WebConfig) et).setIncludedUrls(DfTypeUtil.toString(vl)), + "includedUrls"); + setupEpg(_epgMap, et -> ((WebConfig) et).getIntervalTime(), (et, vl) -> ((WebConfig) et).setIntervalTime(DfTypeUtil.toInteger(vl)), + "intervalTime"); + setupEpg(_epgMap, et -> ((WebConfig) et).getMaxAccessCount(), + (et, vl) -> ((WebConfig) et).setMaxAccessCount(DfTypeUtil.toLong(vl)), "maxAccessCount"); + setupEpg(_epgMap, et -> ((WebConfig) et).getName(), (et, vl) -> ((WebConfig) et).setName(DfTypeUtil.toString(vl)), "name"); + setupEpg(_epgMap, et -> ((WebConfig) et).getNumOfThread(), (et, vl) -> ((WebConfig) et).setNumOfThread(DfTypeUtil.toInteger(vl)), + "numOfThread"); + setupEpg(_epgMap, et -> ((WebConfig) et).getSortOrder(), (et, vl) -> ((WebConfig) et).setSortOrder(DfTypeUtil.toInteger(vl)), + "sortOrder"); + setupEpg(_epgMap, et -> ((WebConfig) et).getUpdatedBy(), (et, vl) -> ((WebConfig) et).setUpdatedBy(DfTypeUtil.toString(vl)), + "updatedBy"); + setupEpg(_epgMap, et -> ((WebConfig) et).getUpdatedTime(), (et, vl) -> ((WebConfig) et).setUpdatedTime(DfTypeUtil.toLong(vl)), + "updatedTime"); + setupEpg(_epgMap, et -> ((WebConfig) et).getUrls(), (et, vl) -> ((WebConfig) et).setUrls(DfTypeUtil.toString(vl)), "urls"); + setupEpg(_epgMap, et -> ((WebConfig) et).getUserAgent(), (et, vl) -> ((WebConfig) et).setUserAgent(DfTypeUtil.toString(vl)), + "userAgent"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnAvailable = cci("available", "available", null, null, Boolean.class, "available", null, false, false, + false, "Boolean", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnBoost = cci("boost", "boost", null, null, Float.class, "boost", null, false, false, false, "Float", + 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnConfigParameter = cci("configParameter", "configParameter", null, null, String.class, + "configParameter", null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedBy = cci("createdBy", "createdBy", null, null, String.class, "createdBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnCreatedTime = cci("createdTime", "createdTime", null, null, Long.class, "createdTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnDepth = cci("depth", "depth", null, null, Integer.class, "depth", null, false, false, false, + "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnExcludedDocUrls = cci("excludedDocUrls", "excludedDocUrls", null, null, String.class, + "excludedDocUrls", null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnExcludedUrls = cci("excludedUrls", "excludedUrls", null, null, String.class, "excludedUrls", null, + false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnIncludedDocUrls = cci("includedDocUrls", "includedDocUrls", null, null, String.class, + "includedDocUrls", null, false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnIncludedUrls = cci("includedUrls", "includedUrls", null, null, String.class, "includedUrls", null, + false, false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnIntervalTime = cci("intervalTime", "intervalTime", null, null, Integer.class, "intervalTime", null, + false, false, false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnMaxAccessCount = cci("maxAccessCount", "maxAccessCount", null, null, Long.class, "maxAccessCount", + null, false, false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnName = cci("name", "name", null, null, String.class, "name", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnNumOfThread = cci("numOfThread", "numOfThread", null, null, Integer.class, "numOfThread", null, + false, false, false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnSortOrder = cci("sortOrder", "sortOrder", null, null, Integer.class, "sortOrder", null, false, false, + false, "Integer", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedBy = cci("updatedBy", "updatedBy", null, null, String.class, "updatedBy", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUpdatedTime = cci("updatedTime", "updatedTime", null, null, Long.class, "updatedTime", null, false, + false, false, "Long", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUrls = cci("urls", "urls", null, null, String.class, "urls", null, false, false, false, "String", 0, + 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnUserAgent = cci("userAgent", "userAgent", null, null, String.class, "userAgent", null, false, false, + false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnAvailable() { + return _columnAvailable; + } + + public ColumnInfo columnBoost() { + return _columnBoost; + } + + public ColumnInfo columnConfigParameter() { + return _columnConfigParameter; + } + + public ColumnInfo columnCreatedBy() { + return _columnCreatedBy; + } + + public ColumnInfo columnCreatedTime() { + return _columnCreatedTime; + } + + public ColumnInfo columnDepth() { + return _columnDepth; + } + + public ColumnInfo columnExcludedDocUrls() { + return _columnExcludedDocUrls; + } + + public ColumnInfo columnExcludedUrls() { + return _columnExcludedUrls; + } + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnIncludedDocUrls() { + return _columnIncludedDocUrls; + } + + public ColumnInfo columnIncludedUrls() { + return _columnIncludedUrls; + } + + public ColumnInfo columnIntervalTime() { + return _columnIntervalTime; + } + + public ColumnInfo columnMaxAccessCount() { + return _columnMaxAccessCount; + } + + public ColumnInfo columnName() { + return _columnName; + } + + public ColumnInfo columnNumOfThread() { + return _columnNumOfThread; + } + + public ColumnInfo columnSortOrder() { + return _columnSortOrder; + } + + public ColumnInfo columnUpdatedBy() { + return _columnUpdatedBy; + } + + public ColumnInfo columnUpdatedTime() { + return _columnUpdatedTime; + } + + public ColumnInfo columnUrls() { + return _columnUrls; + } + + public ColumnInfo columnUserAgent() { + return _columnUserAgent; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnAvailable()); + ls.add(columnBoost()); + ls.add(columnConfigParameter()); + ls.add(columnCreatedBy()); + ls.add(columnCreatedTime()); + ls.add(columnDepth()); + ls.add(columnExcludedDocUrls()); + ls.add(columnExcludedUrls()); + ls.add(columnId()); + ls.add(columnIncludedDocUrls()); + ls.add(columnIncludedUrls()); + ls.add(columnIntervalTime()); + ls.add(columnMaxAccessCount()); + ls.add(columnName()); + ls.add(columnNumOfThread()); + ls.add(columnSortOrder()); + ls.add(columnUpdatedBy()); + ls.add(columnUpdatedTime()); + ls.add(columnUrls()); + ls.add(columnUserAgent()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "web_config"; + protected final String _tableDispName = "web_config"; + protected final String _tablePropertyName = "WebConfig"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +276,6 @@ public class WebConfigDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +290,27 @@ public class WebConfigDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.WebConfig"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.WebConfigCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.WebConfigBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return WebConfig.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new WebConfig(); } @Override @@ -138,12 +337,6 @@ public class WebConfigDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigToLabelDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigToLabelDbm.java index 2d5d7e7ac..3a1bbeb36 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigToLabelDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigToLabelDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.WebConfigToLabel; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class WebConfigToLabelDbm extends AbstractDBMeta { @@ -24,6 +27,82 @@ public class WebConfigToLabelDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((WebConfigToLabel) et).getId(), (et, vl) -> ((WebConfigToLabel) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((WebConfigToLabel) et).getLabelTypeId(), + (et, vl) -> ((WebConfigToLabel) et).setLabelTypeId(DfTypeUtil.toString(vl)), "labelTypeId"); + setupEpg(_epgMap, et -> ((WebConfigToLabel) et).getWebConfigId(), + (et, vl) -> ((WebConfigToLabel) et).setWebConfigId(DfTypeUtil.toString(vl)), "webConfigId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnLabelTypeId = cci("labelTypeId", "labelTypeId", null, null, String.class, "labelTypeId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnWebConfigId = cci("webConfigId", "webConfigId", null, null, String.class, "webConfigId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnLabelTypeId() { + return _columnLabelTypeId; + } + + public ColumnInfo columnWebConfigId() { + return _columnWebConfigId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnId()); + ls.add(columnLabelTypeId()); + ls.add(columnWebConfigId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "web_config_to_label"; + protected final String _tableDispName = "web_config_to_label"; + protected final String _tablePropertyName = "WebConfigToLabel"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +127,6 @@ public class WebConfigToLabelDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +141,27 @@ public class WebConfigToLabelDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.WebConfigToLabel"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.WebConfigToLabelCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.WebConfigToLabelBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return WebConfigToLabel.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new WebConfigToLabel(); } @Override @@ -138,12 +188,6 @@ public class WebConfigToLabelDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigToRoleDbm.java b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigToRoleDbm.java index 6389b3a9a..c3558e6e4 100644 --- a/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigToRoleDbm.java +++ b/src/main/java/org/codelibs/fess/es/bsentity/dbmeta/WebConfigToRoleDbm.java @@ -3,12 +3,15 @@ package org.codelibs.fess.es.bsentity.dbmeta; import java.util.List; import java.util.Map; +import org.codelibs.fess.es.exentity.WebConfigToRole; import org.dbflute.Entity; import org.dbflute.dbmeta.AbstractDBMeta; import org.dbflute.dbmeta.info.ColumnInfo; import org.dbflute.dbmeta.info.UniqueInfo; import org.dbflute.dbmeta.name.TableSqlName; +import org.dbflute.dbmeta.property.PropertyGateway; import org.dbflute.dbway.DBDef; +import org.dbflute.util.DfTypeUtil; public class WebConfigToRoleDbm extends AbstractDBMeta { @@ -24,6 +27,82 @@ public class WebConfigToRoleDbm extends AbstractDBMeta { return _instance; } + // =================================================================================== + // Property Gateway + // ================ + // ----------------------------------------------------- + // Column Property + // --------------- + protected final Map _epgMap = newHashMap(); + { + setupEpg(_epgMap, et -> ((WebConfigToRole) et).getId(), (et, vl) -> ((WebConfigToRole) et).setId(DfTypeUtil.toString(vl)), "id"); + setupEpg(_epgMap, et -> ((WebConfigToRole) et).getRoleTypeId(), + (et, vl) -> ((WebConfigToRole) et).setRoleTypeId(DfTypeUtil.toString(vl)), "roleTypeId"); + setupEpg(_epgMap, et -> ((WebConfigToRole) et).getWebConfigId(), + (et, vl) -> ((WebConfigToRole) et).setWebConfigId(DfTypeUtil.toString(vl)), "webConfigId"); + } + + @Override + public PropertyGateway findPropertyGateway(final String prop) { + return doFindEpg(_epgMap, prop); + } + + // =================================================================================== + // Column Info + // =========== + protected final ColumnInfo _columnId = cci("id", "id", null, null, String.class, "id", null, false, false, false, "String", 0, 0, null, + false, null, null, null, null, null, false); + protected final ColumnInfo _columnRoleTypeId = cci("roleTypeId", "roleTypeId", null, null, String.class, "roleTypeId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + protected final ColumnInfo _columnWebConfigId = cci("webConfigId", "webConfigId", null, null, String.class, "webConfigId", null, false, + false, false, "String", 0, 0, null, false, null, null, null, null, null, false); + + public ColumnInfo columnId() { + return _columnId; + } + + public ColumnInfo columnRoleTypeId() { + return _columnRoleTypeId; + } + + public ColumnInfo columnWebConfigId() { + return _columnWebConfigId; + } + + protected List ccil() { + List ls = newArrayList(); + ls.add(columnId()); + ls.add(columnRoleTypeId()); + ls.add(columnWebConfigId()); + return ls; + } + + // =================================================================================== + // Table Info + // ========== + protected final String _tableDbName = "web_config_to_role"; + protected final String _tableDispName = "web_config_to_role"; + protected final String _tablePropertyName = "WebConfigToRole"; + + public String getTableDbName() { + return _tableDbName; + } + + @Override + public String getTableDispName() { + return _tableDispName; + } + + @Override + public String getTablePropertyName() { + return _tablePropertyName; + } + + @Override + public TableSqlName getTableSqlName() { + return null; + } + @Override public String getProjectName() { // TODO Auto-generated method stub @@ -48,30 +127,6 @@ public class WebConfigToRoleDbm extends AbstractDBMeta { return null; } - @Override - public String getTableDbName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTableDispName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public String getTablePropertyName() { - // TODO Auto-generated method stub - return null; - } - - @Override - public TableSqlName getTableSqlName() { - // TODO Auto-generated method stub - return null; - } - @Override public boolean hasPrimaryKey() { // TODO Auto-generated method stub @@ -86,32 +141,27 @@ public class WebConfigToRoleDbm extends AbstractDBMeta { @Override public String getEntityTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exentity.WebConfigToRole"; } @Override public String getConditionBeanTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.cbean.WebConfigToRoleCB"; } @Override public String getBehaviorTypeName() { - // TODO Auto-generated method stub - return null; + return "org.codelibs.fess.es.exbhv.WebConfigToRoleBhv"; } @Override public Class getEntityType() { - // TODO Auto-generated method stub - return null; + return WebConfigToRole.class; } @Override public Entity newEntity() { - // TODO Auto-generated method stub - return null; + return new WebConfigToRole(); } @Override @@ -138,12 +188,6 @@ public class WebConfigToRoleDbm extends AbstractDBMeta { return null; } - @Override - protected List ccil() { - // TODO Auto-generated method stub - return null; - } - @Override protected UniqueInfo cpui() { // TODO Auto-generated method stub diff --git a/src/main/java/org/codelibs/fess/es/cbean/EventLogCB.java b/src/main/java/org/codelibs/fess/es/cbean/EventLogCB.java new file mode 100644 index 000000000..ea42cce5f --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/EventLogCB.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean; + +import org.codelibs.fess.es.cbean.bs.BsEventLogCB; + +/** + * @author FreeGen + */ +public class EventLogCB extends BsEventLogCB { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/GroupCB.java b/src/main/java/org/codelibs/fess/es/cbean/GroupCB.java new file mode 100644 index 000000000..1ce60eebf --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/GroupCB.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean; + +import org.codelibs.fess.es.cbean.bs.BsGroupCB; + +/** + * @author FreeGen + */ +public class GroupCB extends BsGroupCB { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/RoleCB.java b/src/main/java/org/codelibs/fess/es/cbean/RoleCB.java new file mode 100644 index 000000000..10f2864c4 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/RoleCB.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean; + +import org.codelibs.fess.es.cbean.bs.BsRoleCB; + +/** + * @author FreeGen + */ +public class RoleCB extends BsRoleCB { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/UserCB.java b/src/main/java/org/codelibs/fess/es/cbean/UserCB.java new file mode 100644 index 000000000..298a34f1b --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/UserCB.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean; + +import org.codelibs.fess.es.cbean.bs.BsUserCB; + +/** + * @author FreeGen + */ +public class UserCB extends BsUserCB { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/bs/AbstractConditionBean.java b/src/main/java/org/codelibs/fess/es/cbean/bs/AbstractConditionBean.java index 6381bd8c8..2120b3496 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/bs/AbstractConditionBean.java +++ b/src/main/java/org/codelibs/fess/es/cbean/bs/AbstractConditionBean.java @@ -572,6 +572,28 @@ public abstract class AbstractConditionBean implements ConditionBean { // do nothing } + @Override + public boolean hasSpecifiedLocalColumn() { + // TODO Auto-generated method stub + return false; + } + + @Override + public void enableUndefinedClassificationSelect() { + // TODO Auto-generated method stub + } + + @Override + public void disableUndefinedClassificationSelect() { + // TODO Auto-generated method stub + } + + @Override + public boolean isUndefinedClassificationSelectAllowed() { + // TODO Auto-generated method stub + return false; + } + public SearchRequestParams request() { return _searchRequestParams; } diff --git a/src/main/java/org/codelibs/fess/es/cbean/bs/BsEventLogCB.java b/src/main/java/org/codelibs/fess/es/cbean/bs/BsEventLogCB.java new file mode 100644 index 000000000..0807e6133 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/bs/BsEventLogCB.java @@ -0,0 +1,150 @@ +package org.codelibs.fess.es.cbean.bs; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +import org.codelibs.fess.es.bsentity.dbmeta.EventLogDbm; +import org.codelibs.fess.es.cbean.EventLogCB; +import org.codelibs.fess.es.cbean.cq.EventLogCQ; +import org.codelibs.fess.es.cbean.cq.bs.BsEventLogCQ; +import org.dbflute.cbean.ConditionQuery; +import org.elasticsearch.action.count.CountRequestBuilder; +import org.elasticsearch.action.search.SearchRequestBuilder; +import org.elasticsearch.index.query.QueryBuilder; + +/** + * @author FreeGen + */ +public class BsEventLogCB extends AbstractConditionBean { + + protected BsEventLogCQ _conditionQuery; + + protected HpSpecification _specification; + + @Override + public EventLogDbm asDBMeta() { + return EventLogDbm.getInstance(); + } + + @Override + public String asTableDbName() { + return "event_log"; + } + + @Override + public boolean hasSpecifiedColumn() { + return _specification != null; + } + + @Override + public ConditionQuery localCQ() { + return doGetConditionQuery(); + } + + public EventLogCB acceptPK(String id) { + assertObjectNotNull("id", id); + BsEventLogCB cb = this; + cb.query().docMeta().setId_Equal(id); + return (EventLogCB) this; + } + + @Override + public void acceptPrimaryKeyMap(Map primaryKeyMap) { + acceptPK((String) primaryKeyMap.get("_id")); + } + + @Override + public CountRequestBuilder build(CountRequestBuilder builder) { + if (_conditionQuery != null) { + QueryBuilder queryBuilder = _conditionQuery.getQuery(); + if (queryBuilder != null) { + builder.setQuery(queryBuilder); + } + } + return builder; + } + + @Override + public SearchRequestBuilder build(SearchRequestBuilder builder) { + if (_conditionQuery != null) { + QueryBuilder queryBuilder = _conditionQuery.getQuery(); + if (queryBuilder != null) { + builder.setQuery(queryBuilder); + } + _conditionQuery.getFieldSortBuilderList().forEach(sort -> { + builder.addSort(sort); + }); + } + + if (_specification != null) { + builder.setFetchSource(_specification.columnList.toArray(new String[_specification.columnList.size()]), null); + } + + return builder; + } + + public BsEventLogCQ query() { + assertQueryPurpose(); + return doGetConditionQuery(); + } + + protected BsEventLogCQ doGetConditionQuery() { + if (_conditionQuery == null) { + _conditionQuery = createLocalCQ(); + } + return _conditionQuery; + } + + protected BsEventLogCQ createLocalCQ() { + return new EventLogCQ(); + } + + public HpSpecification specify() { + assertSpecifyPurpose(); + if (_specification == null) { + _specification = new HpSpecification(); + } + return _specification; + } + + protected void assertQueryPurpose() { + // TODO + } + + protected void assertSpecifyPurpose() { + // TODO + } + + public static class HpSpecification { + private List columnList = new ArrayList<>(); + + private void doColumn(String name) { + columnList.add(name); + } + + public void columnCreatedAt() { + doColumn("createdAt"); + } + + public void columnCreatedBy() { + doColumn("createdBy"); + } + + public void columnEventType() { + doColumn("eventType"); + } + + public void columnId() { + doColumn("id"); + } + + public void columnMessage() { + doColumn("message"); + } + + public void columnPath() { + doColumn("path"); + } + } +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/bs/BsGroupCB.java b/src/main/java/org/codelibs/fess/es/cbean/bs/BsGroupCB.java new file mode 100644 index 000000000..8014ab647 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/bs/BsGroupCB.java @@ -0,0 +1,134 @@ +package org.codelibs.fess.es.cbean.bs; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +import org.codelibs.fess.es.bsentity.dbmeta.GroupDbm; +import org.codelibs.fess.es.cbean.GroupCB; +import org.codelibs.fess.es.cbean.cq.GroupCQ; +import org.codelibs.fess.es.cbean.cq.bs.BsGroupCQ; +import org.dbflute.cbean.ConditionQuery; +import org.elasticsearch.action.count.CountRequestBuilder; +import org.elasticsearch.action.search.SearchRequestBuilder; +import org.elasticsearch.index.query.QueryBuilder; + +/** + * @author FreeGen + */ +public class BsGroupCB extends AbstractConditionBean { + + protected BsGroupCQ _conditionQuery; + + protected HpSpecification _specification; + + @Override + public GroupDbm asDBMeta() { + return GroupDbm.getInstance(); + } + + @Override + public String asTableDbName() { + return "group"; + } + + @Override + public boolean hasSpecifiedColumn() { + return _specification != null; + } + + @Override + public ConditionQuery localCQ() { + return doGetConditionQuery(); + } + + public GroupCB acceptPK(String id) { + assertObjectNotNull("id", id); + BsGroupCB cb = this; + cb.query().docMeta().setId_Equal(id); + return (GroupCB) this; + } + + @Override + public void acceptPrimaryKeyMap(Map primaryKeyMap) { + acceptPK((String) primaryKeyMap.get("_id")); + } + + @Override + public CountRequestBuilder build(CountRequestBuilder builder) { + if (_conditionQuery != null) { + QueryBuilder queryBuilder = _conditionQuery.getQuery(); + if (queryBuilder != null) { + builder.setQuery(queryBuilder); + } + } + return builder; + } + + @Override + public SearchRequestBuilder build(SearchRequestBuilder builder) { + if (_conditionQuery != null) { + QueryBuilder queryBuilder = _conditionQuery.getQuery(); + if (queryBuilder != null) { + builder.setQuery(queryBuilder); + } + _conditionQuery.getFieldSortBuilderList().forEach(sort -> { + builder.addSort(sort); + }); + } + + if (_specification != null) { + builder.setFetchSource(_specification.columnList.toArray(new String[_specification.columnList.size()]), null); + } + + return builder; + } + + public BsGroupCQ query() { + assertQueryPurpose(); + return doGetConditionQuery(); + } + + protected BsGroupCQ doGetConditionQuery() { + if (_conditionQuery == null) { + _conditionQuery = createLocalCQ(); + } + return _conditionQuery; + } + + protected BsGroupCQ createLocalCQ() { + return new GroupCQ(); + } + + public HpSpecification specify() { + assertSpecifyPurpose(); + if (_specification == null) { + _specification = new HpSpecification(); + } + return _specification; + } + + protected void assertQueryPurpose() { + // TODO + } + + protected void assertSpecifyPurpose() { + // TODO + } + + public static class HpSpecification { + private List columnList = new ArrayList<>(); + + private void doColumn(String name) { + columnList.add(name); + } + + public void columnId() { + doColumn("id"); + } + + public void columnName() { + doColumn("name"); + } + } +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/bs/BsRoleCB.java b/src/main/java/org/codelibs/fess/es/cbean/bs/BsRoleCB.java new file mode 100644 index 000000000..0544f579e --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/bs/BsRoleCB.java @@ -0,0 +1,134 @@ +package org.codelibs.fess.es.cbean.bs; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +import org.codelibs.fess.es.bsentity.dbmeta.RoleDbm; +import org.codelibs.fess.es.cbean.RoleCB; +import org.codelibs.fess.es.cbean.cq.RoleCQ; +import org.codelibs.fess.es.cbean.cq.bs.BsRoleCQ; +import org.dbflute.cbean.ConditionQuery; +import org.elasticsearch.action.count.CountRequestBuilder; +import org.elasticsearch.action.search.SearchRequestBuilder; +import org.elasticsearch.index.query.QueryBuilder; + +/** + * @author FreeGen + */ +public class BsRoleCB extends AbstractConditionBean { + + protected BsRoleCQ _conditionQuery; + + protected HpSpecification _specification; + + @Override + public RoleDbm asDBMeta() { + return RoleDbm.getInstance(); + } + + @Override + public String asTableDbName() { + return "role"; + } + + @Override + public boolean hasSpecifiedColumn() { + return _specification != null; + } + + @Override + public ConditionQuery localCQ() { + return doGetConditionQuery(); + } + + public RoleCB acceptPK(String id) { + assertObjectNotNull("id", id); + BsRoleCB cb = this; + cb.query().docMeta().setId_Equal(id); + return (RoleCB) this; + } + + @Override + public void acceptPrimaryKeyMap(Map primaryKeyMap) { + acceptPK((String) primaryKeyMap.get("_id")); + } + + @Override + public CountRequestBuilder build(CountRequestBuilder builder) { + if (_conditionQuery != null) { + QueryBuilder queryBuilder = _conditionQuery.getQuery(); + if (queryBuilder != null) { + builder.setQuery(queryBuilder); + } + } + return builder; + } + + @Override + public SearchRequestBuilder build(SearchRequestBuilder builder) { + if (_conditionQuery != null) { + QueryBuilder queryBuilder = _conditionQuery.getQuery(); + if (queryBuilder != null) { + builder.setQuery(queryBuilder); + } + _conditionQuery.getFieldSortBuilderList().forEach(sort -> { + builder.addSort(sort); + }); + } + + if (_specification != null) { + builder.setFetchSource(_specification.columnList.toArray(new String[_specification.columnList.size()]), null); + } + + return builder; + } + + public BsRoleCQ query() { + assertQueryPurpose(); + return doGetConditionQuery(); + } + + protected BsRoleCQ doGetConditionQuery() { + if (_conditionQuery == null) { + _conditionQuery = createLocalCQ(); + } + return _conditionQuery; + } + + protected BsRoleCQ createLocalCQ() { + return new RoleCQ(); + } + + public HpSpecification specify() { + assertSpecifyPurpose(); + if (_specification == null) { + _specification = new HpSpecification(); + } + return _specification; + } + + protected void assertQueryPurpose() { + // TODO + } + + protected void assertSpecifyPurpose() { + // TODO + } + + public static class HpSpecification { + private List columnList = new ArrayList<>(); + + private void doColumn(String name) { + columnList.add(name); + } + + public void columnId() { + doColumn("id"); + } + + public void columnName() { + doColumn("name"); + } + } +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/bs/BsUserCB.java b/src/main/java/org/codelibs/fess/es/cbean/bs/BsUserCB.java new file mode 100644 index 000000000..3cca8c18f --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/bs/BsUserCB.java @@ -0,0 +1,146 @@ +package org.codelibs.fess.es.cbean.bs; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +import org.codelibs.fess.es.bsentity.dbmeta.UserDbm; +import org.codelibs.fess.es.cbean.UserCB; +import org.codelibs.fess.es.cbean.cq.UserCQ; +import org.codelibs.fess.es.cbean.cq.bs.BsUserCQ; +import org.dbflute.cbean.ConditionQuery; +import org.elasticsearch.action.count.CountRequestBuilder; +import org.elasticsearch.action.search.SearchRequestBuilder; +import org.elasticsearch.index.query.QueryBuilder; + +/** + * @author FreeGen + */ +public class BsUserCB extends AbstractConditionBean { + + protected BsUserCQ _conditionQuery; + + protected HpSpecification _specification; + + @Override + public UserDbm asDBMeta() { + return UserDbm.getInstance(); + } + + @Override + public String asTableDbName() { + return "user"; + } + + @Override + public boolean hasSpecifiedColumn() { + return _specification != null; + } + + @Override + public ConditionQuery localCQ() { + return doGetConditionQuery(); + } + + public UserCB acceptPK(String id) { + assertObjectNotNull("id", id); + BsUserCB cb = this; + cb.query().docMeta().setId_Equal(id); + return (UserCB) this; + } + + @Override + public void acceptPrimaryKeyMap(Map primaryKeyMap) { + acceptPK((String) primaryKeyMap.get("_id")); + } + + @Override + public CountRequestBuilder build(CountRequestBuilder builder) { + if (_conditionQuery != null) { + QueryBuilder queryBuilder = _conditionQuery.getQuery(); + if (queryBuilder != null) { + builder.setQuery(queryBuilder); + } + } + return builder; + } + + @Override + public SearchRequestBuilder build(SearchRequestBuilder builder) { + if (_conditionQuery != null) { + QueryBuilder queryBuilder = _conditionQuery.getQuery(); + if (queryBuilder != null) { + builder.setQuery(queryBuilder); + } + _conditionQuery.getFieldSortBuilderList().forEach(sort -> { + builder.addSort(sort); + }); + } + + if (_specification != null) { + builder.setFetchSource(_specification.columnList.toArray(new String[_specification.columnList.size()]), null); + } + + return builder; + } + + public BsUserCQ query() { + assertQueryPurpose(); + return doGetConditionQuery(); + } + + protected BsUserCQ doGetConditionQuery() { + if (_conditionQuery == null) { + _conditionQuery = createLocalCQ(); + } + return _conditionQuery; + } + + protected BsUserCQ createLocalCQ() { + return new UserCQ(); + } + + public HpSpecification specify() { + assertSpecifyPurpose(); + if (_specification == null) { + _specification = new HpSpecification(); + } + return _specification; + } + + protected void assertQueryPurpose() { + // TODO + } + + protected void assertSpecifyPurpose() { + // TODO + } + + public static class HpSpecification { + private List columnList = new ArrayList<>(); + + private void doColumn(String name) { + columnList.add(name); + } + + public void columnGroups() { + doColumn("groups"); + } + + public void columnId() { + doColumn("id"); + } + + public void columnName() { + doColumn("name"); + } + + public void columnPassword() { + doColumn("password"); + } + + public void columnRoles() { + doColumn("roles"); + } + } +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/EventLogCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/EventLogCF.java new file mode 100644 index 000000000..2a31fb914 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/EventLogCF.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean.cf; + +import org.codelibs.fess.es.cbean.cf.bs.BsEventLogCF; + +/** + * @author FreeGen + */ +public class EventLogCF extends BsEventLogCF { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/GroupCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/GroupCF.java new file mode 100644 index 000000000..a3978d802 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/GroupCF.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean.cf; + +import org.codelibs.fess.es.cbean.cf.bs.BsGroupCF; + +/** + * @author FreeGen + */ +public class GroupCF extends BsGroupCF { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/RoleCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/RoleCF.java new file mode 100644 index 000000000..fe5354150 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/RoleCF.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean.cf; + +import org.codelibs.fess.es.cbean.cf.bs.BsRoleCF; + +/** + * @author FreeGen + */ +public class RoleCF extends BsRoleCF { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/UserCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/UserCF.java new file mode 100644 index 000000000..125864549 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/UserCF.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean.cf; + +import org.codelibs.fess.es.cbean.cf.bs.BsUserCF; + +/** + * @author FreeGen + */ +public class UserCF extends BsUserCF { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsBoostDocumentRuleCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsBoostDocumentRuleCF.java index 72e17d892..f7e0e3ad8 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsBoostDocumentRuleCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsBoostDocumentRuleCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.BoostDocumentRuleCF; import org.codelibs.fess.es.cbean.cq.BoostDocumentRuleCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsClickLogCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsClickLogCF.java index 308f9a9d4..2e5720a09 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsClickLogCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsClickLogCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.ClickLogCF; import org.codelibs.fess.es.cbean.cq.ClickLogCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsCrawlingSessionCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsCrawlingSessionCF.java index 7f2a00fda..f05c64b7a 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsCrawlingSessionCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsCrawlingSessionCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.CrawlingSessionCF; import org.codelibs.fess.es.cbean.cq.CrawlingSessionCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsCrawlingSessionInfoCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsCrawlingSessionInfoCF.java index 91e91a98c..ae383bbd0 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsCrawlingSessionInfoCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsCrawlingSessionInfoCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.CrawlingSessionInfoCF; import org.codelibs.fess.es.cbean.cq.CrawlingSessionInfoCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigCF.java index 7716cd0d9..636800b8e 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.DataConfigCF; import org.codelibs.fess.es.cbean.cq.DataConfigCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigToLabelCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigToLabelCF.java index b4fa132e9..56e436b4c 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigToLabelCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigToLabelCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.DataConfigToLabelCF; import org.codelibs.fess.es.cbean.cq.DataConfigToLabelCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigToRoleCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigToRoleCF.java index 2b99e9dd5..0f385fb1b 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigToRoleCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsDataConfigToRoleCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.DataConfigToRoleCF; import org.codelibs.fess.es.cbean.cq.DataConfigToRoleCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsEventLogCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsEventLogCF.java new file mode 100644 index 000000000..228539567 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsEventLogCF.java @@ -0,0 +1,855 @@ +package org.codelibs.fess.es.cbean.cf.bs; + +import java.time.LocalDateTime; +import java.util.Collection; + +import org.codelibs.fess.es.cbean.cf.EventLogCF; +import org.codelibs.fess.es.cbean.cq.EventLogCQ; +import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; +import org.elasticsearch.index.query.AndFilterBuilder; +import org.elasticsearch.index.query.BoolFilterBuilder; +import org.elasticsearch.index.query.ExistsFilterBuilder; +import org.elasticsearch.index.query.MissingFilterBuilder; +import org.elasticsearch.index.query.NotFilterBuilder; +import org.elasticsearch.index.query.OrFilterBuilder; +import org.elasticsearch.index.query.PrefixFilterBuilder; +import org.elasticsearch.index.query.QueryFilterBuilder; +import org.elasticsearch.index.query.RangeFilterBuilder; +import org.elasticsearch.index.query.TermFilterBuilder; +import org.elasticsearch.index.query.TermsFilterBuilder; + +/** + * @author FreeGen + */ +public abstract class BsEventLogCF extends AbstractConditionFilter { + + public void bool(BoolCall boolLambda) { + bool(boolLambda, null); + } + + public void bool(BoolCall boolLambda, ConditionOptionCall opLambda) { + EventLogCF mustFilter = new EventLogCF(); + EventLogCF shouldFilter = new EventLogCF(); + EventLogCF mustNotFilter = new EventLogCF(); + boolLambda.callback(mustFilter, shouldFilter, mustNotFilter); + if (mustFilter.hasFilters() || shouldFilter.hasFilters() || mustNotFilter.hasFilters()) { + BoolFilterBuilder builder = + regBoolF(mustFilter.filterBuilderList, shouldFilter.filterBuilderList, mustNotFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void and(OperatorCall andLambda) { + and(andLambda, null); + } + + public void and(OperatorCall andLambda, ConditionOptionCall opLambda) { + EventLogCF andFilter = new EventLogCF(); + andLambda.callback(andFilter); + if (andFilter.hasFilters()) { + AndFilterBuilder builder = regAndF(andFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void or(OperatorCall orLambda) { + or(orLambda, null); + } + + public void or(OperatorCall orLambda, ConditionOptionCall opLambda) { + EventLogCF orFilter = new EventLogCF(); + orLambda.callback(orFilter); + if (orFilter.hasFilters()) { + OrFilterBuilder builder = regOrF(orFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void not(OperatorCall notLambda) { + not(notLambda, null); + } + + public void not(OperatorCall notLambda, ConditionOptionCall opLambda) { + EventLogCF notFilter = new EventLogCF(); + notLambda.callback(notFilter); + if (notFilter.hasFilters()) { + if (notFilter.filterBuilderList.size() > 1) { + final String msg = "not filter must be one filter."; + throw new IllegalConditionBeanOperationException(msg); + } + NotFilterBuilder builder = regNotF(notFilter.filterBuilderList.get(0)); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall queryLambda) { + query(queryLambda, null); + } + + public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall queryLambda, + ConditionOptionCall opLambda) { + EventLogCQ query = new EventLogCQ(); + queryLambda.callback(query); + if (query.hasQueries()) { + QueryFilterBuilder builder = regQueryF(query.getQuery()); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void setCreatedAt_NotEqual(LocalDateTime createdAt) { + setCreatedAt_NotEqual(createdAt, null, null); + } + + public void setCreatedAt_NotEqual(LocalDateTime createdAt, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setCreatedAt_Equal(createdAt, eqOpLambda); + }, notOpLambda); + } + + public void setCreatedAt_Equal(LocalDateTime createdAt) { + setCreatedAt_Term(createdAt, null); + } + + public void setCreatedAt_Equal(LocalDateTime createdAt, ConditionOptionCall opLambda) { + setCreatedAt_Term(createdAt, opLambda); + } + + public void setCreatedAt_Term(LocalDateTime createdAt) { + setCreatedAt_Term(createdAt, null); + } + + public void setCreatedAt_Term(LocalDateTime createdAt, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("createdAt", createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_Terms(Collection createdAtList) { + setCreatedAt_Terms(createdAtList, null); + } + + public void setCreatedAt_Terms(Collection createdAtList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("createdAt", createdAtList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_InScope(Collection createdAtList) { + setCreatedAt_Terms(createdAtList, null); + } + + public void setCreatedAt_InScope(Collection createdAtList, ConditionOptionCall opLambda) { + setCreatedAt_Terms(createdAtList, opLambda); + } + + public void setCreatedAt_Exists() { + setCreatedAt_Exists(null); + } + + public void setCreatedAt_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("createdAt"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_Missing() { + setCreatedAt_Missing(null); + } + + public void setCreatedAt_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("createdAt"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_GreaterThan(LocalDateTime createdAt) { + setCreatedAt_GreaterThan(createdAt, null); + } + + public void setCreatedAt_GreaterThan(LocalDateTime createdAt, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("createdAt", ConditionKey.CK_GREATER_THAN, createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_LessThan(LocalDateTime createdAt) { + setCreatedAt_LessThan(createdAt, null); + } + + public void setCreatedAt_LessThan(LocalDateTime createdAt, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("createdAt", ConditionKey.CK_LESS_THAN, createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_GreaterEqual(LocalDateTime createdAt) { + setCreatedAt_GreaterEqual(createdAt, null); + } + + public void setCreatedAt_GreaterEqual(LocalDateTime createdAt, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("createdAt", ConditionKey.CK_GREATER_EQUAL, createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_LessEqual(LocalDateTime createdAt) { + setCreatedAt_LessEqual(createdAt, null); + } + + public void setCreatedAt_LessEqual(LocalDateTime createdAt, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("createdAt", ConditionKey.CK_LESS_EQUAL, createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_NotEqual(String createdBy) { + setCreatedBy_NotEqual(createdBy, null, null); + } + + public void setCreatedBy_NotEqual(String createdBy, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setCreatedBy_Equal(createdBy, eqOpLambda); + }, notOpLambda); + } + + public void setCreatedBy_Equal(String createdBy) { + setCreatedBy_Term(createdBy, null); + } + + public void setCreatedBy_Equal(String createdBy, ConditionOptionCall opLambda) { + setCreatedBy_Term(createdBy, opLambda); + } + + public void setCreatedBy_Term(String createdBy) { + setCreatedBy_Term(createdBy, null); + } + + public void setCreatedBy_Term(String createdBy, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("createdBy", createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_Terms(Collection createdByList) { + setCreatedBy_Terms(createdByList, null); + } + + public void setCreatedBy_Terms(Collection createdByList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("createdBy", createdByList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_InScope(Collection createdByList) { + setCreatedBy_Terms(createdByList, null); + } + + public void setCreatedBy_InScope(Collection createdByList, ConditionOptionCall opLambda) { + setCreatedBy_Terms(createdByList, opLambda); + } + + public void setCreatedBy_Prefix(String createdBy) { + setCreatedBy_Prefix(createdBy, null); + } + + public void setCreatedBy_Prefix(String createdBy, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("createdBy", createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_Exists() { + setCreatedBy_Exists(null); + } + + public void setCreatedBy_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("createdBy"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_Missing() { + setCreatedBy_Missing(null); + } + + public void setCreatedBy_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("createdBy"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_GreaterThan(String createdBy) { + setCreatedBy_GreaterThan(createdBy, null); + } + + public void setCreatedBy_GreaterThan(String createdBy, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("createdBy", ConditionKey.CK_GREATER_THAN, createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_LessThan(String createdBy) { + setCreatedBy_LessThan(createdBy, null); + } + + public void setCreatedBy_LessThan(String createdBy, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("createdBy", ConditionKey.CK_LESS_THAN, createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_GreaterEqual(String createdBy) { + setCreatedBy_GreaterEqual(createdBy, null); + } + + public void setCreatedBy_GreaterEqual(String createdBy, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("createdBy", ConditionKey.CK_GREATER_EQUAL, createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_LessEqual(String createdBy) { + setCreatedBy_LessEqual(createdBy, null); + } + + public void setCreatedBy_LessEqual(String createdBy, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("createdBy", ConditionKey.CK_LESS_EQUAL, createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_NotEqual(String eventType) { + setEventType_NotEqual(eventType, null, null); + } + + public void setEventType_NotEqual(String eventType, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setEventType_Equal(eventType, eqOpLambda); + }, notOpLambda); + } + + public void setEventType_Equal(String eventType) { + setEventType_Term(eventType, null); + } + + public void setEventType_Equal(String eventType, ConditionOptionCall opLambda) { + setEventType_Term(eventType, opLambda); + } + + public void setEventType_Term(String eventType) { + setEventType_Term(eventType, null); + } + + public void setEventType_Term(String eventType, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("eventType", eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_Terms(Collection eventTypeList) { + setEventType_Terms(eventTypeList, null); + } + + public void setEventType_Terms(Collection eventTypeList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("eventType", eventTypeList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_InScope(Collection eventTypeList) { + setEventType_Terms(eventTypeList, null); + } + + public void setEventType_InScope(Collection eventTypeList, ConditionOptionCall opLambda) { + setEventType_Terms(eventTypeList, opLambda); + } + + public void setEventType_Prefix(String eventType) { + setEventType_Prefix(eventType, null); + } + + public void setEventType_Prefix(String eventType, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("eventType", eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_Exists() { + setEventType_Exists(null); + } + + public void setEventType_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("eventType"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_Missing() { + setEventType_Missing(null); + } + + public void setEventType_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("eventType"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_GreaterThan(String eventType) { + setEventType_GreaterThan(eventType, null); + } + + public void setEventType_GreaterThan(String eventType, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("eventType", ConditionKey.CK_GREATER_THAN, eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_LessThan(String eventType) { + setEventType_LessThan(eventType, null); + } + + public void setEventType_LessThan(String eventType, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("eventType", ConditionKey.CK_LESS_THAN, eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_GreaterEqual(String eventType) { + setEventType_GreaterEqual(eventType, null); + } + + public void setEventType_GreaterEqual(String eventType, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("eventType", ConditionKey.CK_GREATER_EQUAL, eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_LessEqual(String eventType) { + setEventType_LessEqual(eventType, null); + } + + public void setEventType_LessEqual(String eventType, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("eventType", ConditionKey.CK_LESS_EQUAL, eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_NotEqual(String id) { + setId_NotEqual(id, null, null); + } + + public void setId_NotEqual(String id, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setId_Equal(id, eqOpLambda); + }, notOpLambda); + } + + public void setId_Equal(String id) { + setId_Term(id, null); + } + + public void setId_Equal(String id, ConditionOptionCall opLambda) { + setId_Term(id, opLambda); + } + + public void setId_Term(String id) { + setId_Term(id, null); + } + + public void setId_Term(String id, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Terms(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_Terms(Collection idList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("id", idList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_InScope(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_InScope(Collection idList, ConditionOptionCall opLambda) { + setId_Terms(idList, opLambda); + } + + public void setId_Prefix(String id) { + setId_Prefix(id, null); + } + + public void setId_Prefix(String id, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Exists() { + setId_Exists(null); + } + + public void setId_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("id"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Missing() { + setId_Missing(null); + } + + public void setId_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("id"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterThan(String id) { + setId_GreaterThan(id, null); + } + + public void setId_GreaterThan(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_GREATER_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessThan(String id) { + setId_LessThan(id, null); + } + + public void setId_LessThan(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_LESS_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterEqual(String id) { + setId_GreaterEqual(id, null); + } + + public void setId_GreaterEqual(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_GREATER_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessEqual(String id) { + setId_LessEqual(id, null); + } + + public void setId_LessEqual(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_LESS_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_NotEqual(String message) { + setMessage_NotEqual(message, null, null); + } + + public void setMessage_NotEqual(String message, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setMessage_Equal(message, eqOpLambda); + }, notOpLambda); + } + + public void setMessage_Equal(String message) { + setMessage_Term(message, null); + } + + public void setMessage_Equal(String message, ConditionOptionCall opLambda) { + setMessage_Term(message, opLambda); + } + + public void setMessage_Term(String message) { + setMessage_Term(message, null); + } + + public void setMessage_Term(String message, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("message", message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_Terms(Collection messageList) { + setMessage_Terms(messageList, null); + } + + public void setMessage_Terms(Collection messageList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("message", messageList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_InScope(Collection messageList) { + setMessage_Terms(messageList, null); + } + + public void setMessage_InScope(Collection messageList, ConditionOptionCall opLambda) { + setMessage_Terms(messageList, opLambda); + } + + public void setMessage_Prefix(String message) { + setMessage_Prefix(message, null); + } + + public void setMessage_Prefix(String message, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("message", message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_Exists() { + setMessage_Exists(null); + } + + public void setMessage_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("message"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_Missing() { + setMessage_Missing(null); + } + + public void setMessage_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("message"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_GreaterThan(String message) { + setMessage_GreaterThan(message, null); + } + + public void setMessage_GreaterThan(String message, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("message", ConditionKey.CK_GREATER_THAN, message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_LessThan(String message) { + setMessage_LessThan(message, null); + } + + public void setMessage_LessThan(String message, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("message", ConditionKey.CK_LESS_THAN, message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_GreaterEqual(String message) { + setMessage_GreaterEqual(message, null); + } + + public void setMessage_GreaterEqual(String message, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("message", ConditionKey.CK_GREATER_EQUAL, message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_LessEqual(String message) { + setMessage_LessEqual(message, null); + } + + public void setMessage_LessEqual(String message, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("message", ConditionKey.CK_LESS_EQUAL, message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_NotEqual(String path) { + setPath_NotEqual(path, null, null); + } + + public void setPath_NotEqual(String path, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setPath_Equal(path, eqOpLambda); + }, notOpLambda); + } + + public void setPath_Equal(String path) { + setPath_Term(path, null); + } + + public void setPath_Equal(String path, ConditionOptionCall opLambda) { + setPath_Term(path, opLambda); + } + + public void setPath_Term(String path) { + setPath_Term(path, null); + } + + public void setPath_Term(String path, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("path", path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_Terms(Collection pathList) { + setPath_Terms(pathList, null); + } + + public void setPath_Terms(Collection pathList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("path", pathList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_InScope(Collection pathList) { + setPath_Terms(pathList, null); + } + + public void setPath_InScope(Collection pathList, ConditionOptionCall opLambda) { + setPath_Terms(pathList, opLambda); + } + + public void setPath_Prefix(String path) { + setPath_Prefix(path, null); + } + + public void setPath_Prefix(String path, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("path", path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_Exists() { + setPath_Exists(null); + } + + public void setPath_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("path"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_Missing() { + setPath_Missing(null); + } + + public void setPath_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("path"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_GreaterThan(String path) { + setPath_GreaterThan(path, null); + } + + public void setPath_GreaterThan(String path, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("path", ConditionKey.CK_GREATER_THAN, path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_LessThan(String path) { + setPath_LessThan(path, null); + } + + public void setPath_LessThan(String path, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("path", ConditionKey.CK_LESS_THAN, path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_GreaterEqual(String path) { + setPath_GreaterEqual(path, null); + } + + public void setPath_GreaterEqual(String path, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("path", ConditionKey.CK_GREATER_EQUAL, path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_LessEqual(String path) { + setPath_LessEqual(path, null); + } + + public void setPath_LessEqual(String path, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("path", ConditionKey.CK_LESS_EQUAL, path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFailureUrlCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFailureUrlCF.java index 7b0869d95..a482f0034 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFailureUrlCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFailureUrlCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.FailureUrlCF; import org.codelibs.fess.es.cbean.cq.FailureUrlCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFavoriteLogCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFavoriteLogCF.java index b3dfb54e5..833251a93 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFavoriteLogCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFavoriteLogCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.FavoriteLogCF; import org.codelibs.fess.es.cbean.cq.FavoriteLogCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileAuthenticationCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileAuthenticationCF.java index 35daa55fc..73bc06e01 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileAuthenticationCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileAuthenticationCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.FileAuthenticationCF; import org.codelibs.fess.es.cbean.cq.FileAuthenticationCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigCF.java index ac1738d70..9ee94d27b 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.FileConfigCF; import org.codelibs.fess.es.cbean.cq.FileConfigCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigToLabelCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigToLabelCF.java index 603762d49..349f00f5f 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigToLabelCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigToLabelCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.FileConfigToLabelCF; import org.codelibs.fess.es.cbean.cq.FileConfigToLabelCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigToRoleCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigToRoleCF.java index c302bc866..bde88fa91 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigToRoleCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsFileConfigToRoleCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.FileConfigToRoleCF; import org.codelibs.fess.es.cbean.cq.FileConfigToRoleCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsGroupCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsGroupCF.java new file mode 100644 index 000000000..5aae8cc62 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsGroupCF.java @@ -0,0 +1,361 @@ +package org.codelibs.fess.es.cbean.cf.bs; + +import java.util.Collection; + +import org.codelibs.fess.es.cbean.cf.GroupCF; +import org.codelibs.fess.es.cbean.cq.GroupCQ; +import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; +import org.elasticsearch.index.query.AndFilterBuilder; +import org.elasticsearch.index.query.BoolFilterBuilder; +import org.elasticsearch.index.query.ExistsFilterBuilder; +import org.elasticsearch.index.query.MissingFilterBuilder; +import org.elasticsearch.index.query.NotFilterBuilder; +import org.elasticsearch.index.query.OrFilterBuilder; +import org.elasticsearch.index.query.PrefixFilterBuilder; +import org.elasticsearch.index.query.QueryFilterBuilder; +import org.elasticsearch.index.query.RangeFilterBuilder; +import org.elasticsearch.index.query.TermFilterBuilder; +import org.elasticsearch.index.query.TermsFilterBuilder; + +/** + * @author FreeGen + */ +public abstract class BsGroupCF extends AbstractConditionFilter { + + public void bool(BoolCall boolLambda) { + bool(boolLambda, null); + } + + public void bool(BoolCall boolLambda, ConditionOptionCall opLambda) { + GroupCF mustFilter = new GroupCF(); + GroupCF shouldFilter = new GroupCF(); + GroupCF mustNotFilter = new GroupCF(); + boolLambda.callback(mustFilter, shouldFilter, mustNotFilter); + if (mustFilter.hasFilters() || shouldFilter.hasFilters() || mustNotFilter.hasFilters()) { + BoolFilterBuilder builder = + regBoolF(mustFilter.filterBuilderList, shouldFilter.filterBuilderList, mustNotFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void and(OperatorCall andLambda) { + and(andLambda, null); + } + + public void and(OperatorCall andLambda, ConditionOptionCall opLambda) { + GroupCF andFilter = new GroupCF(); + andLambda.callback(andFilter); + if (andFilter.hasFilters()) { + AndFilterBuilder builder = regAndF(andFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void or(OperatorCall orLambda) { + or(orLambda, null); + } + + public void or(OperatorCall orLambda, ConditionOptionCall opLambda) { + GroupCF orFilter = new GroupCF(); + orLambda.callback(orFilter); + if (orFilter.hasFilters()) { + OrFilterBuilder builder = regOrF(orFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void not(OperatorCall notLambda) { + not(notLambda, null); + } + + public void not(OperatorCall notLambda, ConditionOptionCall opLambda) { + GroupCF notFilter = new GroupCF(); + notLambda.callback(notFilter); + if (notFilter.hasFilters()) { + if (notFilter.filterBuilderList.size() > 1) { + final String msg = "not filter must be one filter."; + throw new IllegalConditionBeanOperationException(msg); + } + NotFilterBuilder builder = regNotF(notFilter.filterBuilderList.get(0)); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall queryLambda) { + query(queryLambda, null); + } + + public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall queryLambda, + ConditionOptionCall opLambda) { + GroupCQ query = new GroupCQ(); + queryLambda.callback(query); + if (query.hasQueries()) { + QueryFilterBuilder builder = regQueryF(query.getQuery()); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void setId_NotEqual(String id) { + setId_NotEqual(id, null, null); + } + + public void setId_NotEqual(String id, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setId_Equal(id, eqOpLambda); + }, notOpLambda); + } + + public void setId_Equal(String id) { + setId_Term(id, null); + } + + public void setId_Equal(String id, ConditionOptionCall opLambda) { + setId_Term(id, opLambda); + } + + public void setId_Term(String id) { + setId_Term(id, null); + } + + public void setId_Term(String id, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Terms(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_Terms(Collection idList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("id", idList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_InScope(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_InScope(Collection idList, ConditionOptionCall opLambda) { + setId_Terms(idList, opLambda); + } + + public void setId_Prefix(String id) { + setId_Prefix(id, null); + } + + public void setId_Prefix(String id, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Exists() { + setId_Exists(null); + } + + public void setId_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("id"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Missing() { + setId_Missing(null); + } + + public void setId_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("id"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterThan(String id) { + setId_GreaterThan(id, null); + } + + public void setId_GreaterThan(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_GREATER_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessThan(String id) { + setId_LessThan(id, null); + } + + public void setId_LessThan(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_LESS_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterEqual(String id) { + setId_GreaterEqual(id, null); + } + + public void setId_GreaterEqual(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_GREATER_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessEqual(String id) { + setId_LessEqual(id, null); + } + + public void setId_LessEqual(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_LESS_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_NotEqual(String name) { + setName_NotEqual(name, null, null); + } + + public void setName_NotEqual(String name, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setName_Equal(name, eqOpLambda); + }, notOpLambda); + } + + public void setName_Equal(String name) { + setName_Term(name, null); + } + + public void setName_Equal(String name, ConditionOptionCall opLambda) { + setName_Term(name, opLambda); + } + + public void setName_Term(String name) { + setName_Term(name, null); + } + + public void setName_Term(String name, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Terms(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_Terms(Collection nameList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("name", nameList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_InScope(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_InScope(Collection nameList, ConditionOptionCall opLambda) { + setName_Terms(nameList, opLambda); + } + + public void setName_Prefix(String name) { + setName_Prefix(name, null); + } + + public void setName_Prefix(String name, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Exists() { + setName_Exists(null); + } + + public void setName_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("name"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Missing() { + setName_Missing(null); + } + + public void setName_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("name"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterThan(String name) { + setName_GreaterThan(name, null); + } + + public void setName_GreaterThan(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_GREATER_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessThan(String name) { + setName_LessThan(name, null); + } + + public void setName_LessThan(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_LESS_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterEqual(String name) { + setName_GreaterEqual(name, null); + } + + public void setName_GreaterEqual(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_GREATER_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessEqual(String name) { + setName_LessEqual(name, null); + } + + public void setName_LessEqual(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_LESS_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsJobLogCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsJobLogCF.java index bfced1aac..2b1a001a0 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsJobLogCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsJobLogCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.JobLogCF; import org.codelibs.fess.es.cbean.cq.JobLogCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsKeyMatchCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsKeyMatchCF.java index a1a60409c..985a8b720 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsKeyMatchCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsKeyMatchCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.KeyMatchCF; import org.codelibs.fess.es.cbean.cq.KeyMatchCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsLabelToRoleCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsLabelToRoleCF.java index 8f796fd01..5789df6f6 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsLabelToRoleCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsLabelToRoleCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.LabelToRoleCF; import org.codelibs.fess.es.cbean.cq.LabelToRoleCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsLabelTypeCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsLabelTypeCF.java index 841a3c193..ce4ca0470 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsLabelTypeCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsLabelTypeCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.LabelTypeCF; import org.codelibs.fess.es.cbean.cq.LabelTypeCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsOverlappingHostCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsOverlappingHostCF.java index bff80c2c8..f652b6389 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsOverlappingHostCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsOverlappingHostCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.OverlappingHostCF; import org.codelibs.fess.es.cbean.cq.OverlappingHostCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsPathMappingCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsPathMappingCF.java index 713183700..a77e8ed1f 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsPathMappingCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsPathMappingCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.PathMappingCF; import org.codelibs.fess.es.cbean.cq.PathMappingCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRequestHeaderCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRequestHeaderCF.java index 376c00b5e..f1b9b4256 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRequestHeaderCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRequestHeaderCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.RequestHeaderCF; import org.codelibs.fess.es.cbean.cq.RequestHeaderCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRoleCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRoleCF.java new file mode 100644 index 000000000..f183c5c77 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRoleCF.java @@ -0,0 +1,361 @@ +package org.codelibs.fess.es.cbean.cf.bs; + +import java.util.Collection; + +import org.codelibs.fess.es.cbean.cf.RoleCF; +import org.codelibs.fess.es.cbean.cq.RoleCQ; +import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; +import org.elasticsearch.index.query.AndFilterBuilder; +import org.elasticsearch.index.query.BoolFilterBuilder; +import org.elasticsearch.index.query.ExistsFilterBuilder; +import org.elasticsearch.index.query.MissingFilterBuilder; +import org.elasticsearch.index.query.NotFilterBuilder; +import org.elasticsearch.index.query.OrFilterBuilder; +import org.elasticsearch.index.query.PrefixFilterBuilder; +import org.elasticsearch.index.query.QueryFilterBuilder; +import org.elasticsearch.index.query.RangeFilterBuilder; +import org.elasticsearch.index.query.TermFilterBuilder; +import org.elasticsearch.index.query.TermsFilterBuilder; + +/** + * @author FreeGen + */ +public abstract class BsRoleCF extends AbstractConditionFilter { + + public void bool(BoolCall boolLambda) { + bool(boolLambda, null); + } + + public void bool(BoolCall boolLambda, ConditionOptionCall opLambda) { + RoleCF mustFilter = new RoleCF(); + RoleCF shouldFilter = new RoleCF(); + RoleCF mustNotFilter = new RoleCF(); + boolLambda.callback(mustFilter, shouldFilter, mustNotFilter); + if (mustFilter.hasFilters() || shouldFilter.hasFilters() || mustNotFilter.hasFilters()) { + BoolFilterBuilder builder = + regBoolF(mustFilter.filterBuilderList, shouldFilter.filterBuilderList, mustNotFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void and(OperatorCall andLambda) { + and(andLambda, null); + } + + public void and(OperatorCall andLambda, ConditionOptionCall opLambda) { + RoleCF andFilter = new RoleCF(); + andLambda.callback(andFilter); + if (andFilter.hasFilters()) { + AndFilterBuilder builder = regAndF(andFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void or(OperatorCall orLambda) { + or(orLambda, null); + } + + public void or(OperatorCall orLambda, ConditionOptionCall opLambda) { + RoleCF orFilter = new RoleCF(); + orLambda.callback(orFilter); + if (orFilter.hasFilters()) { + OrFilterBuilder builder = regOrF(orFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void not(OperatorCall notLambda) { + not(notLambda, null); + } + + public void not(OperatorCall notLambda, ConditionOptionCall opLambda) { + RoleCF notFilter = new RoleCF(); + notLambda.callback(notFilter); + if (notFilter.hasFilters()) { + if (notFilter.filterBuilderList.size() > 1) { + final String msg = "not filter must be one filter."; + throw new IllegalConditionBeanOperationException(msg); + } + NotFilterBuilder builder = regNotF(notFilter.filterBuilderList.get(0)); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall queryLambda) { + query(queryLambda, null); + } + + public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall queryLambda, + ConditionOptionCall opLambda) { + RoleCQ query = new RoleCQ(); + queryLambda.callback(query); + if (query.hasQueries()) { + QueryFilterBuilder builder = regQueryF(query.getQuery()); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void setId_NotEqual(String id) { + setId_NotEqual(id, null, null); + } + + public void setId_NotEqual(String id, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setId_Equal(id, eqOpLambda); + }, notOpLambda); + } + + public void setId_Equal(String id) { + setId_Term(id, null); + } + + public void setId_Equal(String id, ConditionOptionCall opLambda) { + setId_Term(id, opLambda); + } + + public void setId_Term(String id) { + setId_Term(id, null); + } + + public void setId_Term(String id, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Terms(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_Terms(Collection idList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("id", idList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_InScope(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_InScope(Collection idList, ConditionOptionCall opLambda) { + setId_Terms(idList, opLambda); + } + + public void setId_Prefix(String id) { + setId_Prefix(id, null); + } + + public void setId_Prefix(String id, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Exists() { + setId_Exists(null); + } + + public void setId_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("id"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Missing() { + setId_Missing(null); + } + + public void setId_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("id"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterThan(String id) { + setId_GreaterThan(id, null); + } + + public void setId_GreaterThan(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_GREATER_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessThan(String id) { + setId_LessThan(id, null); + } + + public void setId_LessThan(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_LESS_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterEqual(String id) { + setId_GreaterEqual(id, null); + } + + public void setId_GreaterEqual(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_GREATER_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessEqual(String id) { + setId_LessEqual(id, null); + } + + public void setId_LessEqual(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_LESS_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_NotEqual(String name) { + setName_NotEqual(name, null, null); + } + + public void setName_NotEqual(String name, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setName_Equal(name, eqOpLambda); + }, notOpLambda); + } + + public void setName_Equal(String name) { + setName_Term(name, null); + } + + public void setName_Equal(String name, ConditionOptionCall opLambda) { + setName_Term(name, opLambda); + } + + public void setName_Term(String name) { + setName_Term(name, null); + } + + public void setName_Term(String name, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Terms(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_Terms(Collection nameList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("name", nameList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_InScope(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_InScope(Collection nameList, ConditionOptionCall opLambda) { + setName_Terms(nameList, opLambda); + } + + public void setName_Prefix(String name) { + setName_Prefix(name, null); + } + + public void setName_Prefix(String name, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Exists() { + setName_Exists(null); + } + + public void setName_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("name"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Missing() { + setName_Missing(null); + } + + public void setName_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("name"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterThan(String name) { + setName_GreaterThan(name, null); + } + + public void setName_GreaterThan(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_GREATER_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessThan(String name) { + setName_LessThan(name, null); + } + + public void setName_LessThan(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_LESS_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterEqual(String name) { + setName_GreaterEqual(name, null); + } + + public void setName_GreaterEqual(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_GREATER_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessEqual(String name) { + setName_LessEqual(name, null); + } + + public void setName_LessEqual(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_LESS_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRoleTypeCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRoleTypeCF.java index 38f06316d..ab5edd642 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRoleTypeCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRoleTypeCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.RoleTypeCF; import org.codelibs.fess.es.cbean.cq.RoleTypeCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsScheduledJobCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsScheduledJobCF.java index 06f01295e..623beb2e7 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsScheduledJobCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsScheduledJobCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.ScheduledJobCF; import org.codelibs.fess.es.cbean.cq.ScheduledJobCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSearchFieldLogCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSearchFieldLogCF.java index f31022111..05099da47 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSearchFieldLogCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSearchFieldLogCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.SearchFieldLogCF; import org.codelibs.fess.es.cbean.cq.SearchFieldLogCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSearchLogCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSearchLogCF.java index d0c13742f..7e41eac67 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSearchLogCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSearchLogCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.SearchLogCF; import org.codelibs.fess.es.cbean.cq.SearchLogCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSuggestBadWordCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSuggestBadWordCF.java index 03fb9e1ed..f94a53555 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSuggestBadWordCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSuggestBadWordCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.SuggestBadWordCF; import org.codelibs.fess.es.cbean.cq.SuggestBadWordCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSuggestElevateWordCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSuggestElevateWordCF.java index e57fc204a..04e645905 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSuggestElevateWordCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsSuggestElevateWordCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.SuggestElevateWordCF; import org.codelibs.fess.es.cbean.cq.SuggestElevateWordCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsUserCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsUserCF.java new file mode 100644 index 000000000..0166a7042 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsUserCF.java @@ -0,0 +1,739 @@ +package org.codelibs.fess.es.cbean.cf.bs; + +import java.util.Collection; + +import org.codelibs.fess.es.cbean.cf.UserCF; +import org.codelibs.fess.es.cbean.cq.UserCQ; +import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; +import org.elasticsearch.index.query.AndFilterBuilder; +import org.elasticsearch.index.query.BoolFilterBuilder; +import org.elasticsearch.index.query.ExistsFilterBuilder; +import org.elasticsearch.index.query.MissingFilterBuilder; +import org.elasticsearch.index.query.NotFilterBuilder; +import org.elasticsearch.index.query.OrFilterBuilder; +import org.elasticsearch.index.query.PrefixFilterBuilder; +import org.elasticsearch.index.query.QueryFilterBuilder; +import org.elasticsearch.index.query.RangeFilterBuilder; +import org.elasticsearch.index.query.TermFilterBuilder; +import org.elasticsearch.index.query.TermsFilterBuilder; + +/** + * @author FreeGen + */ +public abstract class BsUserCF extends AbstractConditionFilter { + + public void bool(BoolCall boolLambda) { + bool(boolLambda, null); + } + + public void bool(BoolCall boolLambda, ConditionOptionCall opLambda) { + UserCF mustFilter = new UserCF(); + UserCF shouldFilter = new UserCF(); + UserCF mustNotFilter = new UserCF(); + boolLambda.callback(mustFilter, shouldFilter, mustNotFilter); + if (mustFilter.hasFilters() || shouldFilter.hasFilters() || mustNotFilter.hasFilters()) { + BoolFilterBuilder builder = + regBoolF(mustFilter.filterBuilderList, shouldFilter.filterBuilderList, mustNotFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void and(OperatorCall andLambda) { + and(andLambda, null); + } + + public void and(OperatorCall andLambda, ConditionOptionCall opLambda) { + UserCF andFilter = new UserCF(); + andLambda.callback(andFilter); + if (andFilter.hasFilters()) { + AndFilterBuilder builder = regAndF(andFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void or(OperatorCall orLambda) { + or(orLambda, null); + } + + public void or(OperatorCall orLambda, ConditionOptionCall opLambda) { + UserCF orFilter = new UserCF(); + orLambda.callback(orFilter); + if (orFilter.hasFilters()) { + OrFilterBuilder builder = regOrF(orFilter.filterBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void not(OperatorCall notLambda) { + not(notLambda, null); + } + + public void not(OperatorCall notLambda, ConditionOptionCall opLambda) { + UserCF notFilter = new UserCF(); + notLambda.callback(notFilter); + if (notFilter.hasFilters()) { + if (notFilter.filterBuilderList.size() > 1) { + final String msg = "not filter must be one filter."; + throw new IllegalConditionBeanOperationException(msg); + } + NotFilterBuilder builder = regNotF(notFilter.filterBuilderList.get(0)); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall queryLambda) { + query(queryLambda, null); + } + + public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall queryLambda, + ConditionOptionCall opLambda) { + UserCQ query = new UserCQ(); + queryLambda.callback(query); + if (query.hasQueries()) { + QueryFilterBuilder builder = regQueryF(query.getQuery()); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void setGroups_NotEqual(String groups) { + setGroups_NotEqual(groups, null, null); + } + + public void setGroups_NotEqual(String groups, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setGroups_Equal(groups, eqOpLambda); + }, notOpLambda); + } + + public void setGroups_Equal(String groups) { + setGroups_Term(groups, null); + } + + public void setGroups_Equal(String groups, ConditionOptionCall opLambda) { + setGroups_Term(groups, opLambda); + } + + public void setGroups_Term(String groups) { + setGroups_Term(groups, null); + } + + public void setGroups_Term(String groups, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("groups", groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_Terms(Collection groupsList) { + setGroups_Terms(groupsList, null); + } + + public void setGroups_Terms(Collection groupsList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("groups", groupsList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_InScope(Collection groupsList) { + setGroups_Terms(groupsList, null); + } + + public void setGroups_InScope(Collection groupsList, ConditionOptionCall opLambda) { + setGroups_Terms(groupsList, opLambda); + } + + public void setGroups_Prefix(String groups) { + setGroups_Prefix(groups, null); + } + + public void setGroups_Prefix(String groups, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("groups", groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_Exists() { + setGroups_Exists(null); + } + + public void setGroups_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("groups"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_Missing() { + setGroups_Missing(null); + } + + public void setGroups_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("groups"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_GreaterThan(String groups) { + setGroups_GreaterThan(groups, null); + } + + public void setGroups_GreaterThan(String groups, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("groups", ConditionKey.CK_GREATER_THAN, groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_LessThan(String groups) { + setGroups_LessThan(groups, null); + } + + public void setGroups_LessThan(String groups, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("groups", ConditionKey.CK_LESS_THAN, groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_GreaterEqual(String groups) { + setGroups_GreaterEqual(groups, null); + } + + public void setGroups_GreaterEqual(String groups, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("groups", ConditionKey.CK_GREATER_EQUAL, groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_LessEqual(String groups) { + setGroups_LessEqual(groups, null); + } + + public void setGroups_LessEqual(String groups, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("groups", ConditionKey.CK_LESS_EQUAL, groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_NotEqual(String id) { + setId_NotEqual(id, null, null); + } + + public void setId_NotEqual(String id, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setId_Equal(id, eqOpLambda); + }, notOpLambda); + } + + public void setId_Equal(String id) { + setId_Term(id, null); + } + + public void setId_Equal(String id, ConditionOptionCall opLambda) { + setId_Term(id, opLambda); + } + + public void setId_Term(String id) { + setId_Term(id, null); + } + + public void setId_Term(String id, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Terms(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_Terms(Collection idList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("id", idList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_InScope(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_InScope(Collection idList, ConditionOptionCall opLambda) { + setId_Terms(idList, opLambda); + } + + public void setId_Prefix(String id) { + setId_Prefix(id, null); + } + + public void setId_Prefix(String id, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Exists() { + setId_Exists(null); + } + + public void setId_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("id"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Missing() { + setId_Missing(null); + } + + public void setId_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("id"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterThan(String id) { + setId_GreaterThan(id, null); + } + + public void setId_GreaterThan(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_GREATER_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessThan(String id) { + setId_LessThan(id, null); + } + + public void setId_LessThan(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_LESS_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterEqual(String id) { + setId_GreaterEqual(id, null); + } + + public void setId_GreaterEqual(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_GREATER_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessEqual(String id) { + setId_LessEqual(id, null); + } + + public void setId_LessEqual(String id, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("id", ConditionKey.CK_LESS_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_NotEqual(String name) { + setName_NotEqual(name, null, null); + } + + public void setName_NotEqual(String name, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setName_Equal(name, eqOpLambda); + }, notOpLambda); + } + + public void setName_Equal(String name) { + setName_Term(name, null); + } + + public void setName_Equal(String name, ConditionOptionCall opLambda) { + setName_Term(name, opLambda); + } + + public void setName_Term(String name) { + setName_Term(name, null); + } + + public void setName_Term(String name, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Terms(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_Terms(Collection nameList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("name", nameList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_InScope(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_InScope(Collection nameList, ConditionOptionCall opLambda) { + setName_Terms(nameList, opLambda); + } + + public void setName_Prefix(String name) { + setName_Prefix(name, null); + } + + public void setName_Prefix(String name, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Exists() { + setName_Exists(null); + } + + public void setName_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("name"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Missing() { + setName_Missing(null); + } + + public void setName_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("name"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterThan(String name) { + setName_GreaterThan(name, null); + } + + public void setName_GreaterThan(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_GREATER_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessThan(String name) { + setName_LessThan(name, null); + } + + public void setName_LessThan(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_LESS_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterEqual(String name) { + setName_GreaterEqual(name, null); + } + + public void setName_GreaterEqual(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_GREATER_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessEqual(String name) { + setName_LessEqual(name, null); + } + + public void setName_LessEqual(String name, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_LESS_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_NotEqual(String password) { + setPassword_NotEqual(password, null, null); + } + + public void setPassword_NotEqual(String password, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setPassword_Equal(password, eqOpLambda); + }, notOpLambda); + } + + public void setPassword_Equal(String password) { + setPassword_Term(password, null); + } + + public void setPassword_Equal(String password, ConditionOptionCall opLambda) { + setPassword_Term(password, opLambda); + } + + public void setPassword_Term(String password) { + setPassword_Term(password, null); + } + + public void setPassword_Term(String password, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("password", password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_Terms(Collection passwordList) { + setPassword_Terms(passwordList, null); + } + + public void setPassword_Terms(Collection passwordList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("password", passwordList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_InScope(Collection passwordList) { + setPassword_Terms(passwordList, null); + } + + public void setPassword_InScope(Collection passwordList, ConditionOptionCall opLambda) { + setPassword_Terms(passwordList, opLambda); + } + + public void setPassword_Prefix(String password) { + setPassword_Prefix(password, null); + } + + public void setPassword_Prefix(String password, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("password", password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_Exists() { + setPassword_Exists(null); + } + + public void setPassword_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("password"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_Missing() { + setPassword_Missing(null); + } + + public void setPassword_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("password"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_GreaterThan(String password) { + setPassword_GreaterThan(password, null); + } + + public void setPassword_GreaterThan(String password, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("password", ConditionKey.CK_GREATER_THAN, password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_LessThan(String password) { + setPassword_LessThan(password, null); + } + + public void setPassword_LessThan(String password, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("password", ConditionKey.CK_LESS_THAN, password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_GreaterEqual(String password) { + setPassword_GreaterEqual(password, null); + } + + public void setPassword_GreaterEqual(String password, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("password", ConditionKey.CK_GREATER_EQUAL, password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_LessEqual(String password) { + setPassword_LessEqual(password, null); + } + + public void setPassword_LessEqual(String password, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("password", ConditionKey.CK_LESS_EQUAL, password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_NotEqual(String roles) { + setRoles_NotEqual(roles, null, null); + } + + public void setRoles_NotEqual(String roles, ConditionOptionCall notOpLambda, + ConditionOptionCall eqOpLambda) { + not(subCf -> { + subCf.setRoles_Equal(roles, eqOpLambda); + }, notOpLambda); + } + + public void setRoles_Equal(String roles) { + setRoles_Term(roles, null); + } + + public void setRoles_Equal(String roles, ConditionOptionCall opLambda) { + setRoles_Term(roles, opLambda); + } + + public void setRoles_Term(String roles) { + setRoles_Term(roles, null); + } + + public void setRoles_Term(String roles, ConditionOptionCall opLambda) { + TermFilterBuilder builder = regTermF("roles", roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_Terms(Collection rolesList) { + setRoles_Terms(rolesList, null); + } + + public void setRoles_Terms(Collection rolesList, ConditionOptionCall opLambda) { + TermsFilterBuilder builder = regTermsF("roles", rolesList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_InScope(Collection rolesList) { + setRoles_Terms(rolesList, null); + } + + public void setRoles_InScope(Collection rolesList, ConditionOptionCall opLambda) { + setRoles_Terms(rolesList, opLambda); + } + + public void setRoles_Prefix(String roles) { + setRoles_Prefix(roles, null); + } + + public void setRoles_Prefix(String roles, ConditionOptionCall opLambda) { + PrefixFilterBuilder builder = regPrefixF("roles", roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_Exists() { + setRoles_Exists(null); + } + + public void setRoles_Exists(ConditionOptionCall opLambda) { + ExistsFilterBuilder builder = regExistsF("roles"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_Missing() { + setRoles_Missing(null); + } + + public void setRoles_Missing(ConditionOptionCall opLambda) { + MissingFilterBuilder builder = regMissingF("roles"); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_GreaterThan(String roles) { + setRoles_GreaterThan(roles, null); + } + + public void setRoles_GreaterThan(String roles, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("roles", ConditionKey.CK_GREATER_THAN, roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_LessThan(String roles) { + setRoles_LessThan(roles, null); + } + + public void setRoles_LessThan(String roles, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("roles", ConditionKey.CK_LESS_THAN, roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_GreaterEqual(String roles) { + setRoles_GreaterEqual(roles, null); + } + + public void setRoles_GreaterEqual(String roles, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("roles", ConditionKey.CK_GREATER_EQUAL, roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_LessEqual(String roles) { + setRoles_LessEqual(roles, null); + } + + public void setRoles_LessEqual(String roles, ConditionOptionCall opLambda) { + RangeFilterBuilder builder = regRangeF("roles", ConditionKey.CK_LESS_EQUAL, roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsUserInfoCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsUserInfoCF.java index f362089d4..974ee32b9 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsUserInfoCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsUserInfoCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.UserInfoCF; import org.codelibs.fess.es.cbean.cq.UserInfoCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebAuthenticationCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebAuthenticationCF.java index 0b6343bc9..751c34006 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebAuthenticationCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebAuthenticationCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.WebAuthenticationCF; import org.codelibs.fess.es.cbean.cq.WebAuthenticationCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigCF.java index 4984a25b9..479fb299d 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.WebConfigCF; import org.codelibs.fess.es.cbean.cq.WebConfigCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigToLabelCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigToLabelCF.java index a0d900f4b..9dcb6d0da 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigToLabelCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigToLabelCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.WebConfigToLabelCF; import org.codelibs.fess.es.cbean.cq.WebConfigToLabelCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigToRoleCF.java b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigToRoleCF.java index ce1adaea3..63729c38b 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigToRoleCF.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsWebConfigToRoleCF.java @@ -4,8 +4,8 @@ import java.util.Collection; import org.codelibs.fess.es.cbean.cf.WebConfigToRoleCF; import org.codelibs.fess.es.cbean.cq.WebConfigToRoleCQ; -import org.dbflute.exception.IllegalConditionBeanOperationException; import org.dbflute.cbean.ckey.ConditionKey; +import org.dbflute.exception.IllegalConditionBeanOperationException; import org.elasticsearch.index.query.AndFilterBuilder; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.ExistsFilterBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/EventLogCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/EventLogCQ.java new file mode 100644 index 000000000..7e453cc82 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/EventLogCQ.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean.cq; + +import org.codelibs.fess.es.cbean.cq.bs.BsEventLogCQ; + +/** + * @author FreeGen + */ +public class EventLogCQ extends BsEventLogCQ { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/GroupCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/GroupCQ.java new file mode 100644 index 000000000..b1f49c6e7 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/GroupCQ.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean.cq; + +import org.codelibs.fess.es.cbean.cq.bs.BsGroupCQ; + +/** + * @author FreeGen + */ +public class GroupCQ extends BsGroupCQ { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/RoleCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/RoleCQ.java new file mode 100644 index 000000000..b3f1655df --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/RoleCQ.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean.cq; + +import org.codelibs.fess.es.cbean.cq.bs.BsRoleCQ; + +/** + * @author FreeGen + */ +public class RoleCQ extends BsRoleCQ { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/UserCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/UserCQ.java new file mode 100644 index 000000000..9d5784705 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/UserCQ.java @@ -0,0 +1,9 @@ +package org.codelibs.fess.es.cbean.cq; + +import org.codelibs.fess.es.cbean.cq.bs.BsUserCQ; + +/** + * @author FreeGen + */ +public class UserCQ extends BsUserCQ { +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/AbstractConditionQuery.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/AbstractConditionQuery.java index 632b74abe..4cdb9d175 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/AbstractConditionQuery.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/AbstractConditionQuery.java @@ -164,12 +164,14 @@ public abstract class AbstractConditionQuery implements ConditionQuery { } protected RangeQueryBuilder regRangeQ(String name, ConditionKey ck, Object value) { - for (QueryBuilder builder : queryBuilderList) { - if (builder instanceof RangeQueryBuilder) { - RangeQueryBuilder rangeQueryBuilder = (RangeQueryBuilder) builder; - if (rangeQueryBuilder.toString().replaceAll("\\s", "").startsWith("{\"range\":{\"" + name + "\"")) { - addRangeC(rangeQueryBuilder, ck, value); - return rangeQueryBuilder; + if (queryBuilderList != null) { + for (QueryBuilder builder : queryBuilderList) { + if (builder instanceof RangeQueryBuilder) { + RangeQueryBuilder rangeQueryBuilder = (RangeQueryBuilder) builder; + if (rangeQueryBuilder.toString().replaceAll("\\s", "").startsWith("{\"range\":{\"" + name + "\"")) { + addRangeC(rangeQueryBuilder, ck, value); + return rangeQueryBuilder; + } } } } diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsBoostDocumentRuleCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsBoostDocumentRuleCQ.java index 22bfeb415..c05978556 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsBoostDocumentRuleCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsBoostDocumentRuleCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.BoostDocumentRuleCQ; import org.codelibs.fess.es.cbean.cf.BoostDocumentRuleCF; +import org.codelibs.fess.es.cbean.cq.BoostDocumentRuleCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsClickLogCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsClickLogCQ.java index 2e47ef929..c420583bc 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsClickLogCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsClickLogCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.ClickLogCQ; import org.codelibs.fess.es.cbean.cf.ClickLogCF; +import org.codelibs.fess.es.cbean.cq.ClickLogCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsCrawlingSessionCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsCrawlingSessionCQ.java index 48fe5bc06..6dc0cd37e 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsCrawlingSessionCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsCrawlingSessionCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.CrawlingSessionCQ; import org.codelibs.fess.es.cbean.cf.CrawlingSessionCF; +import org.codelibs.fess.es.cbean.cq.CrawlingSessionCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsCrawlingSessionInfoCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsCrawlingSessionInfoCQ.java index 0e482e8b2..965b42ca0 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsCrawlingSessionInfoCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsCrawlingSessionInfoCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.CrawlingSessionInfoCQ; import org.codelibs.fess.es.cbean.cf.CrawlingSessionInfoCF; +import org.codelibs.fess.es.cbean.cq.CrawlingSessionInfoCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigCQ.java index ce8512578..4026adf81 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.DataConfigCQ; import org.codelibs.fess.es.cbean.cf.DataConfigCF; +import org.codelibs.fess.es.cbean.cq.DataConfigCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigToLabelCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigToLabelCQ.java index 4c37e939b..782cf3787 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigToLabelCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigToLabelCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.DataConfigToLabelCQ; import org.codelibs.fess.es.cbean.cf.DataConfigToLabelCF; +import org.codelibs.fess.es.cbean.cq.DataConfigToLabelCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigToRoleCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigToRoleCQ.java index a65d89eb9..f4c034a4a 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigToRoleCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsDataConfigToRoleCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.DataConfigToRoleCQ; import org.codelibs.fess.es.cbean.cf.DataConfigToRoleCF; +import org.codelibs.fess.es.cbean.cq.DataConfigToRoleCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsEventLogCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsEventLogCQ.java new file mode 100644 index 000000000..5a0f399b0 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsEventLogCQ.java @@ -0,0 +1,937 @@ +package org.codelibs.fess.es.cbean.cq.bs; + +import java.time.LocalDateTime; +import java.util.Collection; + +import org.codelibs.fess.es.cbean.cf.EventLogCF; +import org.codelibs.fess.es.cbean.cq.EventLogCQ; +import org.dbflute.cbean.ckey.ConditionKey; +import org.elasticsearch.index.query.BoolQueryBuilder; +import org.elasticsearch.index.query.FilteredQueryBuilder; +import org.elasticsearch.index.query.FuzzyQueryBuilder; +import org.elasticsearch.index.query.MatchQueryBuilder; +import org.elasticsearch.index.query.PrefixQueryBuilder; +import org.elasticsearch.index.query.RangeQueryBuilder; +import org.elasticsearch.index.query.TermQueryBuilder; +import org.elasticsearch.index.query.TermsQueryBuilder; + +/** + * @author FreeGen + */ +public abstract class BsEventLogCQ extends AbstractConditionQuery { + + @Override + public String asTableDbName() { + return "event_log"; + } + + @Override + public String xgetAliasName() { + return "event_log"; + } + + public void filtered(FilteredCall filteredLambda) { + filtered(filteredLambda, null); + } + + public void filtered(FilteredCall filteredLambda, ConditionOptionCall opLambda) { + EventLogCQ query = new EventLogCQ(); + EventLogCF filter = new EventLogCF(); + filteredLambda.callback(query, filter); + if (query.hasQueries()) { + FilteredQueryBuilder builder = regFilteredQ(query.getQuery(), filter.getFilter()); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void bool(BoolCall boolLambda) { + bool(boolLambda, null); + } + + public void bool(BoolCall boolLambda, ConditionOptionCall opLambda) { + EventLogCQ mustQuery = new EventLogCQ(); + EventLogCQ shouldQuery = new EventLogCQ(); + EventLogCQ mustNotQuery = new EventLogCQ(); + boolLambda.callback(mustQuery, shouldQuery, mustNotQuery); + if (mustQuery.hasQueries() || shouldQuery.hasQueries() || mustNotQuery.hasQueries()) { + BoolQueryBuilder builder = regBoolCQ(mustQuery.queryBuilderList, shouldQuery.queryBuilderList, mustNotQuery.queryBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void setCreatedAt_Equal(LocalDateTime createdAt) { + setCreatedAt_Term(createdAt, null); + } + + public void setCreatedAt_Equal(LocalDateTime createdAt, ConditionOptionCall opLambda) { + setCreatedAt_Term(createdAt, opLambda); + } + + public void setCreatedAt_Term(LocalDateTime createdAt) { + setCreatedAt_Term(createdAt, null); + } + + public void setCreatedAt_Term(LocalDateTime createdAt, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("createdAt", createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_Terms(Collection createdAtList) { + setCreatedAt_Terms(createdAtList, null); + } + + public void setCreatedAt_Terms(Collection createdAtList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("createdAt", createdAtList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_InScope(Collection createdAtList) { + setCreatedAt_Terms(createdAtList, null); + } + + public void setCreatedAt_InScope(Collection createdAtList, ConditionOptionCall opLambda) { + setCreatedAt_Terms(createdAtList, opLambda); + } + + public void setCreatedAt_Match(LocalDateTime createdAt) { + setCreatedAt_Match(createdAt, null); + } + + public void setCreatedAt_Match(LocalDateTime createdAt, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("createdAt", createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_MatchPhrase(LocalDateTime createdAt) { + setCreatedAt_MatchPhrase(createdAt, null); + } + + public void setCreatedAt_MatchPhrase(LocalDateTime createdAt, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("createdAt", createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_MatchPhrasePrefix(LocalDateTime createdAt) { + setCreatedAt_MatchPhrasePrefix(createdAt, null); + } + + public void setCreatedAt_MatchPhrasePrefix(LocalDateTime createdAt, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("createdAt", createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_Fuzzy(LocalDateTime createdAt) { + setCreatedAt_Fuzzy(createdAt, null); + } + + public void setCreatedAt_Fuzzy(LocalDateTime createdAt, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("createdAt", createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_GreaterThan(LocalDateTime createdAt) { + setCreatedAt_GreaterThan(createdAt, null); + } + + public void setCreatedAt_GreaterThan(LocalDateTime createdAt, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("createdAt", ConditionKey.CK_GREATER_THAN, createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_LessThan(LocalDateTime createdAt) { + setCreatedAt_LessThan(createdAt, null); + } + + public void setCreatedAt_LessThan(LocalDateTime createdAt, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("createdAt", ConditionKey.CK_LESS_THAN, createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_GreaterEqual(LocalDateTime createdAt) { + setCreatedAt_GreaterEqual(createdAt, null); + } + + public void setCreatedAt_GreaterEqual(LocalDateTime createdAt, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("createdAt", ConditionKey.CK_GREATER_EQUAL, createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedAt_LessEqual(LocalDateTime createdAt) { + setCreatedAt_LessEqual(createdAt, null); + } + + public void setCreatedAt_LessEqual(LocalDateTime createdAt, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("createdAt", ConditionKey.CK_LESS_EQUAL, createdAt); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsEventLogCQ addOrderBy_CreatedAt_Asc() { + regOBA("createdAt"); + return this; + } + + public BsEventLogCQ addOrderBy_CreatedAt_Desc() { + regOBD("createdAt"); + return this; + } + + public void setCreatedBy_Equal(String createdBy) { + setCreatedBy_Term(createdBy, null); + } + + public void setCreatedBy_Equal(String createdBy, ConditionOptionCall opLambda) { + setCreatedBy_Term(createdBy, opLambda); + } + + public void setCreatedBy_Term(String createdBy) { + setCreatedBy_Term(createdBy, null); + } + + public void setCreatedBy_Term(String createdBy, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("createdBy", createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_Terms(Collection createdByList) { + setCreatedBy_Terms(createdByList, null); + } + + public void setCreatedBy_Terms(Collection createdByList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("createdBy", createdByList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_InScope(Collection createdByList) { + setCreatedBy_Terms(createdByList, null); + } + + public void setCreatedBy_InScope(Collection createdByList, ConditionOptionCall opLambda) { + setCreatedBy_Terms(createdByList, opLambda); + } + + public void setCreatedBy_Match(String createdBy) { + setCreatedBy_Match(createdBy, null); + } + + public void setCreatedBy_Match(String createdBy, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("createdBy", createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_MatchPhrase(String createdBy) { + setCreatedBy_MatchPhrase(createdBy, null); + } + + public void setCreatedBy_MatchPhrase(String createdBy, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("createdBy", createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_MatchPhrasePrefix(String createdBy) { + setCreatedBy_MatchPhrasePrefix(createdBy, null); + } + + public void setCreatedBy_MatchPhrasePrefix(String createdBy, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("createdBy", createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_Fuzzy(String createdBy) { + setCreatedBy_Fuzzy(createdBy, null); + } + + public void setCreatedBy_Fuzzy(String createdBy, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("createdBy", createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_Prefix(String createdBy) { + setCreatedBy_Prefix(createdBy, null); + } + + public void setCreatedBy_Prefix(String createdBy, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("createdBy", createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_GreaterThan(String createdBy) { + setCreatedBy_GreaterThan(createdBy, null); + } + + public void setCreatedBy_GreaterThan(String createdBy, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("createdBy", ConditionKey.CK_GREATER_THAN, createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_LessThan(String createdBy) { + setCreatedBy_LessThan(createdBy, null); + } + + public void setCreatedBy_LessThan(String createdBy, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("createdBy", ConditionKey.CK_LESS_THAN, createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_GreaterEqual(String createdBy) { + setCreatedBy_GreaterEqual(createdBy, null); + } + + public void setCreatedBy_GreaterEqual(String createdBy, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("createdBy", ConditionKey.CK_GREATER_EQUAL, createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setCreatedBy_LessEqual(String createdBy) { + setCreatedBy_LessEqual(createdBy, null); + } + + public void setCreatedBy_LessEqual(String createdBy, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("createdBy", ConditionKey.CK_LESS_EQUAL, createdBy); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsEventLogCQ addOrderBy_CreatedBy_Asc() { + regOBA("createdBy"); + return this; + } + + public BsEventLogCQ addOrderBy_CreatedBy_Desc() { + regOBD("createdBy"); + return this; + } + + public void setEventType_Equal(String eventType) { + setEventType_Term(eventType, null); + } + + public void setEventType_Equal(String eventType, ConditionOptionCall opLambda) { + setEventType_Term(eventType, opLambda); + } + + public void setEventType_Term(String eventType) { + setEventType_Term(eventType, null); + } + + public void setEventType_Term(String eventType, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("eventType", eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_Terms(Collection eventTypeList) { + setEventType_Terms(eventTypeList, null); + } + + public void setEventType_Terms(Collection eventTypeList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("eventType", eventTypeList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_InScope(Collection eventTypeList) { + setEventType_Terms(eventTypeList, null); + } + + public void setEventType_InScope(Collection eventTypeList, ConditionOptionCall opLambda) { + setEventType_Terms(eventTypeList, opLambda); + } + + public void setEventType_Match(String eventType) { + setEventType_Match(eventType, null); + } + + public void setEventType_Match(String eventType, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("eventType", eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_MatchPhrase(String eventType) { + setEventType_MatchPhrase(eventType, null); + } + + public void setEventType_MatchPhrase(String eventType, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("eventType", eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_MatchPhrasePrefix(String eventType) { + setEventType_MatchPhrasePrefix(eventType, null); + } + + public void setEventType_MatchPhrasePrefix(String eventType, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("eventType", eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_Fuzzy(String eventType) { + setEventType_Fuzzy(eventType, null); + } + + public void setEventType_Fuzzy(String eventType, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("eventType", eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_Prefix(String eventType) { + setEventType_Prefix(eventType, null); + } + + public void setEventType_Prefix(String eventType, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("eventType", eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_GreaterThan(String eventType) { + setEventType_GreaterThan(eventType, null); + } + + public void setEventType_GreaterThan(String eventType, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("eventType", ConditionKey.CK_GREATER_THAN, eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_LessThan(String eventType) { + setEventType_LessThan(eventType, null); + } + + public void setEventType_LessThan(String eventType, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("eventType", ConditionKey.CK_LESS_THAN, eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_GreaterEqual(String eventType) { + setEventType_GreaterEqual(eventType, null); + } + + public void setEventType_GreaterEqual(String eventType, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("eventType", ConditionKey.CK_GREATER_EQUAL, eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setEventType_LessEqual(String eventType) { + setEventType_LessEqual(eventType, null); + } + + public void setEventType_LessEqual(String eventType, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("eventType", ConditionKey.CK_LESS_EQUAL, eventType); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsEventLogCQ addOrderBy_EventType_Asc() { + regOBA("eventType"); + return this; + } + + public BsEventLogCQ addOrderBy_EventType_Desc() { + regOBD("eventType"); + return this; + } + + public void setId_Equal(String id) { + setId_Term(id, null); + } + + public void setId_Equal(String id, ConditionOptionCall opLambda) { + setId_Term(id, opLambda); + } + + public void setId_Term(String id) { + setId_Term(id, null); + } + + public void setId_Term(String id, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Terms(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_Terms(Collection idList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("id", idList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_InScope(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_InScope(Collection idList, ConditionOptionCall opLambda) { + setId_Terms(idList, opLambda); + } + + public void setId_Match(String id) { + setId_Match(id, null); + } + + public void setId_Match(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_MatchPhrase(String id) { + setId_MatchPhrase(id, null); + } + + public void setId_MatchPhrase(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_MatchPhrasePrefix(String id) { + setId_MatchPhrasePrefix(id, null); + } + + public void setId_MatchPhrasePrefix(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Fuzzy(String id) { + setId_Fuzzy(id, null); + } + + public void setId_Fuzzy(String id, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Prefix(String id) { + setId_Prefix(id, null); + } + + public void setId_Prefix(String id, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterThan(String id) { + setId_GreaterThan(id, null); + } + + public void setId_GreaterThan(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_GREATER_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessThan(String id) { + setId_LessThan(id, null); + } + + public void setId_LessThan(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_LESS_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterEqual(String id) { + setId_GreaterEqual(id, null); + } + + public void setId_GreaterEqual(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_GREATER_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessEqual(String id) { + setId_LessEqual(id, null); + } + + public void setId_LessEqual(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_LESS_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsEventLogCQ addOrderBy_Id_Asc() { + regOBA("id"); + return this; + } + + public BsEventLogCQ addOrderBy_Id_Desc() { + regOBD("id"); + return this; + } + + public void setMessage_Equal(String message) { + setMessage_Term(message, null); + } + + public void setMessage_Equal(String message, ConditionOptionCall opLambda) { + setMessage_Term(message, opLambda); + } + + public void setMessage_Term(String message) { + setMessage_Term(message, null); + } + + public void setMessage_Term(String message, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("message", message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_Terms(Collection messageList) { + setMessage_Terms(messageList, null); + } + + public void setMessage_Terms(Collection messageList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("message", messageList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_InScope(Collection messageList) { + setMessage_Terms(messageList, null); + } + + public void setMessage_InScope(Collection messageList, ConditionOptionCall opLambda) { + setMessage_Terms(messageList, opLambda); + } + + public void setMessage_Match(String message) { + setMessage_Match(message, null); + } + + public void setMessage_Match(String message, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("message", message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_MatchPhrase(String message) { + setMessage_MatchPhrase(message, null); + } + + public void setMessage_MatchPhrase(String message, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("message", message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_MatchPhrasePrefix(String message) { + setMessage_MatchPhrasePrefix(message, null); + } + + public void setMessage_MatchPhrasePrefix(String message, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("message", message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_Fuzzy(String message) { + setMessage_Fuzzy(message, null); + } + + public void setMessage_Fuzzy(String message, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("message", message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_Prefix(String message) { + setMessage_Prefix(message, null); + } + + public void setMessage_Prefix(String message, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("message", message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_GreaterThan(String message) { + setMessage_GreaterThan(message, null); + } + + public void setMessage_GreaterThan(String message, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("message", ConditionKey.CK_GREATER_THAN, message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_LessThan(String message) { + setMessage_LessThan(message, null); + } + + public void setMessage_LessThan(String message, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("message", ConditionKey.CK_LESS_THAN, message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_GreaterEqual(String message) { + setMessage_GreaterEqual(message, null); + } + + public void setMessage_GreaterEqual(String message, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("message", ConditionKey.CK_GREATER_EQUAL, message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setMessage_LessEqual(String message) { + setMessage_LessEqual(message, null); + } + + public void setMessage_LessEqual(String message, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("message", ConditionKey.CK_LESS_EQUAL, message); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsEventLogCQ addOrderBy_Message_Asc() { + regOBA("message"); + return this; + } + + public BsEventLogCQ addOrderBy_Message_Desc() { + regOBD("message"); + return this; + } + + public void setPath_Equal(String path) { + setPath_Term(path, null); + } + + public void setPath_Equal(String path, ConditionOptionCall opLambda) { + setPath_Term(path, opLambda); + } + + public void setPath_Term(String path) { + setPath_Term(path, null); + } + + public void setPath_Term(String path, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("path", path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_Terms(Collection pathList) { + setPath_Terms(pathList, null); + } + + public void setPath_Terms(Collection pathList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("path", pathList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_InScope(Collection pathList) { + setPath_Terms(pathList, null); + } + + public void setPath_InScope(Collection pathList, ConditionOptionCall opLambda) { + setPath_Terms(pathList, opLambda); + } + + public void setPath_Match(String path) { + setPath_Match(path, null); + } + + public void setPath_Match(String path, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("path", path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_MatchPhrase(String path) { + setPath_MatchPhrase(path, null); + } + + public void setPath_MatchPhrase(String path, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("path", path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_MatchPhrasePrefix(String path) { + setPath_MatchPhrasePrefix(path, null); + } + + public void setPath_MatchPhrasePrefix(String path, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("path", path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_Fuzzy(String path) { + setPath_Fuzzy(path, null); + } + + public void setPath_Fuzzy(String path, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("path", path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_Prefix(String path) { + setPath_Prefix(path, null); + } + + public void setPath_Prefix(String path, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("path", path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_GreaterThan(String path) { + setPath_GreaterThan(path, null); + } + + public void setPath_GreaterThan(String path, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("path", ConditionKey.CK_GREATER_THAN, path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_LessThan(String path) { + setPath_LessThan(path, null); + } + + public void setPath_LessThan(String path, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("path", ConditionKey.CK_LESS_THAN, path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_GreaterEqual(String path) { + setPath_GreaterEqual(path, null); + } + + public void setPath_GreaterEqual(String path, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("path", ConditionKey.CK_GREATER_EQUAL, path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPath_LessEqual(String path) { + setPath_LessEqual(path, null); + } + + public void setPath_LessEqual(String path, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("path", ConditionKey.CK_LESS_EQUAL, path); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsEventLogCQ addOrderBy_Path_Asc() { + regOBA("path"); + return this; + } + + public BsEventLogCQ addOrderBy_Path_Desc() { + regOBD("path"); + return this; + } + +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFailureUrlCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFailureUrlCQ.java index 4f38f3469..33fdbc156 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFailureUrlCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFailureUrlCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.FailureUrlCQ; import org.codelibs.fess.es.cbean.cf.FailureUrlCF; +import org.codelibs.fess.es.cbean.cq.FailureUrlCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFavoriteLogCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFavoriteLogCQ.java index 3f7163d10..5670f5292 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFavoriteLogCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFavoriteLogCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.FavoriteLogCQ; import org.codelibs.fess.es.cbean.cf.FavoriteLogCF; +import org.codelibs.fess.es.cbean.cq.FavoriteLogCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileAuthenticationCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileAuthenticationCQ.java index 7aa37d3ec..89020211c 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileAuthenticationCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileAuthenticationCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.FileAuthenticationCQ; import org.codelibs.fess.es.cbean.cf.FileAuthenticationCF; +import org.codelibs.fess.es.cbean.cq.FileAuthenticationCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigCQ.java index 310388fd6..5081d0126 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.FileConfigCQ; import org.codelibs.fess.es.cbean.cf.FileConfigCF; +import org.codelibs.fess.es.cbean.cq.FileConfigCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigToLabelCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigToLabelCQ.java index 343661b8d..42e1ff0b6 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigToLabelCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigToLabelCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.FileConfigToLabelCQ; import org.codelibs.fess.es.cbean.cf.FileConfigToLabelCF; +import org.codelibs.fess.es.cbean.cq.FileConfigToLabelCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigToRoleCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigToRoleCQ.java index fc447f541..219030941 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigToRoleCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsFileConfigToRoleCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.FileConfigToRoleCQ; import org.codelibs.fess.es.cbean.cf.FileConfigToRoleCF; +import org.codelibs.fess.es.cbean.cq.FileConfigToRoleCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsGroupCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsGroupCQ.java new file mode 100644 index 000000000..0feff08ff --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsGroupCQ.java @@ -0,0 +1,359 @@ +package org.codelibs.fess.es.cbean.cq.bs; + +import java.util.Collection; + +import org.codelibs.fess.es.cbean.cf.GroupCF; +import org.codelibs.fess.es.cbean.cq.GroupCQ; +import org.dbflute.cbean.ckey.ConditionKey; +import org.elasticsearch.index.query.BoolQueryBuilder; +import org.elasticsearch.index.query.FilteredQueryBuilder; +import org.elasticsearch.index.query.FuzzyQueryBuilder; +import org.elasticsearch.index.query.MatchQueryBuilder; +import org.elasticsearch.index.query.PrefixQueryBuilder; +import org.elasticsearch.index.query.RangeQueryBuilder; +import org.elasticsearch.index.query.TermQueryBuilder; +import org.elasticsearch.index.query.TermsQueryBuilder; + +/** + * @author FreeGen + */ +public abstract class BsGroupCQ extends AbstractConditionQuery { + + @Override + public String asTableDbName() { + return "group"; + } + + @Override + public String xgetAliasName() { + return "group"; + } + + public void filtered(FilteredCall filteredLambda) { + filtered(filteredLambda, null); + } + + public void filtered(FilteredCall filteredLambda, ConditionOptionCall opLambda) { + GroupCQ query = new GroupCQ(); + GroupCF filter = new GroupCF(); + filteredLambda.callback(query, filter); + if (query.hasQueries()) { + FilteredQueryBuilder builder = regFilteredQ(query.getQuery(), filter.getFilter()); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void bool(BoolCall boolLambda) { + bool(boolLambda, null); + } + + public void bool(BoolCall boolLambda, ConditionOptionCall opLambda) { + GroupCQ mustQuery = new GroupCQ(); + GroupCQ shouldQuery = new GroupCQ(); + GroupCQ mustNotQuery = new GroupCQ(); + boolLambda.callback(mustQuery, shouldQuery, mustNotQuery); + if (mustQuery.hasQueries() || shouldQuery.hasQueries() || mustNotQuery.hasQueries()) { + BoolQueryBuilder builder = regBoolCQ(mustQuery.queryBuilderList, shouldQuery.queryBuilderList, mustNotQuery.queryBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void setId_Equal(String id) { + setId_Term(id, null); + } + + public void setId_Equal(String id, ConditionOptionCall opLambda) { + setId_Term(id, opLambda); + } + + public void setId_Term(String id) { + setId_Term(id, null); + } + + public void setId_Term(String id, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Terms(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_Terms(Collection idList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("id", idList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_InScope(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_InScope(Collection idList, ConditionOptionCall opLambda) { + setId_Terms(idList, opLambda); + } + + public void setId_Match(String id) { + setId_Match(id, null); + } + + public void setId_Match(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_MatchPhrase(String id) { + setId_MatchPhrase(id, null); + } + + public void setId_MatchPhrase(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_MatchPhrasePrefix(String id) { + setId_MatchPhrasePrefix(id, null); + } + + public void setId_MatchPhrasePrefix(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Fuzzy(String id) { + setId_Fuzzy(id, null); + } + + public void setId_Fuzzy(String id, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Prefix(String id) { + setId_Prefix(id, null); + } + + public void setId_Prefix(String id, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterThan(String id) { + setId_GreaterThan(id, null); + } + + public void setId_GreaterThan(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_GREATER_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessThan(String id) { + setId_LessThan(id, null); + } + + public void setId_LessThan(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_LESS_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterEqual(String id) { + setId_GreaterEqual(id, null); + } + + public void setId_GreaterEqual(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_GREATER_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessEqual(String id) { + setId_LessEqual(id, null); + } + + public void setId_LessEqual(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_LESS_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsGroupCQ addOrderBy_Id_Asc() { + regOBA("id"); + return this; + } + + public BsGroupCQ addOrderBy_Id_Desc() { + regOBD("id"); + return this; + } + + public void setName_Equal(String name) { + setName_Term(name, null); + } + + public void setName_Equal(String name, ConditionOptionCall opLambda) { + setName_Term(name, opLambda); + } + + public void setName_Term(String name) { + setName_Term(name, null); + } + + public void setName_Term(String name, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Terms(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_Terms(Collection nameList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("name", nameList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_InScope(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_InScope(Collection nameList, ConditionOptionCall opLambda) { + setName_Terms(nameList, opLambda); + } + + public void setName_Match(String name) { + setName_Match(name, null); + } + + public void setName_Match(String name, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_MatchPhrase(String name) { + setName_MatchPhrase(name, null); + } + + public void setName_MatchPhrase(String name, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_MatchPhrasePrefix(String name) { + setName_MatchPhrasePrefix(name, null); + } + + public void setName_MatchPhrasePrefix(String name, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Fuzzy(String name) { + setName_Fuzzy(name, null); + } + + public void setName_Fuzzy(String name, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Prefix(String name) { + setName_Prefix(name, null); + } + + public void setName_Prefix(String name, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterThan(String name) { + setName_GreaterThan(name, null); + } + + public void setName_GreaterThan(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_GREATER_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessThan(String name) { + setName_LessThan(name, null); + } + + public void setName_LessThan(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_LESS_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterEqual(String name) { + setName_GreaterEqual(name, null); + } + + public void setName_GreaterEqual(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_GREATER_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessEqual(String name) { + setName_LessEqual(name, null); + } + + public void setName_LessEqual(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_LESS_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsGroupCQ addOrderBy_Name_Asc() { + regOBA("name"); + return this; + } + + public BsGroupCQ addOrderBy_Name_Desc() { + regOBD("name"); + return this; + } + +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsJobLogCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsJobLogCQ.java index 2d55c8834..35d43e1fb 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsJobLogCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsJobLogCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.JobLogCQ; import org.codelibs.fess.es.cbean.cf.JobLogCF; +import org.codelibs.fess.es.cbean.cq.JobLogCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsKeyMatchCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsKeyMatchCQ.java index 72b24c6cc..7111d85da 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsKeyMatchCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsKeyMatchCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.KeyMatchCQ; import org.codelibs.fess.es.cbean.cf.KeyMatchCF; +import org.codelibs.fess.es.cbean.cq.KeyMatchCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsLabelToRoleCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsLabelToRoleCQ.java index 631870222..bf4616c17 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsLabelToRoleCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsLabelToRoleCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.LabelToRoleCQ; import org.codelibs.fess.es.cbean.cf.LabelToRoleCF; +import org.codelibs.fess.es.cbean.cq.LabelToRoleCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsLabelTypeCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsLabelTypeCQ.java index d3a61c114..13fe0e3eb 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsLabelTypeCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsLabelTypeCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.LabelTypeCQ; import org.codelibs.fess.es.cbean.cf.LabelTypeCF; +import org.codelibs.fess.es.cbean.cq.LabelTypeCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsOverlappingHostCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsOverlappingHostCQ.java index 4c066de87..c0828bf99 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsOverlappingHostCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsOverlappingHostCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.OverlappingHostCQ; import org.codelibs.fess.es.cbean.cf.OverlappingHostCF; +import org.codelibs.fess.es.cbean.cq.OverlappingHostCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsPathMappingCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsPathMappingCQ.java index f1a748677..1cbe96170 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsPathMappingCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsPathMappingCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.PathMappingCQ; import org.codelibs.fess.es.cbean.cf.PathMappingCF; +import org.codelibs.fess.es.cbean.cq.PathMappingCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRequestHeaderCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRequestHeaderCQ.java index dd8170b41..3308e20b2 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRequestHeaderCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRequestHeaderCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.RequestHeaderCQ; import org.codelibs.fess.es.cbean.cf.RequestHeaderCF; +import org.codelibs.fess.es.cbean.cq.RequestHeaderCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRoleCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRoleCQ.java new file mode 100644 index 000000000..a9f23ecd3 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRoleCQ.java @@ -0,0 +1,359 @@ +package org.codelibs.fess.es.cbean.cq.bs; + +import java.util.Collection; + +import org.codelibs.fess.es.cbean.cf.RoleCF; +import org.codelibs.fess.es.cbean.cq.RoleCQ; +import org.dbflute.cbean.ckey.ConditionKey; +import org.elasticsearch.index.query.BoolQueryBuilder; +import org.elasticsearch.index.query.FilteredQueryBuilder; +import org.elasticsearch.index.query.FuzzyQueryBuilder; +import org.elasticsearch.index.query.MatchQueryBuilder; +import org.elasticsearch.index.query.PrefixQueryBuilder; +import org.elasticsearch.index.query.RangeQueryBuilder; +import org.elasticsearch.index.query.TermQueryBuilder; +import org.elasticsearch.index.query.TermsQueryBuilder; + +/** + * @author FreeGen + */ +public abstract class BsRoleCQ extends AbstractConditionQuery { + + @Override + public String asTableDbName() { + return "role"; + } + + @Override + public String xgetAliasName() { + return "role"; + } + + public void filtered(FilteredCall filteredLambda) { + filtered(filteredLambda, null); + } + + public void filtered(FilteredCall filteredLambda, ConditionOptionCall opLambda) { + RoleCQ query = new RoleCQ(); + RoleCF filter = new RoleCF(); + filteredLambda.callback(query, filter); + if (query.hasQueries()) { + FilteredQueryBuilder builder = regFilteredQ(query.getQuery(), filter.getFilter()); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void bool(BoolCall boolLambda) { + bool(boolLambda, null); + } + + public void bool(BoolCall boolLambda, ConditionOptionCall opLambda) { + RoleCQ mustQuery = new RoleCQ(); + RoleCQ shouldQuery = new RoleCQ(); + RoleCQ mustNotQuery = new RoleCQ(); + boolLambda.callback(mustQuery, shouldQuery, mustNotQuery); + if (mustQuery.hasQueries() || shouldQuery.hasQueries() || mustNotQuery.hasQueries()) { + BoolQueryBuilder builder = regBoolCQ(mustQuery.queryBuilderList, shouldQuery.queryBuilderList, mustNotQuery.queryBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void setId_Equal(String id) { + setId_Term(id, null); + } + + public void setId_Equal(String id, ConditionOptionCall opLambda) { + setId_Term(id, opLambda); + } + + public void setId_Term(String id) { + setId_Term(id, null); + } + + public void setId_Term(String id, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Terms(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_Terms(Collection idList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("id", idList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_InScope(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_InScope(Collection idList, ConditionOptionCall opLambda) { + setId_Terms(idList, opLambda); + } + + public void setId_Match(String id) { + setId_Match(id, null); + } + + public void setId_Match(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_MatchPhrase(String id) { + setId_MatchPhrase(id, null); + } + + public void setId_MatchPhrase(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_MatchPhrasePrefix(String id) { + setId_MatchPhrasePrefix(id, null); + } + + public void setId_MatchPhrasePrefix(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Fuzzy(String id) { + setId_Fuzzy(id, null); + } + + public void setId_Fuzzy(String id, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Prefix(String id) { + setId_Prefix(id, null); + } + + public void setId_Prefix(String id, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterThan(String id) { + setId_GreaterThan(id, null); + } + + public void setId_GreaterThan(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_GREATER_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessThan(String id) { + setId_LessThan(id, null); + } + + public void setId_LessThan(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_LESS_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterEqual(String id) { + setId_GreaterEqual(id, null); + } + + public void setId_GreaterEqual(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_GREATER_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessEqual(String id) { + setId_LessEqual(id, null); + } + + public void setId_LessEqual(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_LESS_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsRoleCQ addOrderBy_Id_Asc() { + regOBA("id"); + return this; + } + + public BsRoleCQ addOrderBy_Id_Desc() { + regOBD("id"); + return this; + } + + public void setName_Equal(String name) { + setName_Term(name, null); + } + + public void setName_Equal(String name, ConditionOptionCall opLambda) { + setName_Term(name, opLambda); + } + + public void setName_Term(String name) { + setName_Term(name, null); + } + + public void setName_Term(String name, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Terms(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_Terms(Collection nameList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("name", nameList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_InScope(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_InScope(Collection nameList, ConditionOptionCall opLambda) { + setName_Terms(nameList, opLambda); + } + + public void setName_Match(String name) { + setName_Match(name, null); + } + + public void setName_Match(String name, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_MatchPhrase(String name) { + setName_MatchPhrase(name, null); + } + + public void setName_MatchPhrase(String name, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_MatchPhrasePrefix(String name) { + setName_MatchPhrasePrefix(name, null); + } + + public void setName_MatchPhrasePrefix(String name, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Fuzzy(String name) { + setName_Fuzzy(name, null); + } + + public void setName_Fuzzy(String name, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Prefix(String name) { + setName_Prefix(name, null); + } + + public void setName_Prefix(String name, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterThan(String name) { + setName_GreaterThan(name, null); + } + + public void setName_GreaterThan(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_GREATER_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessThan(String name) { + setName_LessThan(name, null); + } + + public void setName_LessThan(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_LESS_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterEqual(String name) { + setName_GreaterEqual(name, null); + } + + public void setName_GreaterEqual(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_GREATER_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessEqual(String name) { + setName_LessEqual(name, null); + } + + public void setName_LessEqual(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_LESS_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsRoleCQ addOrderBy_Name_Asc() { + regOBA("name"); + return this; + } + + public BsRoleCQ addOrderBy_Name_Desc() { + regOBD("name"); + return this; + } + +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRoleTypeCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRoleTypeCQ.java index a56b33a90..a5469bae1 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRoleTypeCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRoleTypeCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.RoleTypeCQ; import org.codelibs.fess.es.cbean.cf.RoleTypeCF; +import org.codelibs.fess.es.cbean.cq.RoleTypeCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsScheduledJobCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsScheduledJobCQ.java index 97c718bc4..af8f6a691 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsScheduledJobCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsScheduledJobCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.ScheduledJobCQ; import org.codelibs.fess.es.cbean.cf.ScheduledJobCF; +import org.codelibs.fess.es.cbean.cq.ScheduledJobCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSearchFieldLogCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSearchFieldLogCQ.java index e507f1dbc..99937f5ce 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSearchFieldLogCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSearchFieldLogCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.SearchFieldLogCQ; import org.codelibs.fess.es.cbean.cf.SearchFieldLogCF; +import org.codelibs.fess.es.cbean.cq.SearchFieldLogCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSearchLogCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSearchLogCQ.java index 065d791f9..6e83bea10 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSearchLogCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSearchLogCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.SearchLogCQ; import org.codelibs.fess.es.cbean.cf.SearchLogCF; +import org.codelibs.fess.es.cbean.cq.SearchLogCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSuggestBadWordCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSuggestBadWordCQ.java index 1a11e0d16..2b2ad9c2c 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSuggestBadWordCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSuggestBadWordCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.SuggestBadWordCQ; import org.codelibs.fess.es.cbean.cf.SuggestBadWordCF; +import org.codelibs.fess.es.cbean.cq.SuggestBadWordCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSuggestElevateWordCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSuggestElevateWordCQ.java index 6d81e7d8f..623d4d521 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSuggestElevateWordCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsSuggestElevateWordCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.SuggestElevateWordCQ; import org.codelibs.fess.es.cbean.cf.SuggestElevateWordCF; +import org.codelibs.fess.es.cbean.cq.SuggestElevateWordCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsUserCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsUserCQ.java new file mode 100644 index 000000000..bc7f90984 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsUserCQ.java @@ -0,0 +1,800 @@ +package org.codelibs.fess.es.cbean.cq.bs; + +import java.util.Collection; + +import org.codelibs.fess.es.cbean.cf.UserCF; +import org.codelibs.fess.es.cbean.cq.UserCQ; +import org.dbflute.cbean.ckey.ConditionKey; +import org.elasticsearch.index.query.BoolQueryBuilder; +import org.elasticsearch.index.query.FilteredQueryBuilder; +import org.elasticsearch.index.query.FuzzyQueryBuilder; +import org.elasticsearch.index.query.MatchQueryBuilder; +import org.elasticsearch.index.query.PrefixQueryBuilder; +import org.elasticsearch.index.query.RangeQueryBuilder; +import org.elasticsearch.index.query.TermQueryBuilder; +import org.elasticsearch.index.query.TermsQueryBuilder; + +/** + * @author FreeGen + */ +public abstract class BsUserCQ extends AbstractConditionQuery { + + @Override + public String asTableDbName() { + return "user"; + } + + @Override + public String xgetAliasName() { + return "user"; + } + + public void filtered(FilteredCall filteredLambda) { + filtered(filteredLambda, null); + } + + public void filtered(FilteredCall filteredLambda, ConditionOptionCall opLambda) { + UserCQ query = new UserCQ(); + UserCF filter = new UserCF(); + filteredLambda.callback(query, filter); + if (query.hasQueries()) { + FilteredQueryBuilder builder = regFilteredQ(query.getQuery(), filter.getFilter()); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void bool(BoolCall boolLambda) { + bool(boolLambda, null); + } + + public void bool(BoolCall boolLambda, ConditionOptionCall opLambda) { + UserCQ mustQuery = new UserCQ(); + UserCQ shouldQuery = new UserCQ(); + UserCQ mustNotQuery = new UserCQ(); + boolLambda.callback(mustQuery, shouldQuery, mustNotQuery); + if (mustQuery.hasQueries() || shouldQuery.hasQueries() || mustNotQuery.hasQueries()) { + BoolQueryBuilder builder = regBoolCQ(mustQuery.queryBuilderList, shouldQuery.queryBuilderList, mustNotQuery.queryBuilderList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + } + + public void setGroups_Equal(String groups) { + setGroups_Term(groups, null); + } + + public void setGroups_Equal(String groups, ConditionOptionCall opLambda) { + setGroups_Term(groups, opLambda); + } + + public void setGroups_Term(String groups) { + setGroups_Term(groups, null); + } + + public void setGroups_Term(String groups, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("groups", groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_Terms(Collection groupsList) { + setGroups_Terms(groupsList, null); + } + + public void setGroups_Terms(Collection groupsList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("groups", groupsList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_InScope(Collection groupsList) { + setGroups_Terms(groupsList, null); + } + + public void setGroups_InScope(Collection groupsList, ConditionOptionCall opLambda) { + setGroups_Terms(groupsList, opLambda); + } + + public void setGroups_Match(String groups) { + setGroups_Match(groups, null); + } + + public void setGroups_Match(String groups, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("groups", groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_MatchPhrase(String groups) { + setGroups_MatchPhrase(groups, null); + } + + public void setGroups_MatchPhrase(String groups, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("groups", groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_MatchPhrasePrefix(String groups) { + setGroups_MatchPhrasePrefix(groups, null); + } + + public void setGroups_MatchPhrasePrefix(String groups, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("groups", groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_Fuzzy(String groups) { + setGroups_Fuzzy(groups, null); + } + + public void setGroups_Fuzzy(String groups, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("groups", groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_Prefix(String groups) { + setGroups_Prefix(groups, null); + } + + public void setGroups_Prefix(String groups, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("groups", groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_GreaterThan(String groups) { + setGroups_GreaterThan(groups, null); + } + + public void setGroups_GreaterThan(String groups, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("groups", ConditionKey.CK_GREATER_THAN, groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_LessThan(String groups) { + setGroups_LessThan(groups, null); + } + + public void setGroups_LessThan(String groups, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("groups", ConditionKey.CK_LESS_THAN, groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_GreaterEqual(String groups) { + setGroups_GreaterEqual(groups, null); + } + + public void setGroups_GreaterEqual(String groups, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("groups", ConditionKey.CK_GREATER_EQUAL, groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setGroups_LessEqual(String groups) { + setGroups_LessEqual(groups, null); + } + + public void setGroups_LessEqual(String groups, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("groups", ConditionKey.CK_LESS_EQUAL, groups); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsUserCQ addOrderBy_Groups_Asc() { + regOBA("groups"); + return this; + } + + public BsUserCQ addOrderBy_Groups_Desc() { + regOBD("groups"); + return this; + } + + public void setId_Equal(String id) { + setId_Term(id, null); + } + + public void setId_Equal(String id, ConditionOptionCall opLambda) { + setId_Term(id, opLambda); + } + + public void setId_Term(String id) { + setId_Term(id, null); + } + + public void setId_Term(String id, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Terms(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_Terms(Collection idList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("id", idList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_InScope(Collection idList) { + setId_Terms(idList, null); + } + + public void setId_InScope(Collection idList, ConditionOptionCall opLambda) { + setId_Terms(idList, opLambda); + } + + public void setId_Match(String id) { + setId_Match(id, null); + } + + public void setId_Match(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_MatchPhrase(String id) { + setId_MatchPhrase(id, null); + } + + public void setId_MatchPhrase(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_MatchPhrasePrefix(String id) { + setId_MatchPhrasePrefix(id, null); + } + + public void setId_MatchPhrasePrefix(String id, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Fuzzy(String id) { + setId_Fuzzy(id, null); + } + + public void setId_Fuzzy(String id, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_Prefix(String id) { + setId_Prefix(id, null); + } + + public void setId_Prefix(String id, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("id", id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterThan(String id) { + setId_GreaterThan(id, null); + } + + public void setId_GreaterThan(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_GREATER_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessThan(String id) { + setId_LessThan(id, null); + } + + public void setId_LessThan(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_LESS_THAN, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_GreaterEqual(String id) { + setId_GreaterEqual(id, null); + } + + public void setId_GreaterEqual(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_GREATER_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setId_LessEqual(String id) { + setId_LessEqual(id, null); + } + + public void setId_LessEqual(String id, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("id", ConditionKey.CK_LESS_EQUAL, id); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsUserCQ addOrderBy_Id_Asc() { + regOBA("id"); + return this; + } + + public BsUserCQ addOrderBy_Id_Desc() { + regOBD("id"); + return this; + } + + public void setName_Equal(String name) { + setName_Term(name, null); + } + + public void setName_Equal(String name, ConditionOptionCall opLambda) { + setName_Term(name, opLambda); + } + + public void setName_Term(String name) { + setName_Term(name, null); + } + + public void setName_Term(String name, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Terms(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_Terms(Collection nameList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("name", nameList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_InScope(Collection nameList) { + setName_Terms(nameList, null); + } + + public void setName_InScope(Collection nameList, ConditionOptionCall opLambda) { + setName_Terms(nameList, opLambda); + } + + public void setName_Match(String name) { + setName_Match(name, null); + } + + public void setName_Match(String name, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_MatchPhrase(String name) { + setName_MatchPhrase(name, null); + } + + public void setName_MatchPhrase(String name, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_MatchPhrasePrefix(String name) { + setName_MatchPhrasePrefix(name, null); + } + + public void setName_MatchPhrasePrefix(String name, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Fuzzy(String name) { + setName_Fuzzy(name, null); + } + + public void setName_Fuzzy(String name, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_Prefix(String name) { + setName_Prefix(name, null); + } + + public void setName_Prefix(String name, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("name", name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterThan(String name) { + setName_GreaterThan(name, null); + } + + public void setName_GreaterThan(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_GREATER_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessThan(String name) { + setName_LessThan(name, null); + } + + public void setName_LessThan(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_LESS_THAN, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_GreaterEqual(String name) { + setName_GreaterEqual(name, null); + } + + public void setName_GreaterEqual(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_GREATER_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setName_LessEqual(String name) { + setName_LessEqual(name, null); + } + + public void setName_LessEqual(String name, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("name", ConditionKey.CK_LESS_EQUAL, name); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsUserCQ addOrderBy_Name_Asc() { + regOBA("name"); + return this; + } + + public BsUserCQ addOrderBy_Name_Desc() { + regOBD("name"); + return this; + } + + public void setPassword_Equal(String password) { + setPassword_Term(password, null); + } + + public void setPassword_Equal(String password, ConditionOptionCall opLambda) { + setPassword_Term(password, opLambda); + } + + public void setPassword_Term(String password) { + setPassword_Term(password, null); + } + + public void setPassword_Term(String password, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("password", password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_Terms(Collection passwordList) { + setPassword_Terms(passwordList, null); + } + + public void setPassword_Terms(Collection passwordList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("password", passwordList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_InScope(Collection passwordList) { + setPassword_Terms(passwordList, null); + } + + public void setPassword_InScope(Collection passwordList, ConditionOptionCall opLambda) { + setPassword_Terms(passwordList, opLambda); + } + + public void setPassword_Match(String password) { + setPassword_Match(password, null); + } + + public void setPassword_Match(String password, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("password", password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_MatchPhrase(String password) { + setPassword_MatchPhrase(password, null); + } + + public void setPassword_MatchPhrase(String password, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("password", password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_MatchPhrasePrefix(String password) { + setPassword_MatchPhrasePrefix(password, null); + } + + public void setPassword_MatchPhrasePrefix(String password, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("password", password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_Fuzzy(String password) { + setPassword_Fuzzy(password, null); + } + + public void setPassword_Fuzzy(String password, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("password", password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_Prefix(String password) { + setPassword_Prefix(password, null); + } + + public void setPassword_Prefix(String password, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("password", password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_GreaterThan(String password) { + setPassword_GreaterThan(password, null); + } + + public void setPassword_GreaterThan(String password, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("password", ConditionKey.CK_GREATER_THAN, password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_LessThan(String password) { + setPassword_LessThan(password, null); + } + + public void setPassword_LessThan(String password, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("password", ConditionKey.CK_LESS_THAN, password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_GreaterEqual(String password) { + setPassword_GreaterEqual(password, null); + } + + public void setPassword_GreaterEqual(String password, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("password", ConditionKey.CK_GREATER_EQUAL, password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setPassword_LessEqual(String password) { + setPassword_LessEqual(password, null); + } + + public void setPassword_LessEqual(String password, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("password", ConditionKey.CK_LESS_EQUAL, password); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsUserCQ addOrderBy_Password_Asc() { + regOBA("password"); + return this; + } + + public BsUserCQ addOrderBy_Password_Desc() { + regOBD("password"); + return this; + } + + public void setRoles_Equal(String roles) { + setRoles_Term(roles, null); + } + + public void setRoles_Equal(String roles, ConditionOptionCall opLambda) { + setRoles_Term(roles, opLambda); + } + + public void setRoles_Term(String roles) { + setRoles_Term(roles, null); + } + + public void setRoles_Term(String roles, ConditionOptionCall opLambda) { + TermQueryBuilder builder = regTermQ("roles", roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_Terms(Collection rolesList) { + setRoles_Terms(rolesList, null); + } + + public void setRoles_Terms(Collection rolesList, ConditionOptionCall opLambda) { + TermsQueryBuilder builder = regTermsQ("roles", rolesList); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_InScope(Collection rolesList) { + setRoles_Terms(rolesList, null); + } + + public void setRoles_InScope(Collection rolesList, ConditionOptionCall opLambda) { + setRoles_Terms(rolesList, opLambda); + } + + public void setRoles_Match(String roles) { + setRoles_Match(roles, null); + } + + public void setRoles_Match(String roles, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchQ("roles", roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_MatchPhrase(String roles) { + setRoles_MatchPhrase(roles, null); + } + + public void setRoles_MatchPhrase(String roles, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhraseQ("roles", roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_MatchPhrasePrefix(String roles) { + setRoles_MatchPhrasePrefix(roles, null); + } + + public void setRoles_MatchPhrasePrefix(String roles, ConditionOptionCall opLambda) { + MatchQueryBuilder builder = regMatchPhrasePrefixQ("roles", roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_Fuzzy(String roles) { + setRoles_Fuzzy(roles, null); + } + + public void setRoles_Fuzzy(String roles, ConditionOptionCall opLambda) { + FuzzyQueryBuilder builder = regFuzzyQ("roles", roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_Prefix(String roles) { + setRoles_Prefix(roles, null); + } + + public void setRoles_Prefix(String roles, ConditionOptionCall opLambda) { + PrefixQueryBuilder builder = regPrefixQ("roles", roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_GreaterThan(String roles) { + setRoles_GreaterThan(roles, null); + } + + public void setRoles_GreaterThan(String roles, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("roles", ConditionKey.CK_GREATER_THAN, roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_LessThan(String roles) { + setRoles_LessThan(roles, null); + } + + public void setRoles_LessThan(String roles, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("roles", ConditionKey.CK_LESS_THAN, roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_GreaterEqual(String roles) { + setRoles_GreaterEqual(roles, null); + } + + public void setRoles_GreaterEqual(String roles, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("roles", ConditionKey.CK_GREATER_EQUAL, roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public void setRoles_LessEqual(String roles) { + setRoles_LessEqual(roles, null); + } + + public void setRoles_LessEqual(String roles, ConditionOptionCall opLambda) { + RangeQueryBuilder builder = regRangeQ("roles", ConditionKey.CK_LESS_EQUAL, roles); + if (opLambda != null) { + opLambda.callback(builder); + } + } + + public BsUserCQ addOrderBy_Roles_Asc() { + regOBA("roles"); + return this; + } + + public BsUserCQ addOrderBy_Roles_Desc() { + regOBD("roles"); + return this; + } + +} diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsUserInfoCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsUserInfoCQ.java index 8d0ca942c..15b3b32d6 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsUserInfoCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsUserInfoCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.UserInfoCQ; import org.codelibs.fess.es.cbean.cf.UserInfoCF; +import org.codelibs.fess.es.cbean.cq.UserInfoCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebAuthenticationCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebAuthenticationCQ.java index a8bcb2780..fd16f1d8b 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebAuthenticationCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebAuthenticationCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.WebAuthenticationCQ; import org.codelibs.fess.es.cbean.cf.WebAuthenticationCF; +import org.codelibs.fess.es.cbean.cq.WebAuthenticationCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigCQ.java index a9d499cbb..3432d698a 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.WebConfigCQ; import org.codelibs.fess.es.cbean.cf.WebConfigCF; +import org.codelibs.fess.es.cbean.cq.WebConfigCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigToLabelCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigToLabelCQ.java index fff4867ef..eb60374e3 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigToLabelCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigToLabelCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.WebConfigToLabelCQ; import org.codelibs.fess.es.cbean.cf.WebConfigToLabelCF; +import org.codelibs.fess.es.cbean.cq.WebConfigToLabelCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigToRoleCQ.java b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigToRoleCQ.java index bdc2aee2f..df5b6fd3a 100644 --- a/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigToRoleCQ.java +++ b/src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsWebConfigToRoleCQ.java @@ -2,8 +2,8 @@ package org.codelibs.fess.es.cbean.cq.bs; import java.util.Collection; -import org.codelibs.fess.es.cbean.cq.WebConfigToRoleCQ; import org.codelibs.fess.es.cbean.cf.WebConfigToRoleCF; +import org.codelibs.fess.es.cbean.cq.WebConfigToRoleCQ; import org.dbflute.cbean.ckey.ConditionKey; import org.elasticsearch.index.query.BoolQueryBuilder; import org.elasticsearch.index.query.FilteredQueryBuilder; diff --git a/src/main/java/org/codelibs/fess/client/FessEsClient.java b/src/main/java/org/codelibs/fess/es/client/FessEsClient.java similarity index 67% rename from src/main/java/org/codelibs/fess/client/FessEsClient.java rename to src/main/java/org/codelibs/fess/es/client/FessEsClient.java index 875008e5b..d7f8a9004 100644 --- a/src/main/java/org/codelibs/fess/client/FessEsClient.java +++ b/src/main/java/org/codelibs/fess/es/client/FessEsClient.java @@ -1,9 +1,10 @@ -package org.codelibs.fess.client; +package org.codelibs.fess.es.client; import static org.codelibs.elasticsearch.runner.ElasticsearchClusterRunner.newConfigs; -import java.io.IOException; +import java.io.File; import java.util.ArrayList; +import java.util.Arrays; import java.util.Collections; import java.util.HashMap; import java.util.List; @@ -11,23 +12,29 @@ import java.util.Map; import java.util.Map.Entry; import java.util.Optional; import java.util.Set; +import java.util.stream.Collectors; + +import javax.annotation.PostConstruct; +import javax.annotation.PreDestroy; import org.apache.commons.codec.Charsets; import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.core.io.FileUtil; +import org.codelibs.core.io.ResourceUtil; import org.codelibs.core.lang.StringUtil; import org.codelibs.elasticsearch.runner.ElasticsearchClusterRunner; import org.codelibs.elasticsearch.runner.ElasticsearchClusterRunner.Configs; import org.codelibs.elasticsearch.runner.net.Curl; import org.codelibs.elasticsearch.runner.net.CurlResponse; import org.codelibs.fess.Constants; -import org.codelibs.fess.ResultOffsetExceededException; import org.codelibs.fess.entity.FacetInfo; import org.codelibs.fess.entity.GeoInfo; import org.codelibs.fess.entity.PingResponse; import org.codelibs.fess.entity.SearchQuery; import org.codelibs.fess.entity.SearchQuery.SortField; -import org.codelibs.fess.solr.FessSolrQueryException; +import org.codelibs.fess.exception.ResultOffsetExceededException; +import org.codelibs.fess.helper.QueryHelper; +import org.codelibs.fess.indexer.FessSearchQueryException; import org.codelibs.fess.util.ComponentUtil; import org.elasticsearch.ElasticsearchException; import org.elasticsearch.action.Action; @@ -126,6 +133,7 @@ import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.transport.InetSocketTransportAddress; import org.elasticsearch.common.transport.TransportAddress; import org.elasticsearch.common.unit.TimeValue; +import org.elasticsearch.index.get.GetField; import org.elasticsearch.index.query.BoolFilterBuilder; import org.elasticsearch.index.query.FilterBuilders; import org.elasticsearch.index.query.QueryBuilder; @@ -133,6 +141,7 @@ import org.elasticsearch.index.query.QueryBuilders; import org.elasticsearch.indices.IndexAlreadyExistsException; import org.elasticsearch.indices.IndexMissingException; import org.elasticsearch.search.SearchHit; +import org.elasticsearch.search.SearchHitField; import org.elasticsearch.search.aggregations.AggregationBuilders; import org.elasticsearch.search.aggregations.bucket.filter.FilterAggregationBuilder; import org.elasticsearch.search.aggregations.bucket.terms.TermsBuilder; @@ -140,8 +149,6 @@ import org.elasticsearch.search.sort.FieldSortBuilder; import org.elasticsearch.search.sort.SortBuilders; import org.elasticsearch.search.sort.SortOrder; import org.elasticsearch.threadpool.ThreadPool; -import org.seasar.framework.container.annotation.tiger.DestroyMethod; -import org.seasar.framework.container.annotation.tiger.InitMethod; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -156,7 +163,7 @@ public class FessEsClient implements Client { protected Client client; - protected String clusterName = "elasticsearch"; + protected String clusterName = "fess"; protected Map settings; @@ -166,11 +173,11 @@ public class FessEsClient implements Client { protected Map> configListMap = new HashMap<>(); - public void addIndexConfig(String path) { + public void addIndexConfig(final String path) { indexConfigList.add(path); } - public void addConfigFile(String index, String path) { + public void addConfigFile(final String index, final String path) { List list = configListMap.get(index); if (list == null) { list = new ArrayList<>(); @@ -179,7 +186,7 @@ public class FessEsClient implements Client { list.add(path); } - public void setSettings(Map settings) { + public void setSettings(final Map settings) { this.settings = settings; } @@ -187,20 +194,28 @@ public class FessEsClient implements Client { return clusterName; } - public void setClusterName(String clusterName) { + public void setClusterName(final String clusterName) { this.clusterName = clusterName; } - public void setRunner(ElasticsearchClusterRunner runner) { + public String getStatus() { + return admin().cluster().prepareHealth().execute().actionGet().getStatus().name(); + } + + public void setRunner(final ElasticsearchClusterRunner runner) { this.runner = runner; } - public void addTransportAddress(String host, int port) { + public void addTransportAddress(final String host, final int port) { transportAddressList.add(new InetSocketTransportAddress(host, port)); } - @InitMethod + @PostConstruct public void open() { + final String clusterNameValue = System.getProperty(Constants.FESS_ES_CLUSTER_NAME); + if (StringUtil.isNotBlank(clusterNameValue)) { + clusterName = clusterNameValue; + } final String transportAddressesValue = System.getProperty(Constants.FESS_ES_TRANSPORT_ADDRESSES); if (StringUtil.isNotBlank(transportAddressesValue)) { for (final String transportAddressValue : transportAddressesValue.split(",")) { @@ -221,16 +236,21 @@ public class FessEsClient implements Client { if (transportAddressList.isEmpty()) { if (runner == null) { runner = new ElasticsearchClusterRunner(); - final Configs config = newConfigs().clusterName(clusterName).numOfNode(1); + final Configs config = newConfigs().clusterName(clusterName).numOfNode(1).useLogger(); final String esDir = System.getProperty("fess.es.dir"); if (esDir != null) { config.basePath(esDir); } runner.onBuild((number, settingsBuilder) -> { + final File pluginDir = new File(esDir, "plugins"); + if (pluginDir.isDirectory()) { + settingsBuilder.put("path.plugins", pluginDir.getAbsolutePath()); + } else { + settingsBuilder.put("path.plugins", new File(System.getProperty("user.dir"), "plugins").getAbsolutePath()); + } if (settings != null) { settingsBuilder.put(settings); } - settingsBuilder.put("path.plugins", System.getProperty("user.dir") + "/plugins"); }); runner.build(config); } @@ -247,6 +267,10 @@ public class FessEsClient implements Client { client = transportClient; } + if (StringUtil.isBlank(clusterNameValue)) { + System.setProperty(Constants.FESS_ES_CLUSTER_NAME, clusterName); + } + if (StringUtil.isBlank(transportAddressesValue)) { final StringBuilder buf = new StringBuilder(); for (final TransportAddress transportAddress : transportAddressList) { @@ -299,6 +323,15 @@ public class FessEsClient implements Client { logger.warn("Failed to register " + filePath, e); } }); + try (CurlResponse response = Curl.post(runner.node(), "_configsync/flush").execute()) { + if (response.getHttpStatusCode() == 200) { + logger.info("Flushed config files."); + } else { + logger.warn("Failed to flush config files."); + } + } catch (final Exception e) { + logger.warn("Failed to flush config files.", e); + } } try { @@ -339,6 +372,34 @@ public class FessEsClient implements Client { } else { logger.warn("Failed to create " + configIndex + "/" + configType + " mapping."); } + + final String dataPath = indexConfigPath + "/" + configIndex + "/" + configType + ".bulk"; + if (ResourceUtil.isExist(dataPath)) { + try { + final BulkRequestBuilder builder = client.prepareBulk(); + Arrays.stream(FileUtil.readUTF8(dataPath).split("\n")).reduce((prev, line) -> { + if (StringUtil.isBlank(prev)) { + if (line.startsWith("{\"index\":{")) { + return line; + } else if (line.startsWith("{\"update\":{")) { + return line; + } else if (line.startsWith("{\"delete\":{")) { + return StringUtil.EMPTY; + } + } else if (prev.startsWith("{\"index\":{")) { + final IndexRequestBuilder requestBuilder = client.prepareIndex(configIndex, configType).setSource(line); + builder.add(requestBuilder); + } + return StringUtil.EMPTY; + }); + final BulkResponse response = builder.execute().actionGet(); + if (response.hasFailures()) { + logger.warn("Failed to register " + dataPath.toString() + ": " + response.buildFailureMessage()); + } + } catch (final Exception e) { + logger.warn("Failed to create " + configIndex + "/" + configType + " mapping."); + } + } } else if (logger.isDebugEnabled()) { logger.debug(configIndex + "/" + configType + " mapping exists."); } @@ -356,7 +417,7 @@ public class FessEsClient implements Client { } @Override - @DestroyMethod + @PreDestroy public void close() { try { client.close(); @@ -365,7 +426,7 @@ public class FessEsClient implements Client { } } - public void deleteByQuery(String index, String type, QueryBuilder queryBuilder) { + public void deleteByQuery(final String index, final String type, final QueryBuilder queryBuilder) { try { // TODO replace with deleting bulk ids with scroll/scan client.prepareDeleteByQuery(index).setQuery(queryBuilder).setTypes(type).execute().actionGet().forEach(res -> { @@ -384,26 +445,59 @@ public class FessEsClient implements Client { } } - public T search(String index, String type, SearchCondition condition, SearchResult searchResult) { + public T get(final String index, final String type, final String id, final SearchCondition condition, + final SearchResult searchResult) { + final long startTime = System.currentTimeMillis(); + + GetResponse response = null; + final GetRequestBuilder requestBuilder = client.prepareGet(index, type, id); + if (condition.build(requestBuilder)) { + + if (ComponentUtil.hasQueryHelper()) { + final QueryHelper queryHelper = ComponentUtil.getQueryHelper(); + for (final Map.Entry entry : queryHelper.getQueryParamMap().entrySet()) { + requestBuilder.putHeader(entry.getKey(), entry.getValue()); + } + + final Set> paramSet = queryHelper.getRequestParameterSet(); + if (!paramSet.isEmpty()) { + for (final Map.Entry entry : paramSet) { + requestBuilder.putHeader(entry.getKey(), entry.getValue()); + } + } + } + + response = requestBuilder.execute().actionGet(); + } + final long execTime = System.currentTimeMillis() - startTime; + + return searchResult.build(requestBuilder, execTime, Optional.ofNullable(response)); + } + + public T search(final String index, final String type, final SearchCondition condition, + final SearchResult searchResult) { final long startTime = System.currentTimeMillis(); SearchResponse searchResponse = null; final SearchRequestBuilder searchRequestBuilder = client.prepareSearch(index).setTypes(type); if (condition.build(searchRequestBuilder)) { - if (ComponentUtil.getQueryHelper().getTimeAllowed() >= 0) { - searchRequestBuilder.setTimeout(TimeValue.timeValueMillis(ComponentUtil.getQueryHelper().getTimeAllowed())); - } + if (ComponentUtil.hasQueryHelper()) { + final QueryHelper queryHelper = ComponentUtil.getQueryHelper(); + if (queryHelper.getTimeAllowed() >= 0) { + searchRequestBuilder.setTimeout(TimeValue.timeValueMillis(queryHelper.getTimeAllowed())); + } - for (final Map.Entry entry : ComponentUtil.getQueryHelper().getQueryParamMap().entrySet()) { - searchRequestBuilder.putHeader(entry.getKey(), entry.getValue()); - } - - final Set> paramSet = ComponentUtil.getQueryHelper().getRequestParameterSet(); - if (!paramSet.isEmpty()) { - for (final Map.Entry entry : paramSet) { + for (final Map.Entry entry : queryHelper.getQueryParamMap().entrySet()) { searchRequestBuilder.putHeader(entry.getKey(), entry.getValue()); } + + final Set> paramSet = queryHelper.getRequestParameterSet(); + if (!paramSet.isEmpty()) { + for (final Map.Entry entry : paramSet) { + searchRequestBuilder.putHeader(entry.getKey(), entry.getValue()); + } + } } searchResponse = searchRequestBuilder.execute().actionGet(); @@ -413,13 +507,23 @@ public class FessEsClient implements Client { return searchResult.build(searchRequestBuilder, execTime, Optional.ofNullable(searchResponse)); } - public Optional> getDocument(String index, String type, final SearchCondition condition) { + public Optional> getDocument(final String index, final String type, + final SearchCondition condition) { return getDocument(index, type, condition, (response, hit) -> { - return hit.getSource(); + final Map source = hit.getSource(); + if (source != null) { + return source; + } + final Map fields = hit.getFields(); + if (fields != null) { + return fields.entrySet().stream().collect(Collectors.toMap(e -> e.getKey(), e -> (Object) e.getValue().getValues())); + } + return null; }); } - public Optional getDocument(String index, String type, final SearchCondition condition, EntityCreator creator) { + public Optional getDocument(final String index, final String type, final SearchCondition condition, + final EntityCreator creator) { return search(index, type, condition, (queryBuilder, execTime, searchResponse) -> { return searchResponse.map(response -> { final SearchHit[] hits = response.getHits().hits(); @@ -431,13 +535,39 @@ public class FessEsClient implements Client { }); } - public List> getDocumentList(String index, String type, final SearchCondition condition) { + public Optional> getDocument(final String index, final String type, final String id, + final SearchCondition condition) { + return getDocument(index, type, id, condition, (response, result) -> { + final Map source = response.getSource(); + if (source != null) { + return source; + } + final Map fields = response.getFields(); + if (fields != null) { + return fields.entrySet().stream().collect(Collectors.toMap(e -> e.getKey(), e -> (Object) e.getValue().getValues())); + } + return null; + }); + } + + public Optional getDocument(final String index, final String type, final String id, + final SearchCondition condition, final EntityCreator creator) { + return get(index, type, id, condition, (queryBuilder, execTime, getResponse) -> { + return getResponse.map(response -> { + return creator.build(response, response); + }); + }); + } + + public List> getDocumentList(final String index, final String type, + final SearchCondition condition) { return getDocumentList(index, type, condition, (response, hit) -> { return hit.getSource(); }); } - public List getDocumentList(String index, String type, final SearchCondition condition, EntityCreator creator) { + public List getDocumentList(final String index, final String type, final SearchCondition condition, + final EntityCreator creator) { return search(index, type, condition, (searchRequestBuilder, execTime, searchResponse) -> { final List list = new ArrayList<>(); searchResponse.ifPresent(response -> { @@ -449,7 +579,7 @@ public class FessEsClient implements Client { }); } - public boolean update(String index, String type, String id, String field, Object value) { + public boolean update(final String index, final String type, final String id, final String field, final Object value) { try { return client.prepareUpdate(index, type, id).setDoc(field, value).execute().actionGet().isCreated(); } catch (final ElasticsearchException e) { @@ -457,53 +587,53 @@ public class FessEsClient implements Client { } } - public void refresh(String index) { + public void refresh(final String index) { client.admin().indices().prepareRefresh(index).execute(new ActionListener() { @Override - public void onResponse(RefreshResponse response) { + public void onResponse(final RefreshResponse response) { if (logger.isDebugEnabled()) { logger.debug("Refreshed " + index + "."); } } @Override - public void onFailure(Throwable e) { + public void onFailure(final Throwable e) { logger.error("Failed to refresh " + index + ".", e); } }); } - public void flush(String index) { + public void flush(final String index) { client.admin().indices().prepareFlush(index).execute(new ActionListener() { @Override - public void onResponse(FlushResponse response) { + public void onResponse(final FlushResponse response) { if (logger.isDebugEnabled()) { logger.debug("Flushed " + index + "."); } } @Override - public void onFailure(Throwable e) { + public void onFailure(final Throwable e) { logger.error("Failed to flush " + index + ".", e); } }); } - public void optimize(String index) { + public void optimize(final String index) { client.admin().indices().prepareOptimize(index).execute(new ActionListener() { @Override - public void onResponse(OptimizeResponse response) { + public void onResponse(final OptimizeResponse response) { if (logger.isDebugEnabled()) { logger.debug("Optimzed " + index + "."); } } @Override - public void onFailure(Throwable e) { + public void onFailure(final Throwable e) { logger.error("Failed to optimze " + index + ".", e); } }); @@ -518,15 +648,14 @@ public class FessEsClient implements Client { } } - public void addAll(String index, String type, List> docList) { + public void addAll(final String index, final String type, final List> docList) { final BulkRequestBuilder bulkRequestBuilder = client.prepareBulk(); for (final Map doc : docList) { bulkRequestBuilder.add(client.prepareIndex(index, type).setSource(doc)); } final BulkResponse response = bulkRequestBuilder.execute().actionGet(); - final String failureMessage = response.buildFailureMessage(); - if (StringUtil.isNotBlank(failureMessage)) { - throw new FessEsClientException(failureMessage); + if (response.hasFailures()) { + throw new FessEsClientException(response.buildFailureMessage()); } } @@ -540,15 +669,15 @@ public class FessEsClient implements Client { private GeoInfo geoInfo; private FacetInfo facetInfo; - public static SearchConditionBuilder builder(SearchRequestBuilder searchRequestBuilder) { + public static SearchConditionBuilder builder(final SearchRequestBuilder searchRequestBuilder) { return new SearchConditionBuilder(searchRequestBuilder); } - SearchConditionBuilder(SearchRequestBuilder searchRequestBuilder) { + SearchConditionBuilder(final SearchRequestBuilder searchRequestBuilder) { this.searchRequestBuilder = searchRequestBuilder; } - public SearchConditionBuilder query(String query) { + public SearchConditionBuilder query(final String query) { this.query = query; return this; } @@ -558,27 +687,27 @@ public class FessEsClient implements Client { return this; } - public SearchConditionBuilder responseFields(String[] responseFields) { + public SearchConditionBuilder responseFields(final String[] responseFields) { this.responseFields = responseFields; return this; } - public SearchConditionBuilder offset(int offset) { + public SearchConditionBuilder offset(final int offset) { this.offset = offset; return this; } - public SearchConditionBuilder size(int size) { + public SearchConditionBuilder size(final int size) { this.size = size; return this; } - public SearchConditionBuilder geoInfo(GeoInfo geoInfo) { + public SearchConditionBuilder geoInfo(final GeoInfo geoInfo) { this.geoInfo = geoInfo; return this; } - public SearchConditionBuilder facetInfo(FacetInfo facetInfo) { + public SearchConditionBuilder facetInfo(final FacetInfo facetInfo) { this.facetInfo = facetInfo; return this; } @@ -624,10 +753,10 @@ public class FessEsClient implements Client { } } // highlighting - if (ComponentUtil.getQueryHelper().getHighlightingFields() != null - && ComponentUtil.getQueryHelper().getHighlightingFields().length != 0) { - for (final String hf : ComponentUtil.getQueryHelper().getHighlightingFields()) { - searchRequestBuilder.addHighlightedField(hf, ComponentUtil.getQueryHelper().getHighlightSnippetSize()); + if (ComponentUtil.getQueryHelper().getHighlightedFields() != null + && ComponentUtil.getQueryHelper().getHighlightedFields().length != 0) { + for (final String hf : ComponentUtil.getQueryHelper().getHighlightedFields()) { + searchRequestBuilder.addHighlightedField(hf, ComponentUtil.getQueryHelper().getHighlightFragmentSize()); } } @@ -646,7 +775,7 @@ public class FessEsClient implements Client { } searchRequestBuilder.addAggregation(termsBuilder); } else { - throw new FessSolrQueryException("Invalid facet field: " + f); + throw new FessSearchQueryException("Invalid facet field: " + f); } } } @@ -665,7 +794,7 @@ public class FessEsClient implements Client { } searchRequestBuilder.addAggregation(filterBuilder); } else { - throw new FessSolrQueryException("Invalid facet query: " + facetQuery); + throw new FessSearchQueryException("Invalid facet query: " + facetQuery); } } } @@ -702,7 +831,7 @@ public class FessEsClient implements Client { } } - public boolean store(String index, String type, Object obj) { + public boolean store(final String index, final String type, final Object obj) { final Map source = BeanUtil.copyBeanToNewMap(obj); final String id = (String) source.remove("id"); final Long version = (Long) source.remove("version"); @@ -724,30 +853,33 @@ public class FessEsClient implements Client { } } - public boolean delete(String index, String type, String id, long version) { + public boolean delete(final String index, final String type, final String id, final long version) { try { - final DeleteResponse response = - client.prepareDelete(index, type, id).setVersion(version).setRefresh(true).execute().actionGet(); + final DeleteRequestBuilder builder = client.prepareDelete(index, type, id).setRefresh(true); + if (version > 0) { + builder.setVersion(version); + } + final DeleteResponse response = builder.execute().actionGet(); return response.isFound(); } catch (final ElasticsearchException e) { throw new FessEsClientException("Failed to delete: " + index + "/" + type + "/" + id + "/" + version, e); } } - public void setIndexConfigPath(String indexConfigPath) { + public void setIndexConfigPath(final String indexConfigPath) { this.indexConfigPath = indexConfigPath; } - public interface SearchCondition { - boolean build(SearchRequestBuilder searchRequestBuilder); + public interface SearchCondition { + boolean build(B requestBuilder); } - public interface SearchResult { - T build(SearchRequestBuilder searchRequestBuilder, long execTime, Optional searchResponse); + public interface SearchResult { + T build(B requestBuilder, long execTime, Optional response); } - public interface EntityCreator { - T build(SearchResponse response, SearchHit hit); + public interface EntityCreator { + T build(R response, H hit); } // @@ -756,19 +888,19 @@ public class FessEsClient implements Client { @Override public > ActionFuture execute( - Action action, Request request) { + final Action action, final Request request) { return client.execute(action, request); } @Override public > void execute( - Action action, Request request, ActionListener listener) { + final Action action, final Request request, final ActionListener listener) { client.execute(action, request, listener); } @Override public > RequestBuilder prepareExecute( - Action action) { + final Action action) { return client.prepareExecute(action); } @@ -783,12 +915,12 @@ public class FessEsClient implements Client { } @Override - public ActionFuture index(IndexRequest request) { + public ActionFuture index(final IndexRequest request) { return client.index(request); } @Override - public void index(IndexRequest request, ActionListener listener) { + public void index(final IndexRequest request, final ActionListener listener) { client.index(request, listener); } @@ -798,12 +930,12 @@ public class FessEsClient implements Client { } @Override - public ActionFuture update(UpdateRequest request) { + public ActionFuture update(final UpdateRequest request) { return client.update(request); } @Override - public void update(UpdateRequest request, ActionListener listener) { + public void update(final UpdateRequest request, final ActionListener listener) { client.update(request, listener); } @@ -813,27 +945,27 @@ public class FessEsClient implements Client { } @Override - public UpdateRequestBuilder prepareUpdate(String index, String type, String id) { + public UpdateRequestBuilder prepareUpdate(final String index, final String type, final String id) { return client.prepareUpdate(index, type, id); } @Override - public IndexRequestBuilder prepareIndex(String index, String type) { + public IndexRequestBuilder prepareIndex(final String index, final String type) { return client.prepareIndex(index, type); } @Override - public IndexRequestBuilder prepareIndex(String index, String type, String id) { + public IndexRequestBuilder prepareIndex(final String index, final String type, final String id) { return client.prepareIndex(index, type, id); } @Override - public ActionFuture delete(DeleteRequest request) { + public ActionFuture delete(final DeleteRequest request) { return client.delete(request); } @Override - public void delete(DeleteRequest request, ActionListener listener) { + public void delete(final DeleteRequest request, final ActionListener listener) { client.delete(request, listener); } @@ -843,17 +975,17 @@ public class FessEsClient implements Client { } @Override - public DeleteRequestBuilder prepareDelete(String index, String type, String id) { + public DeleteRequestBuilder prepareDelete(final String index, final String type, final String id) { return client.prepareDelete(index, type, id); } @Override - public ActionFuture bulk(BulkRequest request) { + public ActionFuture bulk(final BulkRequest request) { return client.bulk(request); } @Override - public void bulk(BulkRequest request, ActionListener listener) { + public void bulk(final BulkRequest request, final ActionListener listener) { client.bulk(request, listener); } @@ -863,27 +995,27 @@ public class FessEsClient implements Client { } @Override - public ActionFuture deleteByQuery(DeleteByQueryRequest request) { + public ActionFuture deleteByQuery(final DeleteByQueryRequest request) { return client.deleteByQuery(request); } @Override - public void deleteByQuery(DeleteByQueryRequest request, ActionListener listener) { + public void deleteByQuery(final DeleteByQueryRequest request, final ActionListener listener) { client.deleteByQuery(request, listener); } @Override - public DeleteByQueryRequestBuilder prepareDeleteByQuery(String... indices) { + public DeleteByQueryRequestBuilder prepareDeleteByQuery(final String... indices) { return client.prepareDeleteByQuery(indices); } @Override - public ActionFuture get(GetRequest request) { + public ActionFuture get(final GetRequest request) { return client.get(request); } @Override - public void get(GetRequest request, ActionListener listener) { + public void get(final GetRequest request, final ActionListener listener) { client.get(request, listener); } @@ -893,7 +1025,7 @@ public class FessEsClient implements Client { } @Override - public GetRequestBuilder prepareGet(String index, String type, String id) { + public GetRequestBuilder prepareGet(final String index, final String type, final String id) { return client.prepareGet(index, type, id); } @@ -903,17 +1035,17 @@ public class FessEsClient implements Client { } @Override - public PutIndexedScriptRequestBuilder preparePutIndexedScript(String scriptLang, String id, String source) { + public PutIndexedScriptRequestBuilder preparePutIndexedScript(final String scriptLang, final String id, final String source) { return client.preparePutIndexedScript(scriptLang, id, source); } @Override - public void deleteIndexedScript(DeleteIndexedScriptRequest request, ActionListener listener) { + public void deleteIndexedScript(final DeleteIndexedScriptRequest request, final ActionListener listener) { client.deleteIndexedScript(request, listener); } @Override - public ActionFuture deleteIndexedScript(DeleteIndexedScriptRequest request) { + public ActionFuture deleteIndexedScript(final DeleteIndexedScriptRequest request) { return client.deleteIndexedScript(request); } @@ -923,17 +1055,17 @@ public class FessEsClient implements Client { } @Override - public DeleteIndexedScriptRequestBuilder prepareDeleteIndexedScript(String scriptLang, String id) { + public DeleteIndexedScriptRequestBuilder prepareDeleteIndexedScript(final String scriptLang, final String id) { return client.prepareDeleteIndexedScript(scriptLang, id); } @Override - public void putIndexedScript(PutIndexedScriptRequest request, ActionListener listener) { + public void putIndexedScript(final PutIndexedScriptRequest request, final ActionListener listener) { client.putIndexedScript(request, listener); } @Override - public ActionFuture putIndexedScript(PutIndexedScriptRequest request) { + public ActionFuture putIndexedScript(final PutIndexedScriptRequest request) { return client.putIndexedScript(request); } @@ -943,27 +1075,27 @@ public class FessEsClient implements Client { } @Override - public GetIndexedScriptRequestBuilder prepareGetIndexedScript(String scriptLang, String id) { + public GetIndexedScriptRequestBuilder prepareGetIndexedScript(final String scriptLang, final String id) { return client.prepareGetIndexedScript(scriptLang, id); } @Override - public void getIndexedScript(GetIndexedScriptRequest request, ActionListener listener) { + public void getIndexedScript(final GetIndexedScriptRequest request, final ActionListener listener) { client.getIndexedScript(request, listener); } @Override - public ActionFuture getIndexedScript(GetIndexedScriptRequest request) { + public ActionFuture getIndexedScript(final GetIndexedScriptRequest request) { return client.getIndexedScript(request); } @Override - public ActionFuture multiGet(MultiGetRequest request) { + public ActionFuture multiGet(final MultiGetRequest request) { return client.multiGet(request); } @Override - public void multiGet(MultiGetRequest request, ActionListener listener) { + public void multiGet(final MultiGetRequest request, final ActionListener listener) { client.multiGet(request, listener); } @@ -973,87 +1105,87 @@ public class FessEsClient implements Client { } @Override - public ActionFuture count(CountRequest request) { + public ActionFuture count(final CountRequest request) { return client.count(request); } @Override - public void count(CountRequest request, ActionListener listener) { + public void count(final CountRequest request, final ActionListener listener) { client.count(request, listener); } @Override - public CountRequestBuilder prepareCount(String... indices) { + public CountRequestBuilder prepareCount(final String... indices) { return client.prepareCount(indices); } @Override - public ActionFuture exists(ExistsRequest request) { + public ActionFuture exists(final ExistsRequest request) { return client.exists(request); } @Override - public void exists(ExistsRequest request, ActionListener listener) { + public void exists(final ExistsRequest request, final ActionListener listener) { client.exists(request, listener); } @Override - public ExistsRequestBuilder prepareExists(String... indices) { + public ExistsRequestBuilder prepareExists(final String... indices) { return client.prepareExists(indices); } @Override - public ActionFuture suggest(SuggestRequest request) { + public ActionFuture suggest(final SuggestRequest request) { return client.suggest(request); } @Override - public void suggest(SuggestRequest request, ActionListener listener) { + public void suggest(final SuggestRequest request, final ActionListener listener) { client.suggest(request, listener); } @Override - public SuggestRequestBuilder prepareSuggest(String... indices) { + public SuggestRequestBuilder prepareSuggest(final String... indices) { return client.prepareSuggest(indices); } @Override - public ActionFuture search(SearchRequest request) { + public ActionFuture search(final SearchRequest request) { return client.search(request); } @Override - public void search(SearchRequest request, ActionListener listener) { + public void search(final SearchRequest request, final ActionListener listener) { client.search(request, listener); } @Override - public SearchRequestBuilder prepareSearch(String... indices) { + public SearchRequestBuilder prepareSearch(final String... indices) { return client.prepareSearch(indices); } @Override - public ActionFuture searchScroll(SearchScrollRequest request) { + public ActionFuture searchScroll(final SearchScrollRequest request) { return client.searchScroll(request); } @Override - public void searchScroll(SearchScrollRequest request, ActionListener listener) { + public void searchScroll(final SearchScrollRequest request, final ActionListener listener) { client.searchScroll(request, listener); } @Override - public SearchScrollRequestBuilder prepareSearchScroll(String scrollId) { + public SearchScrollRequestBuilder prepareSearchScroll(final String scrollId) { return client.prepareSearchScroll(scrollId); } @Override - public ActionFuture multiSearch(MultiSearchRequest request) { + public ActionFuture multiSearch(final MultiSearchRequest request) { return client.multiSearch(request); } @Override - public void multiSearch(MultiSearchRequest request, ActionListener listener) { + public void multiSearch(final MultiSearchRequest request, final ActionListener listener) { client.multiSearch(request, listener); } @@ -1063,27 +1195,27 @@ public class FessEsClient implements Client { } @Override - public ActionFuture moreLikeThis(MoreLikeThisRequest request) { + public ActionFuture moreLikeThis(final MoreLikeThisRequest request) { return client.moreLikeThis(request); } @Override - public void moreLikeThis(MoreLikeThisRequest request, ActionListener listener) { + public void moreLikeThis(final MoreLikeThisRequest request, final ActionListener listener) { client.moreLikeThis(request, listener); } @Override - public MoreLikeThisRequestBuilder prepareMoreLikeThis(String index, String type, String id) { + public MoreLikeThisRequestBuilder prepareMoreLikeThis(final String index, final String type, final String id) { return client.prepareMoreLikeThis(index, type, id); } @Override - public ActionFuture termVector(TermVectorRequest request) { + public ActionFuture termVector(final TermVectorRequest request) { return client.termVector(request); } @Override - public void termVector(TermVectorRequest request, ActionListener listener) { + public void termVector(final TermVectorRequest request, final ActionListener listener) { client.termVector(request, listener); } @@ -1093,17 +1225,17 @@ public class FessEsClient implements Client { } @Override - public TermVectorRequestBuilder prepareTermVector(String index, String type, String id) { + public TermVectorRequestBuilder prepareTermVector(final String index, final String type, final String id) { return client.prepareTermVector(index, type, id); } @Override - public ActionFuture multiTermVectors(MultiTermVectorsRequest request) { + public ActionFuture multiTermVectors(final MultiTermVectorsRequest request) { return client.multiTermVectors(request); } @Override - public void multiTermVectors(MultiTermVectorsRequest request, ActionListener listener) { + public void multiTermVectors(final MultiTermVectorsRequest request, final ActionListener listener) { client.multiTermVectors(request, listener); } @@ -1113,12 +1245,12 @@ public class FessEsClient implements Client { } @Override - public ActionFuture percolate(PercolateRequest request) { + public ActionFuture percolate(final PercolateRequest request) { return client.percolate(request); } @Override - public void percolate(PercolateRequest request, ActionListener listener) { + public void percolate(final PercolateRequest request, final ActionListener listener) { client.percolate(request, listener); } @@ -1128,12 +1260,12 @@ public class FessEsClient implements Client { } @Override - public ActionFuture multiPercolate(MultiPercolateRequest request) { + public ActionFuture multiPercolate(final MultiPercolateRequest request) { return client.multiPercolate(request); } @Override - public void multiPercolate(MultiPercolateRequest request, ActionListener listener) { + public void multiPercolate(final MultiPercolateRequest request, final ActionListener listener) { client.multiPercolate(request, listener); } @@ -1143,17 +1275,17 @@ public class FessEsClient implements Client { } @Override - public ExplainRequestBuilder prepareExplain(String index, String type, String id) { + public ExplainRequestBuilder prepareExplain(final String index, final String type, final String id) { return client.prepareExplain(index, type, id); } @Override - public ActionFuture explain(ExplainRequest request) { + public ActionFuture explain(final ExplainRequest request) { return client.explain(request); } @Override - public void explain(ExplainRequest request, ActionListener listener) { + public void explain(final ExplainRequest request, final ActionListener listener) { client.explain(request, listener); } @@ -1163,12 +1295,12 @@ public class FessEsClient implements Client { } @Override - public ActionFuture clearScroll(ClearScrollRequest request) { + public ActionFuture clearScroll(final ClearScrollRequest request) { return client.clearScroll(request); } @Override - public void clearScroll(ClearScrollRequest request, ActionListener listener) { + public void clearScroll(final ClearScrollRequest request, final ActionListener listener) { client.clearScroll(request, listener); } @@ -1178,12 +1310,12 @@ public class FessEsClient implements Client { } @Override - public ActionFuture fieldStats(FieldStatsRequest request) { + public ActionFuture fieldStats(final FieldStatsRequest request) { return client.fieldStats(request); } @Override - public void fieldStats(FieldStatsRequest request, ActionListener listener) { + public void fieldStats(final FieldStatsRequest request, final ActionListener listener) { client.fieldStats(request, listener); } diff --git a/src/main/java/org/codelibs/fess/es/client/FessEsClientException.java b/src/main/java/org/codelibs/fess/es/client/FessEsClientException.java new file mode 100644 index 000000000..813cee159 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/client/FessEsClientException.java @@ -0,0 +1,17 @@ +package org.codelibs.fess.es.client; + +import org.codelibs.fess.exception.FessSystemException; + +public class FessEsClientException extends FessSystemException { + + private static final long serialVersionUID = 1L; + + public FessEsClientException(final String message, final Throwable cause) { + super(message, cause); + } + + public FessEsClientException(final String message) { + super(message); + } + +} diff --git a/src/main/java/org/codelibs/fess/es/exbhv/EventLogBhv.java b/src/main/java/org/codelibs/fess/es/exbhv/EventLogBhv.java new file mode 100644 index 000000000..7b371eb3c --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/exbhv/EventLogBhv.java @@ -0,0 +1,10 @@ +package org.codelibs.fess.es.exbhv; + +import org.codelibs.fess.es.bsbhv.BsEventLogBhv; + +/** + * @author FreeGen + */ +public class EventLogBhv extends BsEventLogBhv { + +} diff --git a/src/main/java/org/codelibs/fess/es/exbhv/GroupBhv.java b/src/main/java/org/codelibs/fess/es/exbhv/GroupBhv.java new file mode 100644 index 000000000..8acca9b87 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/exbhv/GroupBhv.java @@ -0,0 +1,10 @@ +package org.codelibs.fess.es.exbhv; + +import org.codelibs.fess.es.bsbhv.BsGroupBhv; + +/** + * @author FreeGen + */ +public class GroupBhv extends BsGroupBhv { + +} diff --git a/src/main/java/org/codelibs/fess/es/exbhv/RoleBhv.java b/src/main/java/org/codelibs/fess/es/exbhv/RoleBhv.java new file mode 100644 index 000000000..fc856b6c7 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/exbhv/RoleBhv.java @@ -0,0 +1,10 @@ +package org.codelibs.fess.es.exbhv; + +import org.codelibs.fess.es.bsbhv.BsRoleBhv; + +/** + * @author FreeGen + */ +public class RoleBhv extends BsRoleBhv { + +} diff --git a/src/main/java/org/codelibs/fess/es/exbhv/UserBhv.java b/src/main/java/org/codelibs/fess/es/exbhv/UserBhv.java new file mode 100644 index 000000000..0c7b8930c --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/exbhv/UserBhv.java @@ -0,0 +1,10 @@ +package org.codelibs.fess.es.exbhv; + +import org.codelibs.fess.es.bsbhv.BsUserBhv; + +/** + * @author FreeGen + */ +public class UserBhv extends BsUserBhv { + +} diff --git a/src/main/java/org/codelibs/fess/es/exentity/BoostDocumentRule.java b/src/main/java/org/codelibs/fess/es/exentity/BoostDocumentRule.java index 5e262f07b..300abd0b3 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/BoostDocumentRule.java +++ b/src/main/java/org/codelibs/fess/es/exentity/BoostDocumentRule.java @@ -15,7 +15,7 @@ public class BoostDocumentRule extends BsBoostDocumentRule { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class BoostDocumentRule extends BsBoostDocumentRule { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/ClickLog.java b/src/main/java/org/codelibs/fess/es/exentity/ClickLog.java index 6e8a47219..1e0ff9d51 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/ClickLog.java +++ b/src/main/java/org/codelibs/fess/es/exentity/ClickLog.java @@ -82,7 +82,7 @@ public class ClickLog extends BsClickLog { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -90,7 +90,7 @@ public class ClickLog extends BsClickLog { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } diff --git a/src/main/java/org/codelibs/fess/es/exentity/CrawlingSession.java b/src/main/java/org/codelibs/fess/es/exentity/CrawlingSession.java index cfc087b15..efb10a037 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/CrawlingSession.java +++ b/src/main/java/org/codelibs/fess/es/exentity/CrawlingSession.java @@ -22,7 +22,7 @@ public class CrawlingSession extends BsCrawlingSession { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -30,7 +30,7 @@ public class CrawlingSession extends BsCrawlingSession { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/CrawlingSessionInfo.java b/src/main/java/org/codelibs/fess/es/exentity/CrawlingSessionInfo.java index 3b07695e9..aee736580 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/CrawlingSessionInfo.java +++ b/src/main/java/org/codelibs/fess/es/exentity/CrawlingSessionInfo.java @@ -6,8 +6,7 @@ import org.codelibs.fess.es.bsentity.BsCrawlingSessionInfo; import org.codelibs.fess.es.exbhv.CrawlingSessionBhv; import org.codelibs.fess.util.ComponentUtil; import org.dbflute.optional.OptionalEntity; -import org.seasar.struts.util.MessageResourcesUtil; -import org.seasar.struts.util.RequestUtil; +import org.lastaflute.web.util.LaRequestUtil; /** * @author FreeGen @@ -24,7 +23,7 @@ public class CrawlingSessionInfo extends BsCrawlingSessionInfo { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -32,7 +31,7 @@ public class CrawlingSessionInfo extends BsCrawlingSessionInfo { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } @@ -47,8 +46,8 @@ public class CrawlingSessionInfo extends BsCrawlingSessionInfo { } public String getKeyMsg() { - final Locale locale = RequestUtil.getRequest().getLocale(); - final String message = MessageResourcesUtil.getMessage(locale, "labels.crawling_session_" + getKey()); + final Locale locale = LaRequestUtil.getRequest().getLocale(); + final String message = ComponentUtil.getMessageManager().getMessage(locale, "labels.crawling_session_" + getKey()); if (message == null || message.startsWith("???")) { return getKey(); } diff --git a/src/main/java/org/codelibs/fess/es/exentity/DataConfig.java b/src/main/java/org/codelibs/fess/es/exentity/DataConfig.java index f130b9257..79300d71c 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/DataConfig.java +++ b/src/main/java/org/codelibs/fess/es/exentity/DataConfig.java @@ -367,7 +367,7 @@ public class DataConfig extends BsDataConfig implements CrawlingConfig { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -375,7 +375,7 @@ public class DataConfig extends BsDataConfig implements CrawlingConfig { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/DataConfigToLabel.java b/src/main/java/org/codelibs/fess/es/exentity/DataConfigToLabel.java index 4a54549d9..0156ee3f2 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/DataConfigToLabel.java +++ b/src/main/java/org/codelibs/fess/es/exentity/DataConfigToLabel.java @@ -15,7 +15,7 @@ public class DataConfigToLabel extends BsDataConfigToLabel { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class DataConfigToLabel extends BsDataConfigToLabel { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/DataConfigToRole.java b/src/main/java/org/codelibs/fess/es/exentity/DataConfigToRole.java index 160ec1b5d..095221d1d 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/DataConfigToRole.java +++ b/src/main/java/org/codelibs/fess/es/exentity/DataConfigToRole.java @@ -15,7 +15,7 @@ public class DataConfigToRole extends BsDataConfigToRole { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class DataConfigToRole extends BsDataConfigToRole { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/EventLog.java b/src/main/java/org/codelibs/fess/es/exentity/EventLog.java new file mode 100644 index 000000000..5d5fe26ca --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/exentity/EventLog.java @@ -0,0 +1,11 @@ +package org.codelibs.fess.es.exentity; + +import org.codelibs.fess.es.bsentity.BsEventLog; + +/** + * @author FreeGen + */ +public class EventLog extends BsEventLog { + + private static final long serialVersionUID = 1L; +} diff --git a/src/main/java/org/codelibs/fess/es/exentity/FailureUrl.java b/src/main/java/org/codelibs/fess/es/exentity/FailureUrl.java index c970c28b1..af8fb8569 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/FailureUrl.java +++ b/src/main/java/org/codelibs/fess/es/exentity/FailureUrl.java @@ -15,7 +15,7 @@ public class FailureUrl extends BsFailureUrl { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class FailureUrl extends BsFailureUrl { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/FavoriteLog.java b/src/main/java/org/codelibs/fess/es/exentity/FavoriteLog.java index 10c17fcc8..1d5467563 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/FavoriteLog.java +++ b/src/main/java/org/codelibs/fess/es/exentity/FavoriteLog.java @@ -15,7 +15,7 @@ public class FavoriteLog extends BsFavoriteLog { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class FavoriteLog extends BsFavoriteLog { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/FileAuthentication.java b/src/main/java/org/codelibs/fess/es/exentity/FileAuthentication.java index 7729deab0..1b2ccea33 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/FileAuthentication.java +++ b/src/main/java/org/codelibs/fess/es/exentity/FileAuthentication.java @@ -1,7 +1,7 @@ package org.codelibs.fess.es.exentity; +import org.codelibs.fess.app.service.FileConfigService; import org.codelibs.fess.es.bsentity.BsFileAuthentication; -import org.codelibs.fess.service.FileConfigService; import org.codelibs.fess.util.ComponentUtil; /** @@ -18,7 +18,7 @@ public class FileAuthentication extends BsFileAuthentication { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -26,7 +26,7 @@ public class FileAuthentication extends BsFileAuthentication { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } diff --git a/src/main/java/org/codelibs/fess/es/exentity/FileConfig.java b/src/main/java/org/codelibs/fess/es/exentity/FileConfig.java index b9e939163..7ef16f246 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/FileConfig.java +++ b/src/main/java/org/codelibs/fess/es/exentity/FileConfig.java @@ -9,20 +9,20 @@ import java.util.regex.Pattern; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; +import org.codelibs.fess.app.service.FileAuthenticationService; import org.codelibs.fess.es.bsentity.BsFileConfig; import org.codelibs.fess.es.exbhv.FileConfigToLabelBhv; import org.codelibs.fess.es.exbhv.FileConfigToRoleBhv; import org.codelibs.fess.es.exbhv.LabelTypeBhv; import org.codelibs.fess.es.exbhv.RoleTypeBhv; import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.service.FileAuthenticationService; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.fess.util.ParameterUtil; import org.codelibs.robot.client.S2RobotClientFactory; import org.codelibs.robot.client.smb.SmbAuthentication; import org.codelibs.robot.client.smb.SmbClient; import org.dbflute.cbean.result.ListResultBean; -import org.seasar.framework.container.SingletonS2Container; +import org.lastaflute.di.core.SingletonLaContainer; /** * @author FreeGen @@ -229,7 +229,7 @@ public class FileConfig extends BsFileConfig implements CrawlingConfig { @Override public void initializeClientFactory(final S2RobotClientFactory clientFactory) { - final FileAuthenticationService fileAuthenticationService = SingletonS2Container.getComponent(FileAuthenticationService.class); + final FileAuthenticationService fileAuthenticationService = SingletonLaContainer.getComponent(FileAuthenticationService.class); // Parameters final Map paramMap = new HashMap(); @@ -279,7 +279,7 @@ public class FileConfig extends BsFileConfig implements CrawlingConfig { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -287,7 +287,7 @@ public class FileConfig extends BsFileConfig implements CrawlingConfig { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/FileConfigToLabel.java b/src/main/java/org/codelibs/fess/es/exentity/FileConfigToLabel.java index 22ff4bb5c..65c4420db 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/FileConfigToLabel.java +++ b/src/main/java/org/codelibs/fess/es/exentity/FileConfigToLabel.java @@ -15,7 +15,7 @@ public class FileConfigToLabel extends BsFileConfigToLabel { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class FileConfigToLabel extends BsFileConfigToLabel { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/FileConfigToRole.java b/src/main/java/org/codelibs/fess/es/exentity/FileConfigToRole.java index d87d8d832..a40535397 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/FileConfigToRole.java +++ b/src/main/java/org/codelibs/fess/es/exentity/FileConfigToRole.java @@ -15,7 +15,7 @@ public class FileConfigToRole extends BsFileConfigToRole { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class FileConfigToRole extends BsFileConfigToRole { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/Group.java b/src/main/java/org/codelibs/fess/es/exentity/Group.java new file mode 100644 index 000000000..0a9d152ee --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/exentity/Group.java @@ -0,0 +1,11 @@ +package org.codelibs.fess.es.exentity; + +import org.codelibs.fess.es.bsentity.BsGroup; + +/** + * @author FreeGen + */ +public class Group extends BsGroup { + + private static final long serialVersionUID = 1L; +} diff --git a/src/main/java/org/codelibs/fess/es/exentity/JobLog.java b/src/main/java/org/codelibs/fess/es/exentity/JobLog.java index 17c8c7ed2..9f8b38666 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/JobLog.java +++ b/src/main/java/org/codelibs/fess/es/exentity/JobLog.java @@ -36,7 +36,7 @@ public class JobLog extends BsJobLog { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -44,7 +44,7 @@ public class JobLog extends BsJobLog { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/KeyMatch.java b/src/main/java/org/codelibs/fess/es/exentity/KeyMatch.java index 96999c0be..953e92d6b 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/KeyMatch.java +++ b/src/main/java/org/codelibs/fess/es/exentity/KeyMatch.java @@ -15,7 +15,7 @@ public class KeyMatch extends BsKeyMatch { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class KeyMatch extends BsKeyMatch { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/LabelToRole.java b/src/main/java/org/codelibs/fess/es/exentity/LabelToRole.java index de2f54a35..170afbbc5 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/LabelToRole.java +++ b/src/main/java/org/codelibs/fess/es/exentity/LabelToRole.java @@ -15,7 +15,7 @@ public class LabelToRole extends BsLabelToRole { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class LabelToRole extends BsLabelToRole { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/LabelType.java b/src/main/java/org/codelibs/fess/es/exentity/LabelType.java index c4371c4c9..e15f3d00a 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/LabelType.java +++ b/src/main/java/org/codelibs/fess/es/exentity/LabelType.java @@ -70,7 +70,7 @@ public class LabelType extends BsLabelType { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -78,7 +78,7 @@ public class LabelType extends BsLabelType { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/OverlappingHost.java b/src/main/java/org/codelibs/fess/es/exentity/OverlappingHost.java index fa1074a88..f6466648d 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/OverlappingHost.java +++ b/src/main/java/org/codelibs/fess/es/exentity/OverlappingHost.java @@ -15,7 +15,7 @@ public class OverlappingHost extends BsOverlappingHost { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class OverlappingHost extends BsOverlappingHost { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } diff --git a/src/main/java/org/codelibs/fess/es/exentity/PathMapping.java b/src/main/java/org/codelibs/fess/es/exentity/PathMapping.java index e16a848e5..e3a33d828 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/PathMapping.java +++ b/src/main/java/org/codelibs/fess/es/exentity/PathMapping.java @@ -20,7 +20,7 @@ public class PathMapping extends BsPathMapping { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -28,7 +28,7 @@ public class PathMapping extends BsPathMapping { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } diff --git a/src/main/java/org/codelibs/fess/es/exentity/RequestHeader.java b/src/main/java/org/codelibs/fess/es/exentity/RequestHeader.java index d6dd50492..263640e25 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/RequestHeader.java +++ b/src/main/java/org/codelibs/fess/es/exentity/RequestHeader.java @@ -1,7 +1,7 @@ package org.codelibs.fess.es.exentity; +import org.codelibs.fess.app.service.WebConfigService; import org.codelibs.fess.es.bsentity.BsRequestHeader; -import org.codelibs.fess.service.WebConfigService; import org.codelibs.fess.util.ComponentUtil; /** @@ -18,7 +18,7 @@ public class RequestHeader extends BsRequestHeader { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -26,7 +26,7 @@ public class RequestHeader extends BsRequestHeader { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } diff --git a/src/main/java/org/codelibs/fess/es/exentity/Role.java b/src/main/java/org/codelibs/fess/es/exentity/Role.java new file mode 100644 index 000000000..bd5ecd039 --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/exentity/Role.java @@ -0,0 +1,11 @@ +package org.codelibs.fess.es.exentity; + +import org.codelibs.fess.es.bsentity.BsRole; + +/** + * @author FreeGen + */ +public class Role extends BsRole { + + private static final long serialVersionUID = 1L; +} diff --git a/src/main/java/org/codelibs/fess/es/exentity/RoleType.java b/src/main/java/org/codelibs/fess/es/exentity/RoleType.java index 02a4e3033..084798df3 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/RoleType.java +++ b/src/main/java/org/codelibs/fess/es/exentity/RoleType.java @@ -15,7 +15,7 @@ public class RoleType extends BsRoleType { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class RoleType extends BsRoleType { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/ScheduledJob.java b/src/main/java/org/codelibs/fess/es/exentity/ScheduledJob.java index 72caa9290..5fb94a52b 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/ScheduledJob.java +++ b/src/main/java/org/codelibs/fess/es/exentity/ScheduledJob.java @@ -39,7 +39,7 @@ public class ScheduledJob extends BsScheduledJob { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -47,7 +47,7 @@ public class ScheduledJob extends BsScheduledJob { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/SearchFieldLog.java b/src/main/java/org/codelibs/fess/es/exentity/SearchFieldLog.java index 822d42604..0790d3b3b 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/SearchFieldLog.java +++ b/src/main/java/org/codelibs/fess/es/exentity/SearchFieldLog.java @@ -15,7 +15,7 @@ public class SearchFieldLog extends BsSearchFieldLog { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class SearchFieldLog extends BsSearchFieldLog { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/SearchLog.java b/src/main/java/org/codelibs/fess/es/exentity/SearchLog.java index dd643fa93..5b56b8615 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/SearchLog.java +++ b/src/main/java/org/codelibs/fess/es/exentity/SearchLog.java @@ -32,7 +32,7 @@ public class SearchLog extends BsSearchLog { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -40,11 +40,11 @@ public class SearchLog extends BsSearchLog { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } - public void setClickLogList(List clickLogList) { + public void setClickLogList(final List clickLogList) { this.clickLogList = clickLogList; } @@ -73,10 +73,6 @@ public class SearchLog extends BsSearchLog { addSearchFieldLogValue(Constants.SEARCH_FIELD_LOG_SEARCH_QUERY, query); } - public void setSolrQuery(final String solrQuery) { - addSearchFieldLogValue(Constants.SEARCH_FIELD_LOG_SOLR_QUERY, solrQuery); - } - public OptionalEntity getUserInfo() { if (userInfo == null) { final UserInfoBhv userInfoBhv = ComponentUtil.getComponent(UserInfoBhv.class); @@ -87,7 +83,7 @@ public class SearchLog extends BsSearchLog { return userInfo; } - public void setUserInfo(OptionalEntity userInfo) { + public void setUserInfo(final OptionalEntity userInfo) { this.userInfo = userInfo; } diff --git a/src/main/java/org/codelibs/fess/es/exentity/SuggestBadWord.java b/src/main/java/org/codelibs/fess/es/exentity/SuggestBadWord.java index 599cc8311..f8679c6c4 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/SuggestBadWord.java +++ b/src/main/java/org/codelibs/fess/es/exentity/SuggestBadWord.java @@ -15,7 +15,7 @@ public class SuggestBadWord extends BsSuggestBadWord { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class SuggestBadWord extends BsSuggestBadWord { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/SuggestElevateWord.java b/src/main/java/org/codelibs/fess/es/exentity/SuggestElevateWord.java index 3cbd3d226..f1406478d 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/SuggestElevateWord.java +++ b/src/main/java/org/codelibs/fess/es/exentity/SuggestElevateWord.java @@ -15,7 +15,7 @@ public class SuggestElevateWord extends BsSuggestElevateWord { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class SuggestElevateWord extends BsSuggestElevateWord { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/User.java b/src/main/java/org/codelibs/fess/es/exentity/User.java new file mode 100644 index 000000000..f4b87d30f --- /dev/null +++ b/src/main/java/org/codelibs/fess/es/exentity/User.java @@ -0,0 +1,11 @@ +package org.codelibs.fess.es.exentity; + +import org.codelibs.fess.es.bsentity.BsUser; + +/** + * @author FreeGen + */ +public class User extends BsUser { + + private static final long serialVersionUID = 1L; +} diff --git a/src/main/java/org/codelibs/fess/es/exentity/UserInfo.java b/src/main/java/org/codelibs/fess/es/exentity/UserInfo.java index 6fdae1e01..f1aba8704 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/UserInfo.java +++ b/src/main/java/org/codelibs/fess/es/exentity/UserInfo.java @@ -15,7 +15,7 @@ public class UserInfo extends BsUserInfo { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class UserInfo extends BsUserInfo { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/WebAuthentication.java b/src/main/java/org/codelibs/fess/es/exentity/WebAuthentication.java index be68dc6b0..481db5aed 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/WebAuthentication.java +++ b/src/main/java/org/codelibs/fess/es/exentity/WebAuthentication.java @@ -12,14 +12,14 @@ import org.apache.http.impl.auth.DigestScheme; import org.apache.http.impl.auth.NTLMScheme; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; +import org.codelibs.fess.app.service.WebConfigService; import org.codelibs.fess.es.bsentity.BsWebAuthentication; -import org.codelibs.fess.service.WebConfigService; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.fess.util.ParameterUtil; -import org.codelibs.robot.RobotSystemException; import org.codelibs.robot.client.http.Authentication; import org.codelibs.robot.client.http.impl.AuthenticationImpl; import org.codelibs.robot.client.http.ntlm.JcifsEngine; +import org.codelibs.robot.exception.RobotSystemException; /** * @author FreeGen @@ -99,7 +99,7 @@ public class WebAuthentication extends BsWebAuthentication { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -107,7 +107,7 @@ public class WebAuthentication extends BsWebAuthentication { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/WebConfig.java b/src/main/java/org/codelibs/fess/es/exentity/WebConfig.java index ec0014bc0..feee2c79b 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/WebConfig.java +++ b/src/main/java/org/codelibs/fess/es/exentity/WebConfig.java @@ -9,20 +9,20 @@ import java.util.regex.Pattern; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; +import org.codelibs.fess.app.service.RequestHeaderService; +import org.codelibs.fess.app.service.WebAuthenticationService; import org.codelibs.fess.es.bsentity.BsWebConfig; import org.codelibs.fess.es.exbhv.LabelTypeBhv; import org.codelibs.fess.es.exbhv.RoleTypeBhv; import org.codelibs.fess.es.exbhv.WebConfigToLabelBhv; import org.codelibs.fess.es.exbhv.WebConfigToRoleBhv; -import org.codelibs.fess.service.RequestHeaderService; -import org.codelibs.fess.service.WebAuthenticationService; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.fess.util.ParameterUtil; import org.codelibs.robot.client.S2RobotClientFactory; import org.codelibs.robot.client.http.Authentication; import org.codelibs.robot.client.http.HcHttpClient; import org.dbflute.cbean.result.ListResultBean; -import org.seasar.framework.container.SingletonS2Container; +import org.lastaflute.di.core.SingletonLaContainer; /** * @author FreeGen @@ -233,8 +233,8 @@ public class WebConfig extends BsWebConfig implements CrawlingConfig { @Override public void initializeClientFactory(final S2RobotClientFactory clientFactory) { - final WebAuthenticationService webAuthenticationService = SingletonS2Container.getComponent(WebAuthenticationService.class); - final RequestHeaderService requestHeaderService = SingletonS2Container.getComponent(RequestHeaderService.class); + final WebAuthenticationService webAuthenticationService = SingletonLaContainer.getComponent(WebAuthenticationService.class); + final RequestHeaderService requestHeaderService = SingletonLaContainer.getComponent(RequestHeaderService.class); // HttpClient Parameters final Map paramMap = new HashMap(); @@ -286,7 +286,7 @@ public class WebConfig extends BsWebConfig implements CrawlingConfig { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -294,7 +294,7 @@ public class WebConfig extends BsWebConfig implements CrawlingConfig { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/WebConfigToLabel.java b/src/main/java/org/codelibs/fess/es/exentity/WebConfigToLabel.java index 2b3fade3a..fa3c54a7a 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/WebConfigToLabel.java +++ b/src/main/java/org/codelibs/fess/es/exentity/WebConfigToLabel.java @@ -15,7 +15,7 @@ public class WebConfigToLabel extends BsWebConfigToLabel { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class WebConfigToLabel extends BsWebConfigToLabel { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/es/exentity/WebConfigToRole.java b/src/main/java/org/codelibs/fess/es/exentity/WebConfigToRole.java index c5ee3978d..bf6bcb8b4 100644 --- a/src/main/java/org/codelibs/fess/es/exentity/WebConfigToRole.java +++ b/src/main/java/org/codelibs/fess/es/exentity/WebConfigToRole.java @@ -15,7 +15,7 @@ public class WebConfigToRole extends BsWebConfigToRole { } @Override - public void setId(String id) { + public void setId(final String id) { asDocMeta().id(id); } @@ -23,7 +23,7 @@ public class WebConfigToRole extends BsWebConfigToRole { return asDocMeta().version(); } - public void setVersionNo(Long version) { + public void setVersionNo(final Long version) { asDocMeta().version(version); } } diff --git a/src/main/java/org/codelibs/fess/FessSystemException.java b/src/main/java/org/codelibs/fess/exception/FessSystemException.java similarity index 96% rename from src/main/java/org/codelibs/fess/FessSystemException.java rename to src/main/java/org/codelibs/fess/exception/FessSystemException.java index e222964d9..5f0fc2c19 100644 --- a/src/main/java/org/codelibs/fess/FessSystemException.java +++ b/src/main/java/org/codelibs/fess/exception/FessSystemException.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess; +package org.codelibs.fess.exception; public class FessSystemException extends RuntimeException { diff --git a/src/main/java/org/codelibs/fess/InvalidQueryException.java b/src/main/java/org/codelibs/fess/exception/InvalidQueryException.java similarity index 67% rename from src/main/java/org/codelibs/fess/InvalidQueryException.java rename to src/main/java/org/codelibs/fess/exception/InvalidQueryException.java index cd9349407..12d7ba8b8 100644 --- a/src/main/java/org/codelibs/fess/InvalidQueryException.java +++ b/src/main/java/org/codelibs/fess/exception/InvalidQueryException.java @@ -14,20 +14,23 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess; +package org.codelibs.fess.exception; + +import org.codelibs.fess.mylasta.action.FessMessages; +import org.lastaflute.web.validation.VaMessenger; public class InvalidQueryException extends FessSystemException { private static final long serialVersionUID = 1L; - private final String messageCode; + private final VaMessenger messageCode; - public InvalidQueryException(final String messageCode, final String message, final Throwable cause) { + public InvalidQueryException(final VaMessenger messageCode, final String message, final Throwable cause) { super(message, cause); this.messageCode = messageCode; } - public InvalidQueryException(final String messageCode, final String message) { + public InvalidQueryException(final VaMessenger messageCode, final String message) { super(message); this.messageCode = messageCode; } @@ -35,7 +38,7 @@ public class InvalidQueryException extends FessSystemException { /** * @return the messageCode */ - public String getMessageCode() { + public VaMessenger getMessageCode() { return messageCode; } diff --git a/src/main/java/org/codelibs/fess/ResultOffsetExceededException.java b/src/main/java/org/codelibs/fess/exception/ResultOffsetExceededException.java similarity index 95% rename from src/main/java/org/codelibs/fess/ResultOffsetExceededException.java rename to src/main/java/org/codelibs/fess/exception/ResultOffsetExceededException.java index d98084c8b..677ee54b0 100644 --- a/src/main/java/org/codelibs/fess/ResultOffsetExceededException.java +++ b/src/main/java/org/codelibs/fess/exception/ResultOffsetExceededException.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess; +package org.codelibs.fess.exception; public class ResultOffsetExceededException extends FessSystemException { private static final long serialVersionUID = 1L; diff --git a/src/main/java/org/codelibs/fess/UnsupportedSearchException.java b/src/main/java/org/codelibs/fess/exception/UnsupportedSearchException.java similarity index 95% rename from src/main/java/org/codelibs/fess/UnsupportedSearchException.java rename to src/main/java/org/codelibs/fess/exception/UnsupportedSearchException.java index 22d4877db..fea253d90 100644 --- a/src/main/java/org/codelibs/fess/UnsupportedSearchException.java +++ b/src/main/java/org/codelibs/fess/exception/UnsupportedSearchException.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess; +package org.codelibs.fess.exception; public class UnsupportedSearchException extends FessSystemException { diff --git a/src/main/java/org/codelibs/fess/WebApiException.java b/src/main/java/org/codelibs/fess/exception/WebApiException.java similarity index 97% rename from src/main/java/org/codelibs/fess/WebApiException.java rename to src/main/java/org/codelibs/fess/exception/WebApiException.java index d49334374..cf111beb7 100644 --- a/src/main/java/org/codelibs/fess/WebApiException.java +++ b/src/main/java/org/codelibs/fess/exception/WebApiException.java @@ -14,7 +14,7 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess; +package org.codelibs.fess.exception; public class WebApiException extends FessSystemException { diff --git a/src/main/java/org/codelibs/fess/exec/Crawler.java b/src/main/java/org/codelibs/fess/exec/Crawler.java index 70057cdaf..63d7171c7 100644 --- a/src/main/java/org/codelibs/fess/exec/Crawler.java +++ b/src/main/java/org/codelibs/fess/exec/Crawler.java @@ -29,43 +29,31 @@ import java.util.List; import java.util.Map; import javax.annotation.Resource; -import javax.servlet.ServletContext; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; import org.codelibs.core.CoreLibConstants; import org.codelibs.core.lang.StringUtil; import org.codelibs.core.misc.DynamicProperties; import org.codelibs.fess.Constants; -import org.codelibs.fess.client.FessEsClient; +import org.codelibs.fess.app.service.CrawlingSessionService; +import org.codelibs.fess.app.service.PathMappingService; +import org.codelibs.fess.es.client.FessEsClient; import org.codelibs.fess.helper.CrawlingSessionHelper; import org.codelibs.fess.helper.DataIndexHelper; -import org.codelibs.fess.helper.DatabaseHelper; import org.codelibs.fess.helper.FieldHelper; import org.codelibs.fess.helper.MailHelper; import org.codelibs.fess.helper.OverlappingHostHelper; import org.codelibs.fess.helper.PathMappingHelper; import org.codelibs.fess.helper.WebFsIndexHelper; -import org.codelibs.fess.screenshot.ScreenShotManager; -import org.codelibs.fess.service.CrawlingSessionService; -import org.codelibs.fess.service.PathMappingService; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.fess.util.ResourceUtil; +import org.codelibs.robot.client.EsClient; import org.elasticsearch.index.query.QueryBuilder; import org.elasticsearch.index.query.QueryBuilders; import org.kohsuke.args4j.CmdLineException; import org.kohsuke.args4j.CmdLineParser; import org.kohsuke.args4j.Option; -import org.seasar.framework.container.ExternalContext; -import org.seasar.framework.container.S2Container; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.framework.container.annotation.tiger.Binding; -import org.seasar.framework.container.annotation.tiger.BindingType; -import org.seasar.framework.container.factory.SingletonS2ContainerFactory; -import org.seasar.framework.container.servlet.SingletonS2ContainerInitializer; -import org.seasar.framework.mock.servlet.MockHttpServletRequestImpl; -import org.seasar.framework.mock.servlet.MockHttpServletResponseImpl; -import org.seasar.framework.mock.servlet.MockServletContextImpl; +import org.lastaflute.di.core.SingletonLaContainer; +import org.lastaflute.di.core.factory.SingletonLaContainerFactory; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -89,10 +77,6 @@ public class Crawler implements Serializable { @Resource protected FessEsClient fessEsClient; - @Binding(bindingType = BindingType.MAY) - @Resource - protected ScreenShotManager screenShotManager; - @Resource protected WebFsIndexHelper webFsIndexHelper; @@ -188,28 +172,27 @@ public class Crawler implements Serializable { return; } + final String transportAddresses = System.getProperty(Constants.FESS_ES_TRANSPORT_ADDRESSES); + if (StringUtil.isNotBlank(transportAddresses)) { + System.setProperty(EsClient.TRANSPORT_ADDRESSES, transportAddresses); + } + final String clusterName = System.getProperty(Constants.FESS_ES_CLUSTER_NAME); + if (StringUtil.isNotBlank(clusterName)) { + System.setProperty(EsClient.CLUSTER_NAME, clusterName); + } + int exitCode; try { - final ServletContext servletContext = new MockServletContextImpl("/fess"); - final HttpServletRequest request = new MockHttpServletRequestImpl(servletContext, "/crawler"); - final HttpServletResponse response = new MockHttpServletResponseImpl(request); - final SingletonS2ContainerInitializer initializer = new SingletonS2ContainerInitializer(); - initializer.setConfigPath("app.dicon"); - initializer.setApplication(servletContext); - initializer.initialize(); - - final S2Container container = SingletonS2ContainerFactory.getContainer(); - final ExternalContext externalContext = container.getExternalContext(); - externalContext.setRequest(request); - externalContext.setResponse(response); + SingletonLaContainerFactory.setConfigPath("app.xml"); + SingletonLaContainerFactory.init(); final Thread shutdownCallback = new Thread("ShutdownHook") { @Override public void run() { if (logger.isDebugEnabled()) { - logger.debug("Destroying S2Container.."); + logger.debug("Destroying LaContainer.."); } - SingletonS2ContainerFactory.destroy(); + SingletonLaContainerFactory.destroy(); } }; Runtime.getRuntime().addShutdownHook(shutdownCallback); @@ -219,7 +202,7 @@ public class Crawler implements Serializable { logger.error("Crawler does not work correctly.", t); exitCode = Constants.EXIT_FAIL; } finally { - SingletonS2ContainerFactory.destroy(); + SingletonLaContainerFactory.destroy(); } if (exitCode != Constants.EXIT_OK) { @@ -228,10 +211,7 @@ public class Crawler implements Serializable { } private static int process(final Options options) { - final Crawler crawler = SingletonS2Container.getComponent(Crawler.class); - - final DatabaseHelper databaseHelper = ComponentUtil.getDatabaseHelper(); - databaseHelper.optimize(); + final Crawler crawler = SingletonLaContainer.getComponent(Crawler.class); if (StringUtil.isBlank(options.sessionId)) { // use a default session id @@ -282,7 +262,6 @@ public class Crawler implements Serializable { } catch (final Exception e) { logger.warn("Failed to store crawling information.", e); } - databaseHelper.optimize(); final Map infoMap = crawlingSessionHelper.getInfoMap(options.sessionId); diff --git a/src/main/java/org/codelibs/fess/filter/AdLoginInfoFilter.java b/src/main/java/org/codelibs/fess/filter/AdLoginInfoFilter.java index 525cf8023..5e489a504 100644 --- a/src/main/java/org/codelibs/fess/filter/AdLoginInfoFilter.java +++ b/src/main/java/org/codelibs/fess/filter/AdLoginInfoFilter.java @@ -31,11 +31,11 @@ import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpSession; +import org.codelibs.core.lang.StringUtil; +import org.codelibs.fess.Constants; import org.codelibs.fess.entity.LoginInfo; import org.codelibs.fess.helper.AdRoleHelper; import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.sastruts.core.SSCConstants; -import org.seasar.framework.util.StringUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -84,12 +84,12 @@ public class AdLoginInfoFilter implements Filter { } } - LoginInfo loginInfo = (LoginInfo) session.getAttribute(SSCConstants.USER_INFO); + LoginInfo loginInfo = (LoginInfo) session.getAttribute(Constants.USER_INFO); if (loginInfo == null) { loginInfo = new LoginInfo(); loginInfo.setUsername(userId); updateRoleList(userId, loginInfo); - session.setAttribute(SSCConstants.USER_INFO, loginInfo); + session.setAttribute(Constants.USER_INFO, loginInfo); } else { final long now = System.currentTimeMillis(); if (now - loginInfo.getUpdatedTime() > updateInterval) { diff --git a/src/main/java/org/codelibs/fess/filter/AdminAuthFilter.java b/src/main/java/org/codelibs/fess/filter/AdminAuthFilter.java index 5eab12902..7b84fc6f9 100644 --- a/src/main/java/org/codelibs/fess/filter/AdminAuthFilter.java +++ b/src/main/java/org/codelibs/fess/filter/AdminAuthFilter.java @@ -19,10 +19,9 @@ package org.codelibs.fess.filter; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpSession; +import org.codelibs.fess.Constants; import org.codelibs.fess.entity.LoginInfo; -import org.codelibs.sastruts.core.SSCConstants; -import org.codelibs.sastruts.core.entity.UserInfo; -import org.codelibs.sastruts.core.filter.AuthFilter; +import org.codelibs.fess.entity.UserInfo; public class AdminAuthFilter extends AuthFilter { @Override @@ -31,7 +30,7 @@ public class AdminAuthFilter extends AuthFilter { if (session == null) { return null; } - final Object obj = session.getAttribute(SSCConstants.USER_INFO); + final Object obj = session.getAttribute(Constants.USER_INFO); if (obj instanceof LoginInfo) { final LoginInfo loginInfo = (LoginInfo) obj; if (loginInfo.isAdministrator()) { diff --git a/src/main/java/org/codelibs/sastruts/core/filter/AuthFilter.java b/src/main/java/org/codelibs/fess/filter/AuthFilter.java similarity index 91% rename from src/main/java/org/codelibs/sastruts/core/filter/AuthFilter.java rename to src/main/java/org/codelibs/fess/filter/AuthFilter.java index 259176158..9cf9bac67 100644 --- a/src/main/java/org/codelibs/sastruts/core/filter/AuthFilter.java +++ b/src/main/java/org/codelibs/fess/filter/AuthFilter.java @@ -13,7 +13,7 @@ * either express or implied. See the License for the specific language * governing permissions and limitations under the License. */ -package org.codelibs.sastruts.core.filter; +package org.codelibs.fess.filter; import java.io.IOException; import java.net.URLEncoder; @@ -34,17 +34,17 @@ import javax.servlet.http.HttpServletResponse; import org.codelibs.core.CoreLibConstants; import org.codelibs.core.crypto.CachedCipher; -import org.codelibs.sastruts.core.SSCConstants; -import org.codelibs.sastruts.core.entity.UserInfo; -import org.codelibs.sastruts.core.util.ActivityUtil; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.framework.util.StringUtil; +import org.codelibs.core.lang.StringUtil; +import org.codelibs.fess.Constants; +import org.codelibs.fess.entity.UserInfo; +import org.codelibs.fess.util.ActivityUtil; +import org.lastaflute.di.core.SingletonLaContainer; /** * A filter implementation to process a container based authentication. - * + * * @author shinsuke - * + * */ public class AuthFilter implements Filter { @@ -159,7 +159,7 @@ public class AuthFilter implements Filter { } protected UserInfo getUserInfo(final HttpServletRequest req) { - final Object obj = req.getSession().getAttribute(SSCConstants.USER_INFO); + final Object obj = req.getSession().getAttribute(Constants.USER_INFO); if (obj instanceof UserInfo) { return (UserInfo) obj; } @@ -167,13 +167,13 @@ public class AuthFilter implements Filter { } protected CachedCipher getCachedCipher() { - return SingletonS2Container.getComponent(cipherName); + return SingletonLaContainer.getComponent(cipherName); } protected static class AuthHttpServletRequest extends HttpServletRequestWrapper { protected UserInfo userInfo; - protected AuthHttpServletRequest(HttpServletRequest request, UserInfo userInfo) { + protected AuthHttpServletRequest(final HttpServletRequest request, final UserInfo userInfo) { super(request); this.userInfo = userInfo; } @@ -184,7 +184,7 @@ public class AuthFilter implements Filter { } @Override - public boolean isUserInRole(String role) { + public boolean isUserInRole(final String role) { return userInfo.isUserInRole(role); } diff --git a/src/main/java/org/codelibs/fess/filter/FessEncodingFilter.java b/src/main/java/org/codelibs/fess/filter/EncodingFilter.java similarity index 94% rename from src/main/java/org/codelibs/fess/filter/FessEncodingFilter.java rename to src/main/java/org/codelibs/fess/filter/EncodingFilter.java index 2fddd1917..e2e327593 100644 --- a/src/main/java/org/codelibs/fess/filter/FessEncodingFilter.java +++ b/src/main/java/org/codelibs/fess/filter/EncodingFilter.java @@ -24,6 +24,7 @@ import java.util.List; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; +import javax.servlet.Filter; import javax.servlet.FilterChain; import javax.servlet.FilterConfig; import javax.servlet.ServletContext; @@ -36,9 +37,9 @@ import javax.servlet.http.HttpServletResponse; import org.apache.commons.codec.DecoderException; import org.apache.commons.codec.net.URLCodec; import org.codelibs.core.lang.StringUtil; -import org.seasar.extension.filter.EncodingFilter; +import org.lastaflute.web.servlet.filter.LastaPrepareFilter; -public class FessEncodingFilter extends EncodingFilter { +public class EncodingFilter implements Filter { public static String ENCODING_MAP = "encodingRules"; protected Map encodingMap = new ConcurrentHashMap<>(); @@ -51,12 +52,11 @@ public class FessEncodingFilter extends EncodingFilter { @Override public void init(final FilterConfig config) throws ServletException { - super.init(config); servletContext = config.getServletContext(); - encoding = config.getInitParameter(ENCODING); + encoding = config.getInitParameter(LastaPrepareFilter.ENCODING_KEY); if (encoding == null) { - encoding = DEFAULT_ENCODING; + encoding = LastaPrepareFilter.DEFAULT_ENCODING; } // ex. sjis:Shift_JIS,eucjp:EUC-JP @@ -117,7 +117,7 @@ public class FessEncodingFilter extends EncodingFilter { } } - super.doFilter(request, response, chain); + chain.doFilter(request, response); } protected Map getParameterMapFromQueryString(final HttpServletRequest request, final String enc) throws IOException { @@ -168,4 +168,9 @@ public class FessEncodingFilter extends EncodingFilter { } return paramMap; } + + @Override + public void destroy() { + // nothing + } } diff --git a/src/main/java/org/codelibs/fess/filter/LoginInfoFilter.java b/src/main/java/org/codelibs/fess/filter/LoginInfoFilter.java index 972b874ec..fda6934f4 100644 --- a/src/main/java/org/codelibs/fess/filter/LoginInfoFilter.java +++ b/src/main/java/org/codelibs/fess/filter/LoginInfoFilter.java @@ -29,10 +29,10 @@ import javax.servlet.ServletResponse; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpSession; +import org.codelibs.fess.Constants; import org.codelibs.fess.entity.LoginInfo; import org.codelibs.fess.helper.SystemHelper; import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.sastruts.core.SSCConstants; // TODO refactoring... public class LoginInfoFilter implements Filter { @@ -51,10 +51,10 @@ public class LoginInfoFilter implements Filter { ServletException { final HttpServletRequest hRequest = (HttpServletRequest) request; final HttpSession session = hRequest.getSession(); - LoginInfo loginInfo = (LoginInfo) session.getAttribute(SSCConstants.USER_INFO); + LoginInfo loginInfo = (LoginInfo) session.getAttribute(Constants.USER_INFO); if (loginInfo == null) { loginInfo = new LoginInfo(); - session.setAttribute(SSCConstants.USER_INFO, loginInfo); + session.setAttribute(Constants.USER_INFO, loginInfo); updateRoleList(hRequest, loginInfo); } else { diff --git a/src/main/java/org/codelibs/fess/helper/CrawlingConfigHelper.java b/src/main/java/org/codelibs/fess/helper/CrawlingConfigHelper.java index a2debb371..8a681ba42 100644 --- a/src/main/java/org/codelibs/fess/helper/CrawlingConfigHelper.java +++ b/src/main/java/org/codelibs/fess/helper/CrawlingConfigHelper.java @@ -16,37 +16,16 @@ package org.codelibs.fess.helper; -import java.io.BufferedInputStream; -import java.io.BufferedOutputStream; -import java.io.IOException; -import java.io.InputStream; -import java.io.OutputStream; import java.io.Serializable; -import java.net.URLDecoder; -import java.net.URLEncoder; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; -import javax.servlet.http.HttpServletResponse; - -import org.apache.commons.io.IOUtils; -import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.app.service.DataConfigService; +import org.codelibs.fess.app.service.FileConfigService; +import org.codelibs.fess.app.service.WebConfigService; import org.codelibs.fess.es.exentity.CrawlingConfig; import org.codelibs.fess.es.exentity.CrawlingConfig.ConfigType; -import org.codelibs.fess.helper.UserAgentHelper.UserAgentType; -import org.codelibs.fess.service.DataConfigService; -import org.codelibs.fess.service.FileConfigService; -import org.codelibs.fess.service.WebConfigService; -import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.robot.builder.RequestDataBuilder; -import org.codelibs.robot.client.S2RobotClient; -import org.codelibs.robot.client.S2RobotClientFactory; -import org.codelibs.robot.entity.ResponseData; -import org.codelibs.robot.util.StreamUtil; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.framework.util.Base64Util; -import org.seasar.struts.util.ResponseUtil; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -93,13 +72,13 @@ public class CrawlingConfigHelper implements Serializable { } switch (configType) { case WEB: - final WebConfigService webConfigService = SingletonS2Container.getComponent(WebConfigService.class); + final WebConfigService webConfigService = SingletonLaContainer.getComponent(WebConfigService.class); return webConfigService.getWebConfig(id); case FILE: - final FileConfigService fileConfigService = SingletonS2Container.getComponent(FileConfigService.class); + final FileConfigService fileConfigService = SingletonLaContainer.getComponent(FileConfigService.class); return fileConfigService.getFileConfig(id); case DATA: - final DataConfigService dataConfigService = SingletonS2Container.getComponent(DataConfigService.class); + final DataConfigService dataConfigService = SingletonLaContainer.getComponent(DataConfigService.class); return dataConfigService.getDataConfig(id); default: return null; @@ -121,135 +100,4 @@ public class CrawlingConfigHelper implements Serializable { return crawlingConfigMap.get(sessionId); } - public void writeContent(final Map doc) { - if (logger.isDebugEnabled()) { - logger.debug("writing the content of: " + doc); - } - final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - final Object configIdObj = doc.get(fieldHelper.configIdField); - if (configIdObj == null) { - throw new FessSystemException("configId is null."); - } - final String configId = configIdObj.toString(); - if (configId.length() < 2) { - throw new FessSystemException("Invalid configId: " + configIdObj); - } - final ConfigType configType = getConfigType(configId); - CrawlingConfig config = null; - if (logger.isDebugEnabled()) { - logger.debug("configType: " + configType + ", configId: " + configId); - } - if (ConfigType.WEB == configType) { - final WebConfigService webConfigService = SingletonS2Container.getComponent(WebConfigService.class); - config = webConfigService.getWebConfig(getId(configId)); - } else if (ConfigType.FILE == configType) { - final FileConfigService fileConfigService = SingletonS2Container.getComponent(FileConfigService.class); - config = fileConfigService.getFileConfig(getId(configId)); - } else if (ConfigType.DATA == configType) { - final DataConfigService dataConfigService = SingletonS2Container.getComponent(DataConfigService.class); - config = dataConfigService.getDataConfig(getId(configId)); - } - if (config == null) { - throw new FessSystemException("No crawlingConfig: " + configIdObj); - } - final String url = (String) doc.get(fieldHelper.urlField); - final S2RobotClientFactory robotClientFactory = SingletonS2Container.getComponent(S2RobotClientFactory.class); - config.initializeClientFactory(robotClientFactory); - final S2RobotClient client = robotClientFactory.getClient(url); - if (client == null) { - throw new FessSystemException("No S2RobotClient: " + configIdObj + ", url: " + url); - } - final ResponseData responseData = client.execute(RequestDataBuilder.newRequestData().get().url(url).build()); - final HttpServletResponse response = ResponseUtil.getResponse(); - writeFileName(response, responseData); - writeContentType(response, responseData); - writeNoCache(response, responseData); - InputStream is = null; - OutputStream os = null; - try { - is = new BufferedInputStream(responseData.getResponseBody()); - os = new BufferedOutputStream(response.getOutputStream()); - StreamUtil.drain(is, os); - os.flush(); - } catch (final IOException e) { - if (!"ClientAbortException".equals(e.getClass().getSimpleName())) { - throw new FessSystemException("Failed to write a content. configId: " + configIdObj + ", url: " + url, e); - } - } finally { - IOUtils.closeQuietly(is); - IOUtils.closeQuietly(os); - } - if (logger.isDebugEnabled()) { - logger.debug("Finished to write " + url); - } - } - - protected void writeNoCache(final HttpServletResponse response, final ResponseData responseData) { - response.setHeader("Pragma", "no-cache"); - response.setHeader("Cache-Control", "no-cache"); - response.setHeader("Expires", "Thu, 01 Dec 1994 16:00:00 GMT"); - } - - protected void writeFileName(final HttpServletResponse response, final ResponseData responseData) { - final UserAgentHelper userAgentHelper = ComponentUtil.getUserAgentHelper(); - final UserAgentType userAgentType = userAgentHelper.getUserAgentType(); - String charset = responseData.getCharSet(); - if (charset == null) { - charset = Constants.UTF_8; - } - final String name; - final String url = responseData.getUrl(); - final int pos = url.lastIndexOf('/'); - try { - if (pos >= 0 && pos + 1 < url.length()) { - name = URLDecoder.decode(url.substring(pos + 1), charset); - } else { - name = URLDecoder.decode(url, charset); - } - - if (logger.isDebugEnabled()) { - logger.debug("userAgentType: " + userAgentType + ", charset: " + charset + ", name: " + name); - } - - switch (userAgentType) { - case IE: - response.setHeader("Content-Disposition", "attachment; filename=\"" + URLEncoder.encode(name, Constants.UTF_8) + "\""); - break; - case OPERA: - response.setHeader("Content-Disposition", "attachment; filename*=utf-8'ja'" + URLEncoder.encode(name, Constants.UTF_8)); - break; - case SAFARI: - response.setHeader("Content-Disposition", "attachment; filename=\"" + name + "\""); - break; - case CHROME: - case FIREFOX: - case OTHER: - default: - response.setHeader("Content-Disposition", - "attachment; filename=\"=?utf-8?B?" + Base64Util.encode(name.getBytes(Constants.UTF_8)) + "?=\""); - break; - } - } catch (final Exception e) { - logger.warn("Failed to write a filename: " + responseData, e); - } - } - - protected void writeContentType(final HttpServletResponse response, final ResponseData responseData) { - final String mimeType = responseData.getMimeType(); - if (logger.isDebugEnabled()) { - logger.debug("mimeType: " + mimeType); - } - if (mimeType == null) { - return; - } - if (mimeType.startsWith("text/")) { - final String charset = response.getCharacterEncoding(); - if (charset != null) { - response.setContentType(mimeType + "; charset=" + charset); - return; - } - } - response.setContentType(mimeType); - } - } diff --git a/src/main/java/org/codelibs/fess/helper/CrawlingSessionHelper.java b/src/main/java/org/codelibs/fess/helper/CrawlingSessionHelper.java index e02613975..0a5398fa1 100644 --- a/src/main/java/org/codelibs/fess/helper/CrawlingSessionHelper.java +++ b/src/main/java/org/codelibs/fess/helper/CrawlingSessionHelper.java @@ -26,11 +26,11 @@ import java.util.Map; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; -import org.codelibs.fess.client.FessEsClient; +import org.codelibs.fess.app.service.CrawlingSessionService; +import org.codelibs.fess.es.client.FessEsClient; import org.codelibs.fess.es.exentity.CrawlingSession; import org.codelibs.fess.es.exentity.CrawlingSessionInfo; -import org.codelibs.fess.service.CrawlingSessionService; +import org.codelibs.fess.exception.FessSystemException; import org.codelibs.fess.util.ComponentUtil; import org.elasticsearch.index.query.QueryBuilders; import org.elasticsearch.search.aggregations.AggregationBuilders; @@ -38,7 +38,7 @@ import org.elasticsearch.search.aggregations.bucket.terms.Terms; import org.elasticsearch.search.aggregations.bucket.terms.Terms.Bucket; import org.elasticsearch.search.aggregations.bucket.terms.Terms.Order; import org.elasticsearch.search.aggregations.bucket.terms.TermsBuilder; -import org.seasar.framework.container.SingletonS2Container; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -56,7 +56,7 @@ public class CrawlingSessionHelper implements Serializable { private final int maxSessionIdsInList = 100; protected CrawlingSessionService getCrawlingSessionService() { - return SingletonS2Container.getComponent(CrawlingSessionService.class); + return SingletonLaContainer.getComponent(CrawlingSessionService.class); } public String getCanonicalSessionId(final String sessionId) { diff --git a/src/main/java/org/codelibs/fess/helper/DataIndexHelper.java b/src/main/java/org/codelibs/fess/helper/DataIndexHelper.java index 7cf8acb20..0f36f73d4 100644 --- a/src/main/java/org/codelibs/fess/helper/DataIndexHelper.java +++ b/src/main/java/org/codelibs/fess/helper/DataIndexHelper.java @@ -28,15 +28,15 @@ import javax.annotation.Resource; import org.codelibs.core.lang.StringUtil; import org.codelibs.core.misc.DynamicProperties; import org.codelibs.fess.Constants; +import org.codelibs.fess.app.service.DataConfigService; import org.codelibs.fess.ds.DataStore; import org.codelibs.fess.ds.DataStoreFactory; import org.codelibs.fess.ds.IndexUpdateCallback; import org.codelibs.fess.es.exentity.DataConfig; -import org.codelibs.fess.service.DataConfigService; import org.codelibs.fess.util.ComponentUtil; import org.elasticsearch.index.query.QueryBuilder; import org.elasticsearch.index.query.QueryBuilders; -import org.seasar.framework.container.SingletonS2Container; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -102,7 +102,7 @@ public class DataIndexHelper implements Serializable { final long startTime = System.currentTimeMillis(); - final IndexUpdateCallback indexUpdateCallback = SingletonS2Container.getComponent(IndexUpdateCallback.class); + final IndexUpdateCallback indexUpdateCallback = SingletonLaContainer.getComponent(IndexUpdateCallback.class); final List sessionIdList = new ArrayList(); final Map initParamMap = new HashMap(); diff --git a/src/main/java/org/codelibs/fess/helper/DatabaseHelper.java b/src/main/java/org/codelibs/fess/helper/DatabaseHelper.java deleted file mode 100644 index a14810f9d..000000000 --- a/src/main/java/org/codelibs/fess/helper/DatabaseHelper.java +++ /dev/null @@ -1,23 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.helper; - -public interface DatabaseHelper { - - void optimize(); - -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/helper/HotSearchWordHelper.java b/src/main/java/org/codelibs/fess/helper/HotSearchWordHelper.java index adbcffbe8..3eba43da0 100644 --- a/src/main/java/org/codelibs/fess/helper/HotSearchWordHelper.java +++ b/src/main/java/org/codelibs/fess/helper/HotSearchWordHelper.java @@ -22,12 +22,12 @@ import java.util.Map; import java.util.concurrent.ConcurrentHashMap; import java.util.regex.Pattern; +import javax.annotation.PostConstruct; import javax.annotation.Resource; import org.codelibs.fess.Constants; import org.codelibs.fess.es.exbhv.SearchLogBhv; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.framework.container.annotation.tiger.InitMethod; public class HotSearchWordHelper { @@ -40,7 +40,7 @@ public class HotSearchWordHelper { public Pattern excludedWordPattern; - @InitMethod + @PostConstruct public void init() { final long now = ComponentUtil.getSystemHelper().getCurrentTimeAsLong(); cacheMap.put(Range.ONE_DAY, getHotSearchWordListByFromDate(now - Constants.ONE_DAY_IN_MILLIS)); diff --git a/src/main/java/org/codelibs/fess/helper/IndexingHelper.java b/src/main/java/org/codelibs/fess/helper/IndexingHelper.java index 6877db5bf..f9d56d1ad 100644 --- a/src/main/java/org/codelibs/fess/helper/IndexingHelper.java +++ b/src/main/java/org/codelibs/fess/helper/IndexingHelper.java @@ -16,11 +16,16 @@ package org.codelibs.fess.helper; +import java.util.ArrayList; import java.util.List; import java.util.Map; -import org.codelibs.fess.client.FessEsClient; +import org.codelibs.fess.es.client.FessEsClient; import org.codelibs.fess.util.ComponentUtil; +import org.elasticsearch.action.count.CountResponse; +import org.elasticsearch.index.query.FilterBuilders; +import org.elasticsearch.index.query.QueryBuilder; +import org.elasticsearch.index.query.QueryBuilders; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -44,258 +49,103 @@ public class IndexingHelper { fessEsClient.addAll(fieldHelper.docIndex, fieldHelper.docType, docList); } if (logger.isInfoEnabled()) { - logger.info("Sent " + docList.size() + " docs (Solr: " + (System.currentTimeMillis() - execTime) + "ms)"); + logger.info("Sent " + docList.size() + " docs (ES: " + (System.currentTimeMillis() - execTime) + "ms)"); } docList.clear(); } private void deleteOldDocuments(final FessEsClient fessEsClient, final List> docList) { - // TODO move fessEsClient - // final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - // - // final List docIdList = new ArrayList(); - // final StringBuilder q = new StringBuilder(1000); - // final StringBuilder fq = new StringBuilder(100); - // for (final Map inputDoc : docList) { - // final Object idValue = inputDoc.get(fieldHelper.idField); - // if (idValue == null) { - // continue; - // } - // - // final Object configIdValue = inputDoc.get(fieldHelper.configIdField); - // if (configIdValue == null) { - // continue; - // } - // - // q.setLength(0); - // q.append(fieldHelper.urlField).append(":\""); - // q.append(QueryUtil.escapeValue((String) - // inputDoc.get(fieldHelper.urlField))); - // q.append('"'); - // - // fq.setLength(0); - // fq.append(fieldHelper.configIdField).append(':'); - // fq.append(configIdValue.toString()); - // - // final List> docs = - // getSolrDocumentList(fessEsClient, fq.toString(), q.toString(), new - // String[] { fieldHelper.idField, - // fieldHelper.docIdField }); - // for (final SolrDocument doc : docs) { - // final Object oldIdValue = doc.getFieldValue(fieldHelper.idField); - // if (!idValue.equals(oldIdValue) && oldIdValue != null) { - // final Object oldDocIdValue = - // doc.getFieldValue(fieldHelper.docIdField); - // if (oldDocIdValue != null) { - // docIdList.add(oldDocIdValue.toString()); - // } - // } - // } - // if (logger.isDebugEnabled()) { - // logger.debug(q + " in " + fq + " => " + docs); - // } - // } - // if (!docIdList.isEmpty()) { - // deleteDocumentsByDocId(fessEsClient, docIdList); - // } - } + final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - public List> getSolrDocumentList(final FessEsClient fessEsClient, final String fq, final String q, - final String[] fields) { - return getSolrDocumentList(fessEsClient, fq, q, fields, defaultRowSize); - } + final List docIdList = new ArrayList<>(); + for (final Map inputDoc : docList) { + final Object idValue = inputDoc.get(fieldHelper.idField); + if (idValue == null) { + continue; + } - protected List> getSolrDocumentList(final FessEsClient fessEsClient, final String fq, final String q, - final String[] fields, final int row) { - // TODO move fessEsClient - // final SolrQuery sq = new SolrQuery(); - // if (fq != null) { - // sq.setFilterQueries(fq); - // } - // sq.setQuery(q); - // if (fields != null) { - // sq.setFields(fields); - // } - // sq.setRows(row); - // e. - // final List> docList = - // fessEsClient.query(sq).getResults(); - // if (docList.getNumFound() <= row) { - // return docList; - // } - // return getSolrDocumentList(fessEsClient, fq, q, fields, (int) - // docList.getNumFound()); - return null; + final Object configIdValue = inputDoc.get(fieldHelper.configIdField); + if (configIdValue == null) { + continue; + } + + final QueryBuilder queryBuilder = + QueryBuilders.filteredQuery(QueryBuilders.termQuery(fieldHelper.urlField, inputDoc.get(fieldHelper.urlField)), + FilterBuilders.termFilter(fieldHelper.configIdField, configIdValue)); + + final List> docs = + getDocumentListByQuery(fessEsClient, queryBuilder, new String[] { fieldHelper.idField, fieldHelper.docIdField }); + for (final Map doc : docs) { + final Object oldIdValue = doc.get(fieldHelper.idField); + if (!idValue.equals(oldIdValue) && oldIdValue != null) { + final Object oldDocIdValue = doc.get(fieldHelper.docIdField); + if (oldDocIdValue != null) { + docIdList.add(oldDocIdValue.toString()); + } + } + } + if (logger.isDebugEnabled()) { + logger.debug(queryBuilder.toString() + " => " + docs); + } + } + if (!docIdList.isEmpty()) { + fessEsClient.deleteByQuery(fieldHelper.docIndex, fieldHelper.docType, + QueryBuilders.idsQuery(fieldHelper.docType).ids(docIdList.stream().toArray(n -> new String[n]))); + + } } public void deleteDocument(final FessEsClient fessEsClient, final String id) { - // TODO move fessEsClient - // final long start = System.currentTimeMillis(); - // final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - // final String query = "{!raw f=" + fieldHelper.idField + "}" + id; - // for (int i = 0; i < maxRetryCount; i++) { - // boolean done = true; - // try { - // for (final UpdateResponse response : fessEsClient.deleteByQuery(query)) { - // if (response.getStatus() != 0) { - // logger.warn("Failed to delete: " + response); - // done = false; - // } - // } - // } catch (final Exception e) { - // logger.warn("Could not delete a document from Solr." + - // " It might be busy. " + "Retrying.. id:" + id + ", cause: " - // + e.getMessage()); - // done = false; - // } - // if (done) { - // if (logger.isDebugEnabled()) { - // logger.info("Deleted 1 doc (Solr: " + (System.currentTimeMillis() - - // start) + "ms) => id:" + id); - // } else { - // logger.info("Deleted 1 doc (Solr: " + (System.currentTimeMillis() - - // start) + "ms)"); - // } - // return; - // } - // try { - // Thread.sleep(requestInterval); - // } catch (final InterruptedException e) {} - // } + final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); + fessEsClient.delete(fieldHelper.docIndex, fieldHelper.docType, id, 0); } public void deleteDocumentsByDocId(final FessEsClient fessEsClient, final List docIdList) { - // TODO move fessEsClient - // final long start = System.currentTimeMillis(); - // final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - // final StringBuilder buf = new StringBuilder(500); - // for (final String docId : docIdList) { - // if (buf.length() != 0) { - // buf.append(" OR "); - // } - // buf.append(fieldHelper.docIdField).append(':').append(docId); - // } - // final String query = buf.toString(); - // for (int i = 0; i < maxRetryCount; i++) { - // boolean done = true; - // try { - // for (final UpdateResponse response : fessEsClient.deleteByQuery(query)) { - // if (response.getStatus() != 0) { - // logger.warn("Failed to delete: " + response); - // done = false; - // } - // } - // } catch (final Exception e) { - // logger.warn("Could not delete a document from Solr." + - // " It might be busy. " + "Retrying.. id:" + docIdList + ", cause: " - // + e.getMessage()); - // done = false; - // } - // if (done) { - // if (logger.isDebugEnabled()) { - // logger.info("Deleted " + docIdList.size() + " docs (Solr: " + - // (System.currentTimeMillis() - start) + "ms) => docId:" - // + docIdList); - // } else { - // logger.info("Deleted " + docIdList.size() + " docs (Solr: " + - // (System.currentTimeMillis() - start) + "ms)"); - // } - // return; - // } - // try { - // Thread.sleep(requestInterval); - // } catch (final InterruptedException e) {} - // } + final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); + fessEsClient.deleteByQuery(fieldHelper.docIndex, fieldHelper.docType, + QueryBuilders.idsQuery(fieldHelper.docType).ids(docIdList.stream().toArray(n -> new String[n]))); } - public Map getSolrDocument(final FessEsClient fessEsClient, final String id, final String[] fields) { - // TODO move fessEsClient - // final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - // - // final SolrQuery solrQuery = new SolrQuery(); - // final StringBuilder queryBuf = new StringBuilder(500); - // queryBuf.append("{!raw f=").append(fieldHelper.idField).append("}"); - // queryBuf.append(id); - // solrQuery.setQuery(queryBuf.toString()); - // if (fields != null) { - // solrQuery.setFields(fields); - // } - // final QueryResponse response = fessEsClient.query(solrQuery); - // final List> docList = response.getResults(); - // if (docList.isEmpty()) { - // return null; - // } - // if (docList.size() > 1) { - // logger.error("Invalid multiple docs for " + id); - // for (final SolrDocument doc : docList) { - // final Object idValue = doc.getFieldValue(fieldHelper.idField); - // if (idValue != null) { - // deleteDocument(fessEsClient, idValue.toString()); - // } - // } - // return null; - // } - // return docList.get(0); - return null; + public Map getDocument(final FessEsClient fessEsClient, final String id, final String[] fields) { + final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); + return fessEsClient.getDocument(fieldHelper.docIndex, fieldHelper.docType, id, requestBuilder -> { + return true; + }).orElseGet(() -> null); } - public List> getSolrDocumentListByPrefixId(final FessEsClient fessEsClient, final String id, final String[] fields) { - // TODO move fessEsClient - // final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - // final SolrQuery solrQuery = new SolrQuery(); - // final StringBuilder queryBuf = new StringBuilder(500); - // queryBuf.append("{!prefix f=").append(fieldHelper.idField).append("}"); - // queryBuf.append(id); - // solrQuery.setQuery(queryBuf.toString()); - // if (fields != null) { - // solrQuery.setFields(fields); - // } - // final QueryResponse response = fessEsClient.query(solrQuery); - // final List> docList = response.getResults(); - // if (docList.isEmpty()) { - // return null; - // } - // if (logger.isDebugEnabled()) { - // logger.debug("Found solr documents: " + docList); - // } - // return docList; - return null; + public List> getDocumentListByPrefixId(final FessEsClient fessEsClient, final String id, final String[] fields) { + final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); + final QueryBuilder queryBuilder = QueryBuilders.prefixQuery(fieldHelper.idField, id); + return getDocumentListByQuery(fessEsClient, queryBuilder, fields); } - public void deleteChildSolrDocument(final FessEsClient fessEsClient, final String id) { - // TODO move fessEsClient - // final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - // final String query = "{!raw f=" + fieldHelper.parentIdField + " v=\"" - // + id + "\"}"; - // for (final UpdateResponse response : fessEsClient.deleteByQuery(query)) { - // if (response.getStatus() != 0) { - // logger.warn("Failed to delete: " + response); - // } - // } + public void deleteChildDocument(final FessEsClient fessEsClient, final String id) { + final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); + fessEsClient.deleteByQuery(fieldHelper.docIndex, fieldHelper.docType, QueryBuilders.termQuery(fieldHelper.parentIdField, id)); } - public List> getChildSolrDocumentList(final FessEsClient fessEsClient, final String id, final String[] fields) { - return getChildSolrDocumentList(fessEsClient, id, fields, defaultRowSize); + public List> getChildDocumentList(final FessEsClient fessEsClient, final String id, final String[] fields) { + final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); + final QueryBuilder queryBuilder = QueryBuilders.termQuery(fieldHelper.parentIdField, id); + return getDocumentListByQuery(fessEsClient, queryBuilder, fields); } - protected List> getChildSolrDocumentList(final FessEsClient fessEsClient, final String id, final String[] fields, - final int row) { - // TODO move fessEsClient - // final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - // final SolrQuery solrQuery = new SolrQuery(); - // solrQuery.setQuery("{!raw f=" + fieldHelper.parentIdField + " v=\"" + - // id + "\"}"); - // if (fields != null) { - // solrQuery.setFields(fields); - // } - // solrQuery.setRows(row); - // final List> docList = - // fessEsClient.query(solrQuery).getResults(); - // if (docList.getNumFound() <= row) { - // return docList; - // } - // return getChildSolrDocumentList(fessEsClient, id, fields, (int) - // docList.getNumFound()); - return null; + protected List> getDocumentListByQuery(final FessEsClient fessEsClient, final QueryBuilder queryBuilder, + final String[] fields) { + final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); + + final CountResponse countResponse = + fessEsClient.prepareCount(fieldHelper.docIndex).setTypes(fieldHelper.docType).setQuery(queryBuilder).execute().actionGet(); + final long numFound = countResponse.getCount(); + // TODO max threshold + + return fessEsClient.getDocumentList(fieldHelper.docIndex, fieldHelper.docType, requestBuilder -> { + requestBuilder.setQuery(queryBuilder).setSize((int) numFound); + if (fields != null) { + requestBuilder.addFields(fields); + } + return true; + }); + } } \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/helper/IntervalControlHelper.java b/src/main/java/org/codelibs/fess/helper/IntervalControlHelper.java index 27a4eddc8..59be277ee 100644 --- a/src/main/java/org/codelibs/fess/helper/IntervalControlHelper.java +++ b/src/main/java/org/codelibs/fess/helper/IntervalControlHelper.java @@ -20,7 +20,7 @@ import java.util.ArrayList; import java.util.Calendar; import java.util.List; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; public class IntervalControlHelper { private volatile boolean crawlerRunning = true; diff --git a/src/main/java/org/codelibs/fess/helper/JobHelper.java b/src/main/java/org/codelibs/fess/helper/JobHelper.java index daf0ead69..f412b6dac 100644 --- a/src/main/java/org/codelibs/fess/helper/JobHelper.java +++ b/src/main/java/org/codelibs/fess/helper/JobHelper.java @@ -22,12 +22,13 @@ import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.CountDownLatch; import java.util.concurrent.TimeUnit; +import javax.annotation.PreDestroy; + import org.apache.commons.io.IOUtils; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; import org.codelibs.fess.job.JobExecutor; import org.codelibs.fess.util.InputStreamThread; import org.codelibs.fess.util.JobProcess; -import org.seasar.framework.container.annotation.tiger.DestroyMethod; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -38,7 +39,7 @@ public class JobHelper { private final ConcurrentHashMap runningJobExecutorMap = new ConcurrentHashMap<>(); - @DestroyMethod + @PreDestroy public void destroy() { for (final String sessionId : runningProcessMap.keySet()) { destroyCrawlerProcess(sessionId); diff --git a/src/main/java/org/codelibs/fess/helper/KeyMatchHelper.java b/src/main/java/org/codelibs/fess/helper/KeyMatchHelper.java index 75c1f2688..73e919a53 100644 --- a/src/main/java/org/codelibs/fess/helper/KeyMatchHelper.java +++ b/src/main/java/org/codelibs/fess/helper/KeyMatchHelper.java @@ -22,14 +22,15 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import javax.annotation.PostConstruct; + import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.client.FessEsClient; -import org.codelibs.fess.client.FessEsClient.SearchConditionBuilder; +import org.codelibs.fess.app.service.KeyMatchService; +import org.codelibs.fess.es.client.FessEsClient; +import org.codelibs.fess.es.client.FessEsClient.SearchConditionBuilder; import org.codelibs.fess.es.exentity.KeyMatch; -import org.codelibs.fess.service.KeyMatchService; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.framework.container.annotation.tiger.InitMethod; +import org.lastaflute.di.core.SingletonLaContainer; public class KeyMatchHelper { protected volatile Map keyMatchQueryMap = Collections.emptyMap(); @@ -38,7 +39,7 @@ public class KeyMatchHelper { protected long reloadInterval = 1000L; - @InitMethod + @PostConstruct public void init() { reload(0); } @@ -49,7 +50,7 @@ public class KeyMatchHelper { protected void reload(final long interval) { final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - final KeyMatchService keyMatchService = SingletonS2Container.getComponent(KeyMatchService.class); + final KeyMatchService keyMatchService = SingletonLaContainer.getComponent(KeyMatchService.class); final List list = keyMatchService.getAvailableKeyMatchList(); final Map keyMatchQueryMap = new HashMap(list.size()); for (final KeyMatch keyMatch : list) { diff --git a/src/main/java/org/codelibs/fess/helper/LabelTypeHelper.java b/src/main/java/org/codelibs/fess/helper/LabelTypeHelper.java index d8eb57073..039c13d46 100644 --- a/src/main/java/org/codelibs/fess/helper/LabelTypeHelper.java +++ b/src/main/java/org/codelibs/fess/helper/LabelTypeHelper.java @@ -26,14 +26,14 @@ import java.util.Map; import java.util.Set; import java.util.regex.Pattern; +import javax.annotation.PostConstruct; import javax.annotation.Resource; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; +import org.codelibs.fess.app.service.LabelTypeService; import org.codelibs.fess.es.exentity.LabelType; -import org.codelibs.fess.service.LabelTypeService; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.framework.container.annotation.tiger.InitMethod; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -50,10 +50,10 @@ public class LabelTypeHelper implements Serializable { protected volatile List labelTypePatternList; protected LabelTypeService getLabelTypeService() { - return SingletonS2Container.getComponent(LabelTypeService.class); + return SingletonLaContainer.getComponent(LabelTypeService.class); } - @InitMethod + @PostConstruct public void init() { final List labelTypeList = getLabelTypeService().getLabelTypeListWithRoles(); buildLabelTypeItems(labelTypeList); diff --git a/src/main/java/org/codelibs/fess/helper/MailHelper.java b/src/main/java/org/codelibs/fess/helper/MailHelper.java index 98749a46b..c5da358eb 100644 --- a/src/main/java/org/codelibs/fess/helper/MailHelper.java +++ b/src/main/java/org/codelibs/fess/helper/MailHelper.java @@ -29,7 +29,7 @@ import javax.mail.internet.InternetAddress; import javax.mail.internet.MimeMessage; import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; public class MailHelper implements Serializable { diff --git a/src/main/java/org/codelibs/fess/helper/OpenSearchHelper.java b/src/main/java/org/codelibs/fess/helper/OpenSearchHelper.java index 4c8f14380..972b4abda 100644 --- a/src/main/java/org/codelibs/fess/helper/OpenSearchHelper.java +++ b/src/main/java/org/codelibs/fess/helper/OpenSearchHelper.java @@ -19,16 +19,16 @@ package org.codelibs.fess.helper; import java.io.File; import java.io.IOException; +import javax.annotation.PostConstruct; import javax.servlet.ServletOutputStream; import javax.servlet.http.HttpServletResponse; import org.apache.commons.io.IOUtils; +import org.codelibs.core.io.FileUtil; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; -import org.seasar.framework.container.annotation.tiger.InitMethod; -import org.seasar.framework.util.FileUtil; -import org.seasar.struts.util.ServletContextUtil; +import org.codelibs.fess.exception.FessSystemException; +import org.lastaflute.web.util.LaServletContextUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -50,10 +50,10 @@ public class OpenSearchHelper { private File osddFile; - @InitMethod + @PostConstruct public void init() { if (StringUtil.isNotBlank(osddPath)) { - final String path = ServletContextUtil.getServletContext().getRealPath(osddPath); + final String path = LaServletContextUtil.getServletContext().getRealPath(osddPath); osddFile = new File(path); if (!osddFile.isFile()) { osddFile = null; @@ -77,7 +77,7 @@ public class OpenSearchHelper { ServletOutputStream os = null; try { os = response.getOutputStream(); - os.write(FileUtil.getBytes(osddFile)); + os.write(FileUtil.readBytes(osddFile)); } catch (final IOException e) { throw new FessSystemException("Failed to write OpenSearch response.", e); } finally { diff --git a/src/main/java/org/codelibs/fess/helper/OverlappingHostHelper.java b/src/main/java/org/codelibs/fess/helper/OverlappingHostHelper.java index 837372f19..e3b365c0c 100644 --- a/src/main/java/org/codelibs/fess/helper/OverlappingHostHelper.java +++ b/src/main/java/org/codelibs/fess/helper/OverlappingHostHelper.java @@ -20,10 +20,11 @@ import java.io.Serializable; import java.util.ArrayList; import java.util.List; +import javax.annotation.PostConstruct; + +import org.codelibs.fess.app.service.OverlappingHostService; import org.codelibs.fess.es.exentity.OverlappingHost; -import org.codelibs.fess.service.OverlappingHostService; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.framework.container.annotation.tiger.InitMethod; +import org.lastaflute.di.core.SingletonLaContainer; public class OverlappingHostHelper implements Serializable { @@ -31,12 +32,12 @@ public class OverlappingHostHelper implements Serializable { private List overlappingHostList; - @InitMethod + @PostConstruct public void init() { if (overlappingHostList == null) { overlappingHostList = new ArrayList(); } - final OverlappingHostService overlappingHostService = SingletonS2Container.getComponent(OverlappingHostService.class); + final OverlappingHostService overlappingHostService = SingletonLaContainer.getComponent(OverlappingHostService.class); overlappingHostList.addAll(overlappingHostService.getOverlappingHostList()); } diff --git a/src/main/java/org/codelibs/fess/helper/PathMappingHelper.java b/src/main/java/org/codelibs/fess/helper/PathMappingHelper.java index 7dcf1eeaa..348ee62c0 100644 --- a/src/main/java/org/codelibs/fess/helper/PathMappingHelper.java +++ b/src/main/java/org/codelibs/fess/helper/PathMappingHelper.java @@ -23,11 +23,12 @@ import java.util.List; import java.util.Map; import java.util.regex.Matcher; +import javax.annotation.PostConstruct; + import org.codelibs.fess.Constants; import org.codelibs.fess.es.exbhv.PathMappingBhv; import org.codelibs.fess.es.exentity.PathMapping; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.framework.container.annotation.tiger.InitMethod; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -41,14 +42,14 @@ public class PathMappingHelper implements Serializable { volatile List cachedPathMappingList = null; - @InitMethod + @PostConstruct public void init() { final List ptList = new ArrayList<>(); ptList.add(Constants.PROCESS_TYPE_DISPLAYING); ptList.add(Constants.PROCESS_TYPE_BOTH); try { - final PathMappingBhv pathMappingBhv = SingletonS2Container.getComponent(PathMappingBhv.class); + final PathMappingBhv pathMappingBhv = SingletonLaContainer.getComponent(PathMappingBhv.class); cachedPathMappingList = pathMappingBhv.selectList(cb -> { cb.query().addOrderBy_SortOrder_Asc(); cb.query().setProcessType_InScope(ptList); diff --git a/src/main/java/org/codelibs/fess/helper/QueryHelper.java b/src/main/java/org/codelibs/fess/helper/QueryHelper.java index af6cebbb4..c846591b3 100644 --- a/src/main/java/org/codelibs/fess/helper/QueryHelper.java +++ b/src/main/java/org/codelibs/fess/helper/QueryHelper.java @@ -16,21 +16,6 @@ package org.codelibs.fess.helper; -/* - * Copyright 2009-2014 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ import java.io.Serializable; import java.util.ArrayList; import java.util.HashMap; @@ -42,23 +27,21 @@ import java.util.Map; import java.util.Map.Entry; import java.util.Set; +import javax.annotation.PostConstruct; import javax.annotation.Resource; import javax.servlet.http.HttpServletRequest; -import org.apache.commons.lang.StringUtils; +import org.apache.commons.lang3.StringUtils; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.InvalidQueryException; import org.codelibs.fess.entity.FacetInfo; import org.codelibs.fess.entity.GeoInfo; import org.codelibs.fess.entity.SearchQuery; import org.codelibs.fess.entity.SearchQuery.SortField; +import org.codelibs.fess.exception.InvalidQueryException; import org.codelibs.fess.util.QueryUtil; -import org.codelibs.fess.util.SearchParamMap; -import org.seasar.framework.container.annotation.tiger.Binding; -import org.seasar.framework.container.annotation.tiger.BindingType; -import org.seasar.framework.container.annotation.tiger.InitMethod; -import org.seasar.struts.util.RequestUtil; +import org.lastaflute.web.ruts.message.ActionMessages; +import org.lastaflute.web.util.LaRequestUtil; public class QueryHelper implements Serializable { @@ -84,7 +67,6 @@ public class QueryHelper implements Serializable { private static final long serialVersionUID = 1L; - @Binding(bindingType = BindingType.MAY) @Resource protected RoleQueryHelper roleQueryHelper; @@ -94,7 +76,6 @@ public class QueryHelper implements Serializable { @Resource protected FieldHelper fieldHelper; - @Binding(bindingType = BindingType.MAY) @Resource protected KeyMatchHelper keyMatchHelper; @@ -108,7 +89,7 @@ public class QueryHelper implements Serializable { protected String[] responseDocValuesFields; - protected String[] highlightingFields; + protected String[] highlightedFields; protected String[] searchFields; @@ -122,7 +103,7 @@ public class QueryHelper implements Serializable { protected String[] supportedAnalysisFields; - protected int highlightSnippetSize = 5; + protected int highlightFragmentSize = 100; protected boolean useBigram = true; @@ -140,7 +121,7 @@ public class QueryHelper implements Serializable { protected List defaultSortFieldList = new ArrayList(); - protected String highlightingPrefix = "hl_"; + protected String highlightPrefix = "hl_"; protected String minimumShouldMatch = "100%"; @@ -156,7 +137,7 @@ public class QueryHelper implements Serializable { protected Map fieldBoostMap = new HashMap(); - @InitMethod + @PostConstruct public void init() { if (responseFields == null) { responseFields = @@ -177,8 +158,8 @@ public class QueryHelper implements Serializable { if (responseDocValuesFields == null) { responseDocValuesFields = new String[] { fieldHelper.clickCountField, fieldHelper.favoriteCountField }; } - if (highlightingFields == null) { - highlightingFields = new String[] { fieldHelper.contentField }; + if (highlightedFields == null) { + highlightedFields = new String[] { fieldHelper.contentField }; } if (searchFields == null) { searchFields = @@ -297,13 +278,13 @@ public class QueryHelper implements Serializable { final SearchQuery searchQuery = new SearchQuery(); final String q = buildQuery(query, sortFieldMap, highLightQueryList, fieldLogMap); - String solrQuery; + String queryString; if (q == null || "()".equals(q)) { - solrQuery = StringUtil.EMPTY; + queryString = StringUtil.EMPTY; } else { - solrQuery = unbracketQuery(q); + queryString = unbracketQuery(q); } - searchQuery.setQuery(solrQuery); + searchQuery.setQuery(queryString); searchQuery.setMinimumShouldMatch(minimumShouldMatch); searchQuery.setDefType(defType); @@ -312,7 +293,7 @@ public class QueryHelper implements Serializable { searchQuery.addSortField(entry.getKey(), entry.getValue()); } // set queries to request for HighLight - final HttpServletRequest request = RequestUtil.getRequest(); + final HttpServletRequest request = LaRequestUtil.getOptionalRequest().orElse(null); if (request != null) { request.setAttribute(Constants.HIGHLIGHT_QUERIES, highLightQueryList.toArray(new String[highLightQueryList.size()])); request.setAttribute(Constants.FIELD_LOGS, fieldLogMap); @@ -628,7 +609,8 @@ public class QueryHelper implements Serializable { final String value1 = split[0].trim(); final String value2 = split[1].trim(); if ("*".equals(value1) && "*".equals(value2)) { - throw new InvalidQueryException("errors.invalid_query_str_range", "Invalid range: " + value); + throw new InvalidQueryException(messages -> messages.addErrorsInvalidQueryStrRange(ActionMessages.GLOBAL_PROPERTY_KEY), + "Invalid range: " + value); } buf.append(prefix); buf.append(QueryUtil.escapeRangeValue(value1)); @@ -636,7 +618,8 @@ public class QueryHelper implements Serializable { buf.append(QueryUtil.escapeRangeValue(value2)); buf.append(suffix); } else { - throw new InvalidQueryException("errors.invalid_query_str_range", "Invalid range: " + value); + throw new InvalidQueryException(messages -> messages.addErrorsInvalidQueryStrRange(ActionMessages.GLOBAL_PROPERTY_KEY), + "Invalid range: " + value); } } @@ -734,13 +717,17 @@ public class QueryHelper implements Serializable { buf.append('\\'); } if (quoted) { - throw new InvalidQueryException("errors.invalid_query_quoted", "Invalid quoted: " + query); + throw new InvalidQueryException(messages -> messages.addErrorsInvalidQueryQuoted(ActionMessages.GLOBAL_PROPERTY_KEY), + "Invalid quoted: " + query); } else if (curlyBracket > 0) { - throw new InvalidQueryException("errors.invalid_query_curly_bracket", "Invalid curly bracket: " + query); + throw new InvalidQueryException(messages -> messages.addErrorsInvalidQueryCurlyBracket(ActionMessages.GLOBAL_PROPERTY_KEY), + "Invalid curly bracket: " + query); } else if (squareBracket > 0) { - throw new InvalidQueryException("errors.invalid_query_square_bracket", "Invalid square bracket: " + query); + throw new InvalidQueryException(messages -> messages.addErrorsInvalidQuerySquareBracket(ActionMessages.GLOBAL_PROPERTY_KEY), + "Invalid square bracket: " + query); } else if (parenthesis > 0) { - throw new InvalidQueryException("errors.invalid_query_parenthesis", "Invalid parenthesis: " + query); + throw new InvalidQueryException(messages -> messages.addErrorsInvalidQueryParenthesis(ActionMessages.GLOBAL_PROPERTY_KEY), + "Invalid parenthesis: " + query); } if (buf.length() > 0) { addQueryPart(buf.toString(), valueList, sortFieldMap, highLightQueryList, fieldLogMap); @@ -786,13 +773,13 @@ public class QueryHelper implements Serializable { public String buildFacetQuery(final String query) { final String q = buildFacetQueryInternal(query); - String solrQuery; + String queryString; if (q == null || "()".equals(q)) { - solrQuery = StringUtil.EMPTY; + queryString = StringUtil.EMPTY; } else { - solrQuery = unbracketQuery(q); + queryString = unbracketQuery(q); } - return solrQuery; + return queryString; } protected String buildFacetQueryInternal(final String query) { @@ -935,7 +922,7 @@ public class QueryHelper implements Serializable { if (defaultQueryLanguage != null) { return defaultQueryLanguage; } - final HttpServletRequest request = RequestUtil.getRequest(); + final HttpServletRequest request = LaRequestUtil.getOptionalRequest().orElse(null); if (request == null) { return null; } @@ -977,7 +964,7 @@ public class QueryHelper implements Serializable { return "count".equals(sort) || "index".equals(sort); } - public String buildOptionQuery(final SearchParamMap optionMap) { + public String buildOptionQuery(final Map optionMap) { if (optionMap == null) { return StringUtil.EMPTY; } @@ -1125,17 +1112,17 @@ public class QueryHelper implements Serializable { } /** - * @return the highlightingFields + * @return the highlightedFields */ - public String[] getHighlightingFields() { - return highlightingFields; + public String[] getHighlightedFields() { + return highlightedFields; } /** - * @param highlightingFields the highlightingFields to set + * @param highlightedFields the highlightedFields to set */ - public void setHighlightingFields(final String[] highlightingFields) { - this.highlightingFields = highlightingFields; + public void setHighlightedFields(final String[] highlightedFields) { + this.highlightedFields = highlightedFields; } /** @@ -1199,17 +1186,17 @@ public class QueryHelper implements Serializable { } /** - * @return the highlightSnippetSize + * @return the highlightFragmentSize */ - public int getHighlightSnippetSize() { - return highlightSnippetSize; + public int getHighlightFragmentSize() { + return highlightFragmentSize; } /** - * @param highlightSnippetSize the highlightSnippetSize to set + * @param highlightFragmentSize the highlightFragmentSize to set */ - public void setHighlightSnippetSize(final int highlightSnippetSize) { - this.highlightSnippetSize = highlightSnippetSize; + public void setHighlightFragmentSize(final int highlightFragmentSize) { + this.highlightFragmentSize = highlightFragmentSize; } /** @@ -1303,12 +1290,12 @@ public class QueryHelper implements Serializable { return defaultSortFieldList.toArray(new SortField[defaultSortFieldList.size()]); } - public void setHighlightingPrefix(final String highlightingPrefix) { - this.highlightingPrefix = highlightingPrefix; + public void setHighlightPrefix(final String highlightPrefix) { + this.highlightPrefix = highlightPrefix; } - public String getHighlightingPrefix() { - return highlightingPrefix; + public String getHighlightPrefix() { + return highlightPrefix; } public String[] getSupportedMltFields() { @@ -1396,7 +1383,7 @@ public class QueryHelper implements Serializable { return additionalQueryParamMap; } - final HttpServletRequest request = RequestUtil.getRequest(); + final HttpServletRequest request = LaRequestUtil.getOptionalRequest().orElse(null); final Map queryParamMap = new HashMap(); for (final Map.Entry entry : additionalQueryParamMap.entrySet()) { final String[] values = entry.getValue(); @@ -1434,7 +1421,7 @@ public class QueryHelper implements Serializable { } protected String getDefaultOperator() { - final HttpServletRequest request = RequestUtil.getRequest(); + final HttpServletRequest request = LaRequestUtil.getOptionalRequest().orElse(null); if (request != null) { final String defaultOperator = (String) request.getAttribute(Constants.DEFAULT_OPERATOR); if (AND.equalsIgnoreCase(defaultOperator)) { diff --git a/src/main/java/org/codelibs/fess/helper/RobotLogHelper.java b/src/main/java/org/codelibs/fess/helper/RobotLogHelper.java index 4b453f116..664a98415 100644 --- a/src/main/java/org/codelibs/fess/helper/RobotLogHelper.java +++ b/src/main/java/org/codelibs/fess/helper/RobotLogHelper.java @@ -16,15 +16,15 @@ package org.codelibs.fess.helper; +import org.codelibs.fess.app.service.FailureUrlService; import org.codelibs.fess.es.exentity.CrawlingConfig; -import org.codelibs.fess.service.FailureUrlService; import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.robot.RobotMultipleCrawlAccessException; import org.codelibs.robot.S2RobotContext; import org.codelibs.robot.entity.UrlQueue; +import org.codelibs.robot.exception.RobotMultipleCrawlAccessException; import org.codelibs.robot.helper.impl.LogHelperImpl; import org.codelibs.robot.log.LogType; -import org.seasar.framework.container.SingletonS2Container; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -80,7 +80,7 @@ public class RobotLogHelper extends LogHelperImpl { final CrawlingConfig crawlingConfig = getCrawlingConfig(robotContext.getSessionId()); final String url = urlQueue.getUrl(); - final FailureUrlService failureUrlService = SingletonS2Container.getComponent(FailureUrlService.class); + final FailureUrlService failureUrlService = SingletonLaContainer.getComponent(FailureUrlService.class); failureUrlService.store(crawlingConfig, errorName, url, e); } diff --git a/src/main/java/org/codelibs/fess/helper/SearchLogHelper.java b/src/main/java/org/codelibs/fess/helper/SearchLogHelper.java index 5e49f1bb1..c08a90747 100644 --- a/src/main/java/org/codelibs/fess/helper/SearchLogHelper.java +++ b/src/main/java/org/codelibs/fess/helper/SearchLogHelper.java @@ -20,13 +20,13 @@ import java.util.Map; import java.util.Queue; import java.util.concurrent.ConcurrentLinkedQueue; +import javax.annotation.PostConstruct; import javax.annotation.Resource; +import org.codelibs.core.collection.LruHashMap; import org.codelibs.core.misc.DynamicProperties; import org.codelibs.fess.es.exentity.ClickLog; import org.codelibs.fess.es.exentity.SearchLog; -import org.codelibs.robot.util.LruHashMap; -import org.seasar.framework.container.annotation.tiger.InitMethod; public abstract class SearchLogHelper { @@ -43,7 +43,7 @@ public abstract class SearchLogHelper { protected Map userInfoCache; - @InitMethod + @PostConstruct public void init() { userInfoCache = new LruHashMap(userInfoCacheSize); } @@ -86,7 +86,7 @@ public abstract class SearchLogHelper { protected abstract void processClickLogQueue(Queue queue); - public boolean addfavoriteLog(String userCode, String favoriteUrl) { + public boolean addfavoriteLog(final String userCode, final String favoriteUrl) { // TODO Auto-generated method stub return false; } diff --git a/src/main/java/org/codelibs/fess/helper/SystemHelper.java b/src/main/java/org/codelibs/fess/helper/SystemHelper.java index a5ac6f9ce..4bfd6e217 100644 --- a/src/main/java/org/codelibs/fess/helper/SystemHelper.java +++ b/src/main/java/org/codelibs/fess/helper/SystemHelper.java @@ -19,9 +19,9 @@ package org.codelibs.fess.helper; import java.io.Serializable; import java.io.UnsupportedEncodingException; import java.net.URLEncoder; -import java.time.LocalDateTime; import java.util.ArrayList; import java.util.Collection; +import java.util.Date; import java.util.HashMap; import java.util.HashSet; import java.util.List; @@ -33,17 +33,18 @@ import java.util.concurrent.ExecutionException; import java.util.concurrent.TimeUnit; import java.util.concurrent.atomic.AtomicBoolean; -import org.apache.commons.lang.LocaleUtils; -import org.apache.commons.lang.StringUtils; +import javax.annotation.PostConstruct; + +import org.apache.commons.lang3.LocaleUtils; +import org.apache.commons.lang3.StringUtils; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; +import org.codelibs.fess.app.service.RoleTypeService; import org.codelibs.fess.es.exentity.RoleType; -import org.codelibs.fess.service.RoleTypeService; +import org.codelibs.fess.util.ComponentUtil; import org.codelibs.robot.util.CharUtil; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.framework.container.annotation.tiger.InitMethod; -import org.seasar.struts.util.MessageResourcesUtil; -import org.seasar.struts.util.RequestUtil; +import org.lastaflute.di.core.SingletonLaContainer; +import org.lastaflute.web.util.LaRequestUtil; import com.google.common.cache.CacheBuilder; import com.google.common.cache.CacheLoader; @@ -56,12 +57,11 @@ public class SystemHelper implements Serializable { private final Set adminRoleSet = new HashSet<>(); - private String[] crawlerJavaOptions = new String[] { "-Djava.awt.headless=true", "-server", "-Xmx512m", "-XX:MaxPermSize=128m", - "-XX:-UseGCOverheadLimit", "-XX:+UseConcMarkSweepGC", "-XX:CMSInitiatingOccupancyFraction=75", "-XX:+CMSIncrementalMode", - "-XX:+CMSIncrementalPacing", "-XX:CMSIncrementalDutyCycleMin=0", "-XX:+UseParNewGC", "-XX:+UseStringCache", "-XX:+UseTLAB", - "-XX:+DisableExplicitGC" }; + private String[] crawlerJavaOptions = new String[] { "-Djava.awt.headless=true", "-server", "-Xmx256m", "-XX:MaxMetaspaceSize=128m", + "-XX:CompressedClassSpaceSize=32m", "-XX:-UseGCOverheadLimit", "-XX:+UseConcMarkSweepGC", + "-XX:CMSInitiatingOccupancyFraction=75", "-XX:+UseParNewGC", "-XX:+UseTLAB", "-XX:+DisableExplicitGC" }; - private String logFilePath = System.getProperty("fess.log.file"); + private String logFilePath = System.getProperty("fess.log.path", "target/logs"); private String javaCommandPath = "java"; @@ -90,7 +90,7 @@ public class SystemHelper implements Serializable { protected LoadingCache>> langItemsCache; - @InitMethod + @PostConstruct public void init() { langItemsCache = CacheBuilder.newBuilder().maximumSize(20).expireAfterAccess(1, TimeUnit.HOURS) @@ -100,7 +100,7 @@ public class SystemHelper implements Serializable { final ULocale uLocale = new ULocale(key); final Locale displayLocale = uLocale.toLocale(); final List> langItems = new ArrayList<>(supportedLanguages.length); - final String msg = MessageResourcesUtil.getMessage(displayLocale, "labels.allLanguages"); + final String msg = ComponentUtil.getMessageManager().getMessage(displayLocale, "labels.allLanguages"); final Map defaultMap = new HashMap<>(2); defaultMap.put(Constants.ITEM_LABEL, msg); defaultMap.put(Constants.ITEM_VALUE, "all"); @@ -120,15 +120,13 @@ public class SystemHelper implements Serializable { } public String getUsername() { - String username = RequestUtil.getRequest().getRemoteUser(); - if (StringUtil.isBlank(username)) { - username = "guest"; - } - return username; + return ComponentUtil.getLoginAssist().getSessionUserBean().map(user -> { + return user.getUserId(); + }).orElse(Constants.GUEST_USER); } - public LocalDateTime getCurrentTime() { - return LocalDateTime.now(); + public Date getCurrentTime() { + return new Date(); } public long getCurrentTimeAsLong() { @@ -165,7 +163,7 @@ public class SystemHelper implements Serializable { } public String getHelpLink(final String name) { - final Locale locale = RequestUtil.getRequest().getLocale(); + final Locale locale = LaRequestUtil.getRequest().getLocale(); if (locale != null) { final String lang = locale.getLanguage(); for (final String l : supportedHelpLangs) { @@ -195,7 +193,7 @@ public class SystemHelper implements Serializable { } public Set getAuthenticatedRoleSet() { - final RoleTypeService roleTypeService = SingletonS2Container.getComponent(RoleTypeService.class); + final RoleTypeService roleTypeService = SingletonLaContainer.getComponent(RoleTypeService.class); final List roleTypeList = roleTypeService.getRoleTypeList(); final Set roleList = new HashSet<>(roleTypeList.size() + adminRoleSet.size()); @@ -350,7 +348,7 @@ public class SystemHelper implements Serializable { return langItemsCache.get(localeStr); } catch (final ExecutionException e) { final List> langItems = new ArrayList<>(supportedLanguages.length); - final String msg = MessageResourcesUtil.getMessage(locale, "labels.allLanguages"); + final String msg = ComponentUtil.getMessageManager().getMessage(locale, "labels.allLanguages"); final Map defaultMap = new HashMap<>(2); defaultMap.put(Constants.ITEM_LABEL, msg); defaultMap.put(Constants.ITEM_VALUE, "all"); diff --git a/src/main/java/org/codelibs/fess/helper/UserAgentHelper.java b/src/main/java/org/codelibs/fess/helper/UserAgentHelper.java index 60e53eb5c..a13ca0368 100644 --- a/src/main/java/org/codelibs/fess/helper/UserAgentHelper.java +++ b/src/main/java/org/codelibs/fess/helper/UserAgentHelper.java @@ -18,7 +18,7 @@ package org.codelibs.fess.helper; import javax.servlet.http.HttpServletRequest; -import org.seasar.struts.util.RequestUtil; +import org.lastaflute.web.util.LaRequestUtil; public class UserAgentHelper { private static final String USER_AGENT = "user-agent"; @@ -26,7 +26,7 @@ public class UserAgentHelper { private static final String USER_AGENT_TYPE = "ViewHelper.UserAgent"; public UserAgentType getUserAgentType() { - final HttpServletRequest request = RequestUtil.getRequest(); + final HttpServletRequest request = LaRequestUtil.getRequest(); UserAgentType uaType = (UserAgentType) request.getAttribute(USER_AGENT_TYPE); if (uaType == null) { final String userAgent = request.getHeader(USER_AGENT); diff --git a/src/main/java/org/codelibs/fess/helper/ViewHelper.java b/src/main/java/org/codelibs/fess/helper/ViewHelper.java index 1bcf9c48c..f59824bfa 100644 --- a/src/main/java/org/codelibs/fess/helper/ViewHelper.java +++ b/src/main/java/org/codelibs/fess/helper/ViewHelper.java @@ -16,7 +16,10 @@ package org.codelibs.fess.helper; +import java.io.BufferedInputStream; import java.io.File; +import java.io.IOException; +import java.io.InputStream; import java.io.Serializable; import java.io.UnsupportedEncodingException; import java.net.URLDecoder; @@ -31,26 +34,39 @@ import java.util.concurrent.ConcurrentHashMap; import java.util.regex.Matcher; import java.util.regex.Pattern; +import javax.annotation.PostConstruct; import javax.annotation.Resource; import javax.servlet.http.HttpServletRequest; -import org.apache.commons.lang.StringUtils; +import org.apache.commons.lang3.StringUtils; import org.codelibs.core.CoreLibConstants; import org.codelibs.core.lang.StringUtil; +import org.codelibs.core.misc.Base64Util; import org.codelibs.core.misc.DynamicProperties; +import org.codelibs.core.net.URLUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.app.service.DataConfigService; +import org.codelibs.fess.app.service.FileConfigService; +import org.codelibs.fess.app.service.WebConfigService; import org.codelibs.fess.entity.FacetQueryView; +import org.codelibs.fess.es.exentity.CrawlingConfig; +import org.codelibs.fess.es.exentity.CrawlingConfig.ConfigType; +import org.codelibs.fess.exception.FessSystemException; import org.codelibs.fess.helper.UserAgentHelper.UserAgentType; import org.codelibs.fess.util.ComponentUtil; +import org.codelibs.fess.util.DocumentUtil; import org.codelibs.fess.util.ResourceUtil; +import org.codelibs.robot.builder.RequestDataBuilder; +import org.codelibs.robot.client.S2RobotClient; +import org.codelibs.robot.client.S2RobotClientFactory; +import org.codelibs.robot.entity.ResponseData; import org.codelibs.robot.util.CharUtil; -import org.seasar.framework.container.annotation.tiger.InitMethod; -import org.seasar.framework.util.URLUtil; -import org.seasar.struts.taglib.S2Functions; -import org.seasar.struts.util.MessageResourcesUtil; -import org.seasar.struts.util.RequestUtil; -import org.seasar.struts.util.ServletContextUtil; +import org.lastaflute.di.core.SingletonLaContainer; +import org.lastaflute.taglib.function.LaFunctions; +import org.lastaflute.web.response.StreamResponse; +import org.lastaflute.web.util.LaRequestUtil; +import org.lastaflute.web.util.LaResponseUtil; +import org.lastaflute.web.util.LaServletContextUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -87,11 +103,11 @@ public class ViewHelper implements Serializable { public String[] highlightingFields = new String[] { "hl_content", "digest" }; - public boolean useSolrHighlight = false; + public boolean useHighlight = false; - public String solrHighlightTagPre = ""; + public String originalHighlightTagPre = ""; - public String solrHighlightTagPost = ""; + public String originalHighlightTagPost = ""; public String highlightTagPre = ""; @@ -109,15 +125,15 @@ public class ViewHelper implements Serializable { public String cacheTemplateName = "cache"; - private String escapedSolrHighlightPre = null; + private String escapedHighlightPre = null; - private String escapedSolrHighlightPost = null; + private String escapedHighlightPost = null; - @InitMethod + @PostConstruct public void init() { - if (useSolrHighlight) { - escapedSolrHighlightPre = S2Functions.h(solrHighlightTagPre); - escapedSolrHighlightPost = S2Functions.h(solrHighlightTagPost); + if (useHighlight) { + escapedHighlightPre = LaFunctions.h(originalHighlightTagPre); + escapedHighlightPost = LaFunctions.h(originalHighlightTagPost); } } @@ -142,17 +158,17 @@ public class ViewHelper implements Serializable { } public String getContentDescription(final Map document) { - final HttpServletRequest request = RequestUtil.getRequest(); + final HttpServletRequest request = LaRequestUtil.getOptionalRequest().orElse(null); final String[] queries = request == null ? StringUtil.EMPTY_STRINGS : (String[]) request.getAttribute(Constants.HIGHLIGHT_QUERIES); final int size = descriptionLength; for (final String field : highlightingFields) { final String text = getString(document, field); if (StringUtil.isNotBlank(text)) { - if (useSolrHighlight) { + if (useHighlight) { return escapeHighlight(text); } else { - return highlight(S2Functions.h(StringUtils.abbreviate(removeSolrHighlightTag(text), size)), queries); + return highlight(LaFunctions.h(StringUtils.abbreviate(removeSolrHighlightTag(text), size)), queries); } } } @@ -161,12 +177,12 @@ public class ViewHelper implements Serializable { } protected String escapeHighlight(final String text) { - return S2Functions.h(text).replaceAll(escapedSolrHighlightPre, solrHighlightTagPre) - .replaceAll(escapedSolrHighlightPost, solrHighlightTagPost); + return LaFunctions.h(text).replaceAll(escapedHighlightPre, originalHighlightTagPre) + .replaceAll(escapedHighlightPost, originalHighlightTagPost); } protected String removeSolrHighlightTag(final String str) { - return str.replaceAll(solrHighlightTagPre, StringUtil.EMPTY).replaceAll(solrHighlightTagPost, StringUtil.EMPTY); + return str.replaceAll(originalHighlightTagPre, StringUtil.EMPTY).replaceAll(originalHighlightTagPost, StringUtil.EMPTY); } protected String highlight(final String content, final String[] queries) { @@ -297,7 +313,7 @@ public class ViewHelper implements Serializable { } protected String appendPDFSearchWord(final String url) { - final String[] queries = (String[]) RequestUtil.getRequest().getAttribute(Constants.HIGHLIGHT_QUERIES); + final String[] queries = (String[]) LaRequestUtil.getRequest().getAttribute(Constants.HIGHLIGHT_QUERIES); if (queries != null) { final StringBuilder buf = new StringBuilder(url.length() + 100); buf.append(url).append("#search=%22"); @@ -314,7 +330,7 @@ public class ViewHelper implements Serializable { } public String getPagePath(final String page) { - final Locale locale = RequestUtil.getRequest().getLocale(); + final Locale locale = LaRequestUtil.getRequest().getLocale(); final String lang = locale.getLanguage(); final String country = locale.getCountry(); @@ -365,7 +381,7 @@ public class ViewHelper implements Serializable { } private boolean existsPage(final String path) { - final String realPath = ServletContextUtil.getServletContext().getRealPath(path); + final String realPath = LaServletContextUtil.getServletContext().getRealPath(path); final File file = new File(realPath); return file.isFile(); } @@ -375,22 +391,24 @@ public class ViewHelper implements Serializable { final FileTemplateLoader loader = new FileTemplateLoader(new File(ResourceUtil.getViewTemplatePath(StringUtil.EMPTY))); final Handlebars handlebars = new Handlebars(loader); - Locale locale = RequestUtil.getRequest().getLocale(); + Locale locale = LaRequestUtil.getRequest().getLocale(); if (locale == null) { locale = Locale.ENGLISH; } - String url = (String) doc.get("urlLink"); + String url = DocumentUtil.getValue(doc, "urlLink", String.class); if (url == null) { - url = MessageResourcesUtil.getMessage(locale, "labels.search_unknown"); + url = ComponentUtil.getMessageManager().getMessage(locale, "labels.search_unknown"); } - Object created = doc.get(fieldHelper.createdField); - if (created instanceof Date) { + String createdStr; + final Long created = DocumentUtil.getValue(doc, fieldHelper.createdField, Long.class); + if (created != null) { final SimpleDateFormat sdf = new SimpleDateFormat(CoreLibConstants.DATE_FORMAT_ISO_8601_EXTEND); - created = sdf.format((Date) created); + createdStr = sdf.format(new Date(created.longValue())); } else { - created = MessageResourcesUtil.getMessage(locale, "labels.search_unknown"); + createdStr = ComponentUtil.getMessageManager().getMessage(locale, "labels.search_unknown"); } - doc.put("cacheMsg", MessageResourcesUtil.getMessage(locale, "labels.search_cache_msg", url, created)); + doc.put("cacheMsg", + ComponentUtil.getMessageManager().getMessage(locale, "labels.search_cache_msg", new Object[] { url, createdStr })); doc.put("queries", queries); @@ -457,6 +475,134 @@ public class ViewHelper implements Serializable { return null; } + public StreamResponse asContentResponse(final Map doc) { + if (logger.isDebugEnabled()) { + logger.debug("writing the content of: " + doc); + } + final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); + final CrawlingConfigHelper crawlingConfigHelper = ComponentUtil.getCrawlingConfigHelper(); + final Object configIdObj = doc.get(fieldHelper.configIdField); + if (configIdObj == null) { + throw new FessSystemException("configId is null."); + } + final String configId = configIdObj.toString(); + if (configId.length() < 2) { + throw new FessSystemException("Invalid configId: " + configIdObj); + } + final ConfigType configType = crawlingConfigHelper.getConfigType(configId); + CrawlingConfig config = null; + if (logger.isDebugEnabled()) { + logger.debug("configType: " + configType + ", configId: " + configId); + } + if (ConfigType.WEB == configType) { + final WebConfigService webConfigService = SingletonLaContainer.getComponent(WebConfigService.class); + config = webConfigService.getWebConfig(crawlingConfigHelper.getId(configId)); + } else if (ConfigType.FILE == configType) { + final FileConfigService fileConfigService = SingletonLaContainer.getComponent(FileConfigService.class); + config = fileConfigService.getFileConfig(crawlingConfigHelper.getId(configId)); + } else if (ConfigType.DATA == configType) { + final DataConfigService dataConfigService = SingletonLaContainer.getComponent(DataConfigService.class); + config = dataConfigService.getDataConfig(crawlingConfigHelper.getId(configId)); + } + if (config == null) { + throw new FessSystemException("No crawlingConfig: " + configIdObj); + } + final String url = (String) doc.get(fieldHelper.urlField); + final S2RobotClientFactory robotClientFactory = SingletonLaContainer.getComponent(S2RobotClientFactory.class); + config.initializeClientFactory(robotClientFactory); + final S2RobotClient client = robotClientFactory.getClient(url); + if (client == null) { + throw new FessSystemException("No S2RobotClient: " + configIdObj + ", url: " + url); + } + final ResponseData responseData = client.execute(RequestDataBuilder.newRequestData().get().url(url).build()); + final StreamResponse response = new StreamResponse(StringUtil.EMPTY); + writeFileName(response, responseData); + writeContentType(response, responseData); + writeNoCache(response, responseData); + response.stream(out -> { + try (InputStream is = new BufferedInputStream(responseData.getResponseBody())) { + out.write(is); + } catch (final IOException e) { + if (!"ClientAbortException".equals(e.getClass().getSimpleName())) { + throw new FessSystemException("Failed to write a content. configId: " + configIdObj + ", url: " + url, e); + } + } + if (logger.isDebugEnabled()) { + logger.debug("Finished to write " + url); + } + }); + return response; + } + + protected void writeNoCache(final StreamResponse response, final ResponseData responseData) { + response.header("Pragma", "no-cache"); + response.header("Cache-Control", "no-cache"); + response.header("Expires", "Thu, 01 Dec 1994 16:00:00 GMT"); + } + + protected void writeFileName(final StreamResponse response, final ResponseData responseData) { + final UserAgentHelper userAgentHelper = ComponentUtil.getUserAgentHelper(); + final UserAgentType userAgentType = userAgentHelper.getUserAgentType(); + String charset = responseData.getCharSet(); + if (charset == null) { + charset = Constants.UTF_8; + } + final String name; + final String url = responseData.getUrl(); + final int pos = url.lastIndexOf('/'); + try { + if (pos >= 0 && pos + 1 < url.length()) { + name = URLDecoder.decode(url.substring(pos + 1), charset); + } else { + name = URLDecoder.decode(url, charset); + } + + if (logger.isDebugEnabled()) { + logger.debug("userAgentType: " + userAgentType + ", charset: " + charset + ", name: " + name); + } + + switch (userAgentType) { + case IE: + response.header("Content-Disposition", "attachment; filename=\"" + URLEncoder.encode(name, Constants.UTF_8) + "\""); + break; + case OPERA: + response.header("Content-Disposition", "attachment; filename*=utf-8'ja'" + URLEncoder.encode(name, Constants.UTF_8)); + break; + case SAFARI: + response.header("Content-Disposition", "attachment; filename=\"" + name + "\""); + break; + case CHROME: + case FIREFOX: + case OTHER: + default: + response.header("Content-Disposition", + "attachment; filename=\"=?utf-8?B?" + Base64Util.encode(name.getBytes(Constants.UTF_8)) + "?=\""); + break; + } + } catch (final Exception e) { + logger.warn("Failed to write a filename: " + responseData, e); + } + } + + protected void writeContentType(final StreamResponse response, final ResponseData responseData) { + final String mimeType = responseData.getMimeType(); + if (logger.isDebugEnabled()) { + logger.debug("mimeType: " + mimeType); + } + if (mimeType == null) { + response.contentTypeOctetStream(); + return; + } + if (mimeType.startsWith("text/")) { + final String charset = LaResponseUtil.getResponse().getCharacterEncoding(); + if (charset != null) { + response.contentType(mimeType + "; charset=" + charset); + return; + } + } + response.contentType(mimeType); + } + public boolean isUseSession() { return useSession; } diff --git a/src/main/java/org/codelibs/fess/helper/WebFsIndexHelper.java b/src/main/java/org/codelibs/fess/helper/WebFsIndexHelper.java index 8f0ebd8bc..d5cd755d1 100644 --- a/src/main/java/org/codelibs/fess/helper/WebFsIndexHelper.java +++ b/src/main/java/org/codelibs/fess/helper/WebFsIndexHelper.java @@ -26,23 +26,23 @@ import javax.annotation.Resource; import org.codelibs.core.lang.StringUtil; import org.codelibs.core.misc.DynamicProperties; import org.codelibs.fess.Constants; +import org.codelibs.fess.app.service.BoostDocumentRuleService; +import org.codelibs.fess.app.service.FailureUrlService; +import org.codelibs.fess.app.service.FileAuthenticationService; +import org.codelibs.fess.app.service.FileConfigService; +import org.codelibs.fess.app.service.WebConfigService; +import org.codelibs.fess.crawler.interval.FessIntervalController; import org.codelibs.fess.es.exentity.BoostDocumentRule; import org.codelibs.fess.es.exentity.FileConfig; import org.codelibs.fess.es.exentity.WebConfig; -import org.codelibs.fess.interval.FessIntervalController; -import org.codelibs.fess.service.BoostDocumentRuleService; -import org.codelibs.fess.service.FailureUrlService; -import org.codelibs.fess.service.FileAuthenticationService; -import org.codelibs.fess.service.FileConfigService; -import org.codelibs.fess.service.WebConfigService; -import org.codelibs.fess.solr.IndexUpdater; +import org.codelibs.fess.indexer.IndexUpdater; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.robot.S2Robot; import org.codelibs.robot.S2RobotContext; import org.codelibs.robot.service.DataService; import org.codelibs.robot.service.UrlFilterService; import org.codelibs.robot.service.UrlQueueService; -import org.seasar.framework.container.SingletonS2Container; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -147,7 +147,7 @@ public class WebFsIndexHelper implements Serializable { final String sid = crawlingConfigHelper.store(sessionId, webConfig); // create s2robot - final S2Robot s2Robot = SingletonS2Container.getComponent(S2Robot.class); + final S2Robot s2Robot = SingletonLaContainer.getComponent(S2Robot.class); s2Robot.setSessionId(sid); sessionIdList.add(sid); @@ -253,7 +253,7 @@ public class WebFsIndexHelper implements Serializable { final String sid = crawlingConfigHelper.store(sessionId, fileConfig); // create s2robot - final S2Robot s2Robot = SingletonS2Container.getComponent(S2Robot.class); + final S2Robot s2Robot = SingletonLaContainer.getComponent(S2Robot.class); s2Robot.setSessionId(sid); sessionIdList.add(sid); @@ -388,7 +388,7 @@ public class WebFsIndexHelper implements Serializable { indexUpdater.setDaemon(true); indexUpdater.setS2RobotList(s2RobotList); for (final BoostDocumentRule rule : boostDocumentRuleService.getAvailableBoostDocumentRuleList()) { - indexUpdater.addBoostDocumentRule(new org.codelibs.fess.solr.BoostDocumentRule(rule)); + indexUpdater.addBoostDocumentRule(new org.codelibs.fess.indexer.BoostDocumentRule(rule)); } indexUpdater.start(); @@ -477,15 +477,15 @@ public class WebFsIndexHelper implements Serializable { } // clear url filter - final UrlFilterService urlFilterService = SingletonS2Container.getComponent(UrlFilterService.class); + final UrlFilterService urlFilterService = SingletonLaContainer.getComponent(UrlFilterService.class); urlFilterService.deleteAll(); // clear queue - final UrlQueueService urlQueueService = SingletonS2Container.getComponent(UrlQueueService.class); + final UrlQueueService urlQueueService = SingletonLaContainer.getComponent(UrlQueueService.class); urlQueueService.deleteAll(); // clear - final DataService dataService = SingletonS2Container.getComponent(DataService.class); + final DataService dataService = SingletonLaContainer.getComponent(DataService.class); dataService.deleteAll(); } diff --git a/src/main/java/org/codelibs/fess/helper/WebManagementHelper.java b/src/main/java/org/codelibs/fess/helper/WebManagementHelper.java deleted file mode 100644 index 0b4fca823..000000000 --- a/src/main/java/org/codelibs/fess/helper/WebManagementHelper.java +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.helper; - -import java.util.List; - -public interface WebManagementHelper { - - boolean hasSolrInstance(); - - List getSolrInstanceNameList(); - - String getStatus(String name); - - void start(String name); - - void stop(String name); - - void reload(String name); - -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/helper/impl/CookieUserInfoHelperImpl.java b/src/main/java/org/codelibs/fess/helper/impl/CookieUserInfoHelperImpl.java index f8b0ec393..621c96c71 100644 --- a/src/main/java/org/codelibs/fess/helper/impl/CookieUserInfoHelperImpl.java +++ b/src/main/java/org/codelibs/fess/helper/impl/CookieUserInfoHelperImpl.java @@ -26,15 +26,15 @@ import javax.servlet.http.Cookie; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpSession; +import org.codelibs.core.collection.LruHashMap; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; import org.codelibs.fess.helper.FieldHelper; import org.codelibs.fess.helper.SearchLogHelper; import org.codelibs.fess.helper.UserInfoHelper; import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.robot.util.LruHashMap; -import org.seasar.struts.util.RequestUtil; -import org.seasar.struts.util.ResponseUtil; +import org.lastaflute.web.util.LaRequestUtil; +import org.lastaflute.web.util.LaResponseUtil; public class CookieUserInfoHelperImpl implements UserInfoHelper { @@ -58,7 +58,7 @@ public class CookieUserInfoHelperImpl implements UserInfoHelper { */ @Override public String getUserCode() { - final HttpServletRequest request = RequestUtil.getRequest(); + final HttpServletRequest request = LaRequestUtil.getRequest(); String userCode = (String) request.getAttribute(Constants.USER_CODE); @@ -87,7 +87,7 @@ public class CookieUserInfoHelperImpl implements UserInfoHelper { protected void updateUserSessionId(final String userCode) { searchLogHelper.updateUserInfo(userCode); - final HttpServletRequest request = RequestUtil.getRequest(); + final HttpServletRequest request = LaRequestUtil.getRequest(); request.setAttribute(Constants.USER_CODE, userCode); final Cookie cookie = new Cookie(cookieName, userCode); @@ -101,7 +101,7 @@ public class CookieUserInfoHelperImpl implements UserInfoHelper { if (cookieSecure != null) { cookie.setSecure(cookieSecure); } - ResponseUtil.getResponse().addCookie(cookie); + LaResponseUtil.getResponse().addCookie(cookie); } protected String getUserCodeFromCookie(final HttpServletRequest request) { @@ -118,7 +118,7 @@ public class CookieUserInfoHelperImpl implements UserInfoHelper { @Override public String generateQueryId(final String query, final List> documentItems) { - final HttpSession session = RequestUtil.getRequest().getSession(false); + final HttpSession session = LaRequestUtil.getRequest().getSession(false); if (session != null) { final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); @@ -143,7 +143,7 @@ public class CookieUserInfoHelperImpl implements UserInfoHelper { @Override public String[] getResultDocIds(final String queryId) { - final HttpSession session = RequestUtil.getRequest().getSession(false); + final HttpSession session = LaRequestUtil.getRequest().getSession(false); if (session != null) { final Map resultUrlCache = getResultDocIdsCache(session); final String[] urls = resultUrlCache.get(queryId); diff --git a/src/main/java/org/codelibs/fess/helper/impl/DatabaseHelperImpl.java b/src/main/java/org/codelibs/fess/helper/impl/DatabaseHelperImpl.java deleted file mode 100644 index 17b3d406e..000000000 --- a/src/main/java/org/codelibs/fess/helper/impl/DatabaseHelperImpl.java +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.helper.impl; - -import org.codelibs.fess.helper.DatabaseHelper; -import org.codelibs.robot.service.DataService; -import org.codelibs.robot.service.UrlFilterService; -import org.codelibs.robot.service.UrlQueueService; - -public class DatabaseHelperImpl implements DatabaseHelper { - - public DataService dataService; - - public UrlQueueService urlQueueService; - - public UrlFilterService urlFilterService; - - @Override - public void optimize() { - urlQueueService.deleteAll(); - dataService.deleteAll(); - urlFilterService.deleteAll(); - } - -} diff --git a/src/main/java/org/codelibs/fess/helper/impl/EmptyManagementHelperImpl.java b/src/main/java/org/codelibs/fess/helper/impl/EmptyManagementHelperImpl.java deleted file mode 100644 index da75f4edd..000000000 --- a/src/main/java/org/codelibs/fess/helper/impl/EmptyManagementHelperImpl.java +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.helper.impl; - -import java.util.List; - -import org.codelibs.fess.helper.WebManagementHelper; - -public class EmptyManagementHelperImpl implements WebManagementHelper { - - @Override - public boolean hasSolrInstance() { - return false; - } - - @Override - public List getSolrInstanceNameList() { - return null; - } - - @Override - public String getStatus(final String name) { - return null; - } - - @Override - public void start(final String name) { - // nothing - } - - @Override - public void stop(final String name) { - // nothing - } - - @Override - public void reload(final String name) { - // nothing - } - -} diff --git a/src/main/java/org/codelibs/fess/helper/impl/H2DatabaseHelperImpl.java b/src/main/java/org/codelibs/fess/helper/impl/H2DatabaseHelperImpl.java deleted file mode 100644 index 94ffdcb8d..000000000 --- a/src/main/java/org/codelibs/fess/helper/impl/H2DatabaseHelperImpl.java +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.helper.impl; - -import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.helper.DatabaseHelper; -import org.codelibs.fess.util.ResourceUtil; -import org.h2.tools.DeleteDbFiles; -import org.h2.tools.RunScript; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class H2DatabaseHelperImpl implements DatabaseHelper { - private static final Logger logger = LoggerFactory.getLogger(H2DatabaseHelperImpl.class); - - public String databaseName = "robot"; - - public String databasePath = ResourceUtil.getDbPath(StringUtil.EMPTY); - - public String user = "sa"; - - public String password = StringUtil.EMPTY; - - public String sqlFilePath = ResourceUtil.getClassesPath("sql/robot.ddl"); - - public boolean printLogOnError = false; - - /* (non-Javadoc) - * @see org.codelibs.fess.helper.impl.DatabaseHelper#optimize() - */ - @Override - public synchronized void optimize() { - final String url = "jdbc:h2:" + databasePath + "/" + databaseName; - try { - DeleteDbFiles.execute(databasePath, databaseName, false); - RunScript.execute(url, user, password, sqlFilePath, null, false); - } catch (final Exception e) { - if (printLogOnError) { - logger.error("Failed to optimize H2 Database: " + databasePath + "/" + databaseName, e); - } - } - } -} diff --git a/src/main/java/org/codelibs/fess/helper/impl/RoleQueryHelperImpl.java b/src/main/java/org/codelibs/fess/helper/impl/RoleQueryHelperImpl.java index 11d820221..c5443bc2a 100644 --- a/src/main/java/org/codelibs/fess/helper/impl/RoleQueryHelperImpl.java +++ b/src/main/java/org/codelibs/fess/helper/impl/RoleQueryHelperImpl.java @@ -30,11 +30,11 @@ import javax.servlet.http.HttpSession; import org.codelibs.core.crypto.CachedCipher; import org.codelibs.core.lang.StringUtil; +import org.codelibs.fess.Constants; import org.codelibs.fess.entity.LoginInfo; import org.codelibs.fess.helper.RoleQueryHelper; import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.sastruts.core.SSCConstants; -import org.seasar.struts.util.RequestUtil; +import org.lastaflute.web.util.LaRequestUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -82,7 +82,7 @@ public class RoleQueryHelperImpl implements RoleQueryHelper, Serializable { @Override public Set build() { final Set roleList = new HashSet<>(); - final HttpServletRequest request = RequestUtil.getRequest(); + final HttpServletRequest request = LaRequestUtil.getOptionalRequest().orElse(null); // request parameter if (request != null && StringUtil.isNotBlank(parameterKey)) { @@ -108,7 +108,7 @@ public class RoleQueryHelperImpl implements RoleQueryHelper, Serializable { if (request != null) { final HttpSession session = request.getSession(false); if (session != null) { - final LoginInfo loginInfo = (LoginInfo) session.getAttribute(SSCConstants.USER_INFO); + final LoginInfo loginInfo = (LoginInfo) session.getAttribute(Constants.USER_INFO); if (loginInfo != null) { roleList.addAll(loginInfo.getRoleSet()); } diff --git a/src/main/java/org/codelibs/fess/helper/impl/SearchLogHelperImpl.java b/src/main/java/org/codelibs/fess/helper/impl/SearchLogHelperImpl.java index 267e3d357..9e525ee15 100644 --- a/src/main/java/org/codelibs/fess/helper/impl/SearchLogHelperImpl.java +++ b/src/main/java/org/codelibs/fess/helper/impl/SearchLogHelperImpl.java @@ -22,10 +22,10 @@ import java.util.List; import java.util.Map; import java.util.Queue; +import org.codelibs.core.beans.util.BeanUtil; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.client.FessEsClient; +import org.codelibs.fess.es.client.FessEsClient; import org.codelibs.fess.es.exbhv.ClickLogBhv; import org.codelibs.fess.es.exbhv.SearchLogBhv; import org.codelibs.fess.es.exbhv.UserInfoBhv; @@ -35,7 +35,7 @@ import org.codelibs.fess.es.exentity.UserInfo; import org.codelibs.fess.helper.FieldHelper; import org.codelibs.fess.helper.SearchLogHelper; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.framework.container.SingletonS2Container; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -130,14 +130,14 @@ public class SearchLogHelperImpl extends SearchLogHelper { if (!userInfoMap.isEmpty()) { final List insertList = new ArrayList(userInfoMap.values()); final List updateList = new ArrayList(); - final UserInfoBhv userInfoBhv = SingletonS2Container.getComponent(UserInfoBhv.class); + final UserInfoBhv userInfoBhv = SingletonLaContainer.getComponent(UserInfoBhv.class); final List list = userInfoBhv.selectList(cb -> { cb.query().setCode_InScope(userInfoMap.keySet()); }); for (final UserInfo userInfo : list) { final String code = userInfo.getCode(); final UserInfo entity = userInfoMap.get(code); - FessBeans.copy(userInfo, entity).includes("id", "createdTime").execute(); + BeanUtil.copyBeanToBean(userInfo, entity, option -> option.include("id", "createdTime")); updateList.add(entity); insertList.remove(entity); } @@ -165,7 +165,7 @@ public class SearchLogHelperImpl extends SearchLogHelper { final List clickLogList = new ArrayList(); for (final ClickLog clickLog : queue) { try { - final SearchLogBhv searchLogBhv = SingletonS2Container.getComponent(SearchLogBhv.class); + final SearchLogBhv searchLogBhv = SingletonLaContainer.getComponent(SearchLogBhv.class); final SearchLog entity = searchLogBhv.selectEntity(cb -> { cb.query().setRequestedTime_Equal(clickLog.getQueryRequestedTime()); cb.query().setUserSessionId_Equal(clickLog.getUserSessionId()); @@ -192,7 +192,7 @@ public class SearchLogHelperImpl extends SearchLogHelper { } if (!clickLogList.isEmpty()) { try { - final ClickLogBhv clickLogBhv = SingletonS2Container.getComponent(ClickLogBhv.class); + final ClickLogBhv clickLogBhv = SingletonLaContainer.getComponent(ClickLogBhv.class); clickLogBhv.batchInsert(clickLogList); } catch (final Exception e) { logger.warn("Failed to insert: " + clickLogList, e); diff --git a/src/main/java/org/codelibs/fess/helper/impl/TomcatManagementHelperImpl.java b/src/main/java/org/codelibs/fess/helper/impl/TomcatManagementHelperImpl.java deleted file mode 100644 index 407d5df5b..000000000 --- a/src/main/java/org/codelibs/fess/helper/impl/TomcatManagementHelperImpl.java +++ /dev/null @@ -1,284 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.helper.impl; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -import org.apache.http.HttpEntity; -import org.apache.http.HttpResponse; -import org.apache.http.HttpStatus; -import org.apache.http.auth.AuthScope; -import org.apache.http.auth.Credentials; -import org.apache.http.auth.UsernamePasswordCredentials; -import org.apache.http.client.methods.HttpGet; -import org.apache.http.impl.client.DefaultHttpClient; -import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; -import org.codelibs.fess.helper.WebManagementHelper; -import org.seasar.framework.util.InputStreamUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class TomcatManagementHelperImpl implements WebManagementHelper { - private static final Logger logger = LoggerFactory.getLogger(TomcatManagementHelperImpl.class); - - protected Map solrInstanceMap = new LinkedHashMap(); - - public void addSolrInstance(final SolrInstance solrInstance) { - if (!solrInstance.isValid()) { - throw new FessTomcatManagerException("SolrInstance is invalid: " + solrInstance); - } - solrInstanceMap.put(solrInstance.name, solrInstance); - } - - /* (non-Javadoc) - * @see org.codelibs.fess.helper.WebManagementHelper#hasSolrInstance() - */ - @Override - public boolean hasSolrInstance() { - return !solrInstanceMap.isEmpty(); - } - - /* (non-Javadoc) - * @see org.codelibs.fess.helper.WebManagementHelper#getSolrInstanceNameList() - */ - @Override - public List getSolrInstanceNameList() { - final List solrInstanceNameList = new ArrayList(); - solrInstanceNameList.addAll(solrInstanceMap.keySet()); - return solrInstanceNameList; - } - - /* (non-Javadoc) - * @see org.codelibs.fess.helper.WebManagementHelper#getStatus(java.lang.String) - */ - @Override - public String getStatus(final String name) { - final SolrInstance solrInstance = solrInstanceMap.get(name); - if (solrInstance != null) { - try { - return solrInstance.status(); - } catch (final Exception e) { - logger.error("System error on a solr instance (" + name + ").", e); - return "error"; - } - } - return "none"; - } - - /* (non-Javadoc) - * @see org.codelibs.fess.helper.WebManagementHelper#start(java.lang.String) - */ - @Override - public void start(final String name) { - final SolrInstance solrInstance = solrInstanceMap.get(name); - if (solrInstance != null) { - solrInstance.start(); - } else { - throw new FessTomcatManagerException("Solr instance (" + name + ") is not found."); - } - } - - /* (non-Javadoc) - * @see org.codelibs.fess.helper.WebManagementHelper#stop(java.lang.String) - */ - @Override - public void stop(final String name) { - final SolrInstance solrInstance = solrInstanceMap.get(name); - if (solrInstance != null) { - solrInstance.stop(); - } else { - throw new FessTomcatManagerException("Solr instance (" + name + ") is not found."); - } - } - - /* (non-Javadoc) - * @see org.codelibs.fess.helper.WebManagementHelper#reload(java.lang.String) - */ - @Override - public void reload(final String name) { - final SolrInstance solrInstance = solrInstanceMap.get(name); - if (solrInstance != null) { - solrInstance.reload(); - } else { - throw new FessTomcatManagerException("Solr instance (" + name + ") is not found."); - } - } - - public static class SolrInstance { - public String name; - - public String contextPath; - - public String managerUrl; - - public String schema; - - public String username; - - public String password; - - public void start() { - final StringBuilder buf = new StringBuilder(); - buf.append(managerUrl); - if (!managerUrl.endsWith("/")) { - buf.append('/'); - } - buf.append("start?path="); - buf.append(contextPath); - final String responseBody = getResponseBody(buf.toString()); - if (!responseBody.trim().startsWith("OK")) { - throw new FessTomcatManagerException("Failed to start a solr instance. The reponse is \n" + responseBody); - } - } - - public void stop() { - final StringBuilder buf = new StringBuilder(); - buf.append(managerUrl); - if (!managerUrl.endsWith("/")) { - buf.append('/'); - } - buf.append("stop?path="); - buf.append(contextPath); - final String responseBody = getResponseBody(buf.toString()); - if (!responseBody.trim().startsWith("OK")) { - throw new FessTomcatManagerException("Failed to start a solr instance. The reponse is \n" + responseBody); - } - } - - public void reload() { - final StringBuilder buf = new StringBuilder(); - buf.append(managerUrl); - if (!managerUrl.endsWith("/")) { - buf.append('/'); - } - buf.append("reload?path="); - buf.append(contextPath); - final String responseBody = getResponseBody(buf.toString()); - if (!responseBody.trim().startsWith("OK")) { - throw new FessTomcatManagerException("Failed to start a solr instance. The reponse is \n" + responseBody); - } - } - - public String status() { - final StringBuilder buf = new StringBuilder(); - buf.append(managerUrl); - if (!managerUrl.endsWith("/")) { - buf.append('/'); - } - buf.append("list"); - final String responseBody = getResponseBody(buf.toString()); - if (!responseBody.trim().startsWith("OK")) { - throw new FessTomcatManagerException("Failed to start a solr instance. The reponse is \n" + responseBody); - } - - final String[] lines = responseBody.split("\n"); - for (final String line : lines) { - if (line.trim().startsWith(contextPath)) { - final String[] data = line.split(":"); - if (data.length > 1) { - return data[1]; - } - } - } - return "unknown"; - } - - protected String getResponseBody(final String url) { - // Create an instance of HttpClient. - final DefaultHttpClient client = new DefaultHttpClient(); - - if (username != null && password != null) { - final Credentials defaultcreds = new UsernamePasswordCredentials(username, password); - if (schema == null) { - schema = Constants.BASIC; - } - client.getCredentialsProvider().setCredentials(new AuthScope(AuthScope.ANY_HOST, -1, AuthScope.ANY_REALM, schema), - defaultcreds); - } - - // Create a method instance. - final HttpGet httpGet = new HttpGet(url); - - try { - // Execute the method. - final HttpResponse response = client.execute(httpGet); - final int statusCode = response.getStatusLine().getStatusCode(); - - if (statusCode != HttpStatus.SC_OK) { - throw new FessTomcatManagerException("Could not access " + url + ". HTTP Status is " + statusCode + "."); - } - - final HttpEntity entity = response.getEntity(); - if (entity != null) { - // Read the response body. - final String value = new String(InputStreamUtil.getBytes(entity.getContent()), Constants.UTF_8); - // Release the connection. - entity.consumeContent(); - return value; - } - throw new FessTomcatManagerException("No response from " + url); - } catch (final IOException e) { - throw new FessTomcatManagerException("Fatal transport error: " + url, e); - } finally { - client.getConnectionManager().shutdown(); - } - } - - public boolean isValid() { - if (StringUtil.isBlank(name) || StringUtil.isBlank(managerUrl) || StringUtil.isBlank(contextPath)) { - return false; - } - return true; - } - - @Override - public String toString() { - final StringBuilder buf = new StringBuilder(); - buf.append("name:").append(name).append(", "); - buf.append("managerUrl:").append(managerUrl).append(", "); - buf.append("contextPath:").append(contextPath).append(", "); - buf.append("schema:").append(schema).append(", "); - buf.append("username:").append(username).append(", "); - buf.append("password:").append(password); - return buf.toString(); - } - } - - public static class FessTomcatManagerException extends FessSystemException { - - private static final long serialVersionUID = 1L; - - public FessTomcatManagerException(final String message, final Throwable cause) { - super(message, cause); - } - - public FessTomcatManagerException(final String message) { - super(message); - } - - public FessTomcatManagerException(final Throwable cause) { - super(cause); - } - - } -} diff --git a/src/main/java/org/codelibs/fess/solr/BoostDocumentRule.java b/src/main/java/org/codelibs/fess/indexer/BoostDocumentRule.java similarity index 88% rename from src/main/java/org/codelibs/fess/solr/BoostDocumentRule.java rename to src/main/java/org/codelibs/fess/indexer/BoostDocumentRule.java index 4b3ca792e..576e4bdb8 100644 --- a/src/main/java/org/codelibs/fess/solr/BoostDocumentRule.java +++ b/src/main/java/org/codelibs/fess/indexer/BoostDocumentRule.java @@ -14,14 +14,16 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.solr; +package org.codelibs.fess.indexer; import java.util.Map; -import org.seasar.framework.util.OgnlUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import groovy.lang.Binding; +import groovy.lang.GroovyShell; + public class BoostDocumentRule { private static final Logger logger = LoggerFactory.getLogger(BoostDocumentRule.class); @@ -45,8 +47,7 @@ public class BoostDocumentRule { } try { - final Object exp = OgnlUtil.parseExpression(matchExpression); - final Object value = OgnlUtil.getValue(exp, map); + final Object value = new GroovyShell(new Binding(map)).evaluate(matchExpression); if (value instanceof Boolean) { return ((Boolean) value).booleanValue(); @@ -64,8 +65,7 @@ public class BoostDocumentRule { } try { - final Object exp = OgnlUtil.parseExpression(boostExpression); - final Object value = OgnlUtil.getValue(exp, map); + final Object value = new GroovyShell(new Binding(map)).evaluate(boostExpression); if (value instanceof Integer) { return ((Integer) value).floatValue(); diff --git a/src/main/java/org/codelibs/fess/solr/FessSolrQueryException.java b/src/main/java/org/codelibs/fess/indexer/FessSearchQueryException.java similarity index 68% rename from src/main/java/org/codelibs/fess/solr/FessSolrQueryException.java rename to src/main/java/org/codelibs/fess/indexer/FessSearchQueryException.java index 759db93bb..60d77b1c5 100644 --- a/src/main/java/org/codelibs/fess/solr/FessSolrQueryException.java +++ b/src/main/java/org/codelibs/fess/indexer/FessSearchQueryException.java @@ -14,23 +14,23 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.solr; +package org.codelibs.fess.indexer; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; -public class FessSolrQueryException extends FessSystemException { +public class FessSearchQueryException extends FessSystemException { private static final long serialVersionUID = 1L; - public FessSolrQueryException(String message, Throwable cause) { + public FessSearchQueryException(final String message, final Throwable cause) { super(message, cause); } - public FessSolrQueryException(String message) { + public FessSearchQueryException(final String message) { super(message); } - public FessSolrQueryException(Throwable cause) { + public FessSearchQueryException(final Throwable cause) { super(cause); } diff --git a/src/main/java/org/codelibs/fess/solr/IndexUpdater.java b/src/main/java/org/codelibs/fess/indexer/IndexUpdater.java similarity index 81% rename from src/main/java/org/codelibs/fess/solr/IndexUpdater.java rename to src/main/java/org/codelibs/fess/indexer/IndexUpdater.java index 4959fcedf..c512415b6 100644 --- a/src/main/java/org/codelibs/fess/solr/IndexUpdater.java +++ b/src/main/java/org/codelibs/fess/indexer/IndexUpdater.java @@ -14,21 +14,22 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.solr; +package org.codelibs.fess.indexer; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.function.Consumer; import javax.annotation.Resource; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; -import org.codelibs.fess.client.FessEsClient; +import org.codelibs.fess.es.client.FessEsClient; import org.codelibs.fess.es.exbhv.ClickLogBhv; import org.codelibs.fess.es.exbhv.FavoriteLogBhv; +import org.codelibs.fess.exception.FessSystemException; import org.codelibs.fess.helper.FieldHelper; import org.codelibs.fess.helper.IndexingHelper; import org.codelibs.fess.helper.IntervalControlHelper; @@ -36,19 +37,22 @@ import org.codelibs.fess.helper.SearchLogHelper; import org.codelibs.fess.helper.SystemHelper; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.robot.S2Robot; -import org.codelibs.robot.db.cbean.AccessResultCB; -import org.codelibs.robot.db.exbhv.AccessResultBhv; -import org.codelibs.robot.db.exbhv.AccessResultDataBhv; -import org.codelibs.robot.db.exentity.AccessResult; -import org.codelibs.robot.dbflute.cbean.PagingResultBean; +import org.codelibs.robot.entity.AccessResult; import org.codelibs.robot.entity.AccessResultData; +import org.codelibs.robot.entity.EsAccessResult; +import org.codelibs.robot.entity.EsUrlQueue; import org.codelibs.robot.service.DataService; import org.codelibs.robot.service.UrlFilterService; import org.codelibs.robot.service.UrlQueueService; +import org.codelibs.robot.service.impl.EsDataService; import org.codelibs.robot.transformer.Transformer; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.framework.container.annotation.tiger.Binding; -import org.seasar.framework.container.annotation.tiger.BindingType; +import org.codelibs.robot.util.EsResultList; +import org.elasticsearch.action.search.SearchRequestBuilder; +import org.elasticsearch.index.query.FilterBuilders; +import org.elasticsearch.index.query.QueryBuilder; +import org.elasticsearch.index.query.QueryBuilders; +import org.elasticsearch.search.sort.SortOrder; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -57,23 +61,18 @@ public class IndexUpdater extends Thread { protected List sessionIdList; + @Resource protected FessEsClient fessEsClient; @Resource - protected DataService dataService; + protected DataService dataService; @Resource - protected UrlQueueService urlQueueService; + protected UrlQueueService urlQueueService; @Resource protected UrlFilterService urlFilterService; - @Resource - protected AccessResultBhv accessResultBhv; - - @Resource - protected AccessResultDataBhv accessResultDataBhv; - @Resource protected ClickLogBhv clickLogBhv; @@ -101,7 +100,7 @@ public class IndexUpdater extends Thread { protected long documentSize; - protected int maxSolrErrorCount = 0; + protected int maxIndexerErrorCount = 0; protected int maxErrorCount = 2; @@ -168,21 +167,27 @@ public class IndexUpdater extends Thread { final IntervalControlHelper intervalControlHelper = ComponentUtil.getIntervalControlHelper(); try { - final AccessResultCB cb = new AccessResultCB(); - cb.setupSelect_AccessResultDataAsOne(); - cb.query().setSessionId_InScope(sessionIdList); - cb.query().addOrderBy_CreateTime_Asc(); - cb.query().setStatus_Equal(org.codelibs.robot.Constants.OK_STATUS); - if (maxDocumentCacheSize <= 0) { - maxDocumentCacheSize = 1; - } - cb.fetchFirst(maxDocumentCacheSize); - cb.fetchPage(1); + final Consumer cb = + builder -> { + final QueryBuilder queryBuilder = + QueryBuilders.filteredQuery( + QueryBuilders.matchAllQuery(), + FilterBuilders + .boolFilter() + .must(FilterBuilders.termsFilter(EsAccessResult.SESSION_ID, sessionIdList)) + .must(FilterBuilders.termFilter(EsAccessResult.STATUS, + org.codelibs.robot.Constants.OK_STATUS))); + builder.setQuery(queryBuilder); + builder.setFrom(0); + if (maxDocumentCacheSize <= 0) { + maxDocumentCacheSize = 1; + } + builder.setSize(maxDocumentCacheSize); + builder.addSort(EsAccessResult.CREATE_TIME, SortOrder.ASC); + }; final List> docList = new ArrayList<>(); - final List accessResultList = new ArrayList(); - final List accessResultDataList = - new ArrayList(); + final List accessResultList = new ArrayList<>(); long updateTime = System.currentTimeMillis(); int errorCount = 0; @@ -206,7 +211,6 @@ public class IndexUpdater extends Thread { docList.clear(); accessResultList.clear(); - accessResultDataList.clear(); intervalControlHelper.delayByRules(); @@ -216,16 +220,16 @@ public class IndexUpdater extends Thread { updateTime = System.currentTimeMillis(); - PagingResultBean arList = getAccessResultList(cb); + List arList = getAccessResultList(cb); if (arList.isEmpty()) { emptyListCount++; } else { emptyListCount = 0; // reset } while (!arList.isEmpty()) { - processAccessResults(docList, accessResultList, accessResultDataList, arList); + processAccessResults(docList, accessResultList, arList); - cleanupAccessResults(accessResultList, accessResultDataList); + cleanupAccessResults(accessResultList); if (logger.isDebugEnabled()) { logger.debug("Getting documents in IndexUpdater queue."); @@ -305,10 +309,9 @@ public class IndexUpdater extends Thread { } } - private void processAccessResults(final List> docList, - final List accessResultList, - final List accessResultDataList, final PagingResultBean arList) { - for (final AccessResult accessResult : arList) { + private void processAccessResults(final List> docList, final List accessResultList, + final List arList) { + for (final EsAccessResult accessResult : arList) { if (logger.isDebugEnabled()) { logger.debug("Indexing " + accessResult.getUrl()); } @@ -325,10 +328,9 @@ public class IndexUpdater extends Thread { final AccessResultData accessResultData = accessResult.getAccessResultData(); if (accessResultData != null) { - accessResult.setAccessResultData(null); - accessResultDataList.add((org.codelibs.robot.db.exentity.AccessResultData) accessResultData); + accessResult.setAccessResultData((AccessResultData) null); try { - final Transformer transformer = SingletonS2Container.getComponent(accessResultData.getTransformerName()); + final Transformer transformer = SingletonLaContainer.getComponent(accessResultData.getTransformerName()); if (transformer == null) { // no transformer logger.warn("No transformer: " + accessResultData.getTransformerName()); @@ -443,8 +445,7 @@ public class IndexUpdater extends Thread { } } - private void cleanupAccessResults(final List accessResultList, - final List accessResultDataList) { + private void cleanupAccessResults(final List accessResultList) { if (!accessResultList.isEmpty()) { final long execTime = System.currentTimeMillis(); final int size = accessResultList.size(); @@ -456,37 +457,26 @@ public class IndexUpdater extends Thread { } } - if (!accessResultDataList.isEmpty()) { - final long execTime = System.currentTimeMillis(); - final int size = accessResultDataList.size(); - // clean up content - accessResultDataBhv.batchDelete(accessResultDataList); - accessResultDataList.clear(); - if (logger.isDebugEnabled()) { - logger.debug("Deleted " + size + " access result data. The execution time is " + (System.currentTimeMillis() - execTime) - + "ms."); - } - } } - private PagingResultBean getAccessResultList(final AccessResultCB cb) { + private List getAccessResultList(final Consumer cb) { final long execTime = System.currentTimeMillis(); - final PagingResultBean arList = accessResultBhv.selectPage(cb); + final List arList = ((EsDataService) dataService).getAccessResultList(cb); if (!arList.isEmpty()) { for (final AccessResult ar : arList.toArray(new AccessResult[arList.size()])) { - if (ar.getCreateTime().getTime() > execTime - commitMarginTime) { + if (ar.getCreateTime().longValue() > execTime - commitMarginTime) { arList.remove(ar); } } } + final long totalHits = ((EsResultList) arList).getTotalHits(); if (logger.isInfoEnabled()) { - logger.info("Processing " + arList.size() + "/" + arList.getAllRecordCount() + " docs (DB: " - + (System.currentTimeMillis() - execTime) + "ms)"); + logger.info("Processing " + arList.size() + "/" + totalHits + " docs (DB: " + (System.currentTimeMillis() - execTime) + "ms)"); } - if (arList.getAllRecordCount() > unprocessedDocumentSize) { + if (totalHits > unprocessedDocumentSize) { if (logger.isInfoEnabled()) { - logger.info("Stopped all crawler threads. " + " You have " + arList.getAllRecordCount() + " (>" + unprocessedDocumentSize - + ") " + " unprocessed docs."); + logger.info("Stopped all crawler threads. " + " You have " + totalHits + " (>" + unprocessedDocumentSize + ") " + + " unprocessed docs."); } final IntervalControlHelper intervalControlHelper = ComponentUtil.getIntervalControlHelper(); intervalControlHelper.setCrawlerRunning(false); @@ -542,19 +532,17 @@ public class IndexUpdater extends Thread { return documentSize; } - @Binding(bindingType = BindingType.MAY) @Override public void setUncaughtExceptionHandler(final UncaughtExceptionHandler eh) { super.setUncaughtExceptionHandler(eh); } - @Binding(bindingType = BindingType.MAY) public static void setDefaultUncaughtExceptionHandler(final UncaughtExceptionHandler eh) { Thread.setDefaultUncaughtExceptionHandler(eh); } - public void setMaxSolrErrorCount(final int maxSolrErrorCount) { - this.maxSolrErrorCount = maxSolrErrorCount; + public void setMaxIndexerErrorCount(final int maxIndexerErrorCount) { + this.maxIndexerErrorCount = maxIndexerErrorCount; } public void setUnprocessedDocumentSize(final int unprocessedDocumentSize) { diff --git a/src/main/java/org/codelibs/fess/interceptor/FessActionMessagesThrowsInterceptor.java b/src/main/java/org/codelibs/fess/interceptor/FessActionMessagesThrowsInterceptor.java deleted file mode 100644 index 02951eb32..000000000 --- a/src/main/java/org/codelibs/fess/interceptor/FessActionMessagesThrowsInterceptor.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.interceptor; - -import org.aopalliance.intercept.MethodInvocation; -import org.codelibs.fess.UnsupportedSearchException; -import org.seasar.struts.interceptor.ActionMessagesThrowsInterceptor; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class FessActionMessagesThrowsInterceptor extends ActionMessagesThrowsInterceptor { - private static final long serialVersionUID = 1L; - - private static final String SYSTEM_ERROR_JSP = "/error/system.jsp"; - - private static final Logger logger = LoggerFactory.getLogger(FessActionMessagesThrowsInterceptor.class); - - @Override - public Object invoke(final MethodInvocation invocation) throws Throwable { - try { - return super.invoke(invocation); - } catch (final Throwable t) { // NOPMD - printLog(t); - return SYSTEM_ERROR_JSP; - } - } - - private void printLog(final Throwable t) { - if (t.getClass().getName().endsWith("ClientAbortException")) { - // ignore - if (logger.isDebugEnabled()) { - logger.debug(t.getMessage()); - } - } else if (t instanceof UnsupportedSearchException) { - logger.warn(t.getMessage()); - } else { - logger.error("System error occured.", t); - } - } -} diff --git a/src/main/java/org/codelibs/fess/job/CrawlJob.java b/src/main/java/org/codelibs/fess/job/CrawlJob.java index 539562714..7f37e2cb0 100644 --- a/src/main/java/org/codelibs/fess/job/CrawlJob.java +++ b/src/main/java/org/codelibs/fess/job/CrawlJob.java @@ -25,18 +25,18 @@ import java.util.List; import javax.servlet.ServletContext; -import org.apache.commons.lang.StringUtils; -import org.apache.commons.lang.SystemUtils; +import org.apache.commons.lang3.StringUtils; +import org.apache.commons.lang3.SystemUtils; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; import org.codelibs.fess.exec.Crawler; import org.codelibs.fess.helper.JobHelper; import org.codelibs.fess.helper.SystemHelper; import org.codelibs.fess.util.ComponentUtil; import org.codelibs.fess.util.InputStreamThread; import org.codelibs.fess.util.JobProcess; -import org.seasar.framework.container.SingletonS2Container; +import org.lastaflute.di.core.SingletonLaContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -65,6 +65,8 @@ public class CrawlJob { protected long retryIntervalToDeleteTempDir = 5000; + protected boolean useLocaleElasticsearch = true; + public CrawlJob jobExecutor(final JobExecutor jobExecutor) { this.jobExecutor = jobExecutor; return this; @@ -110,9 +112,15 @@ public class CrawlJob { return this; } - public void retryToDeleteTempDir(final int retryCount, final long retryInterval) { + public CrawlJob retryToDeleteTempDir(final int retryCount, final long retryInterval) { retryCountToDeleteTempDir = retryCount; retryIntervalToDeleteTempDir = retryInterval; + return this; + } + + public CrawlJob useLocaleElasticsearch(final boolean useLocaleElasticsearch) { + this.useLocaleElasticsearch = useLocaleElasticsearch; + return this; } public String execute(final JobExecutor jobExecutor) { @@ -211,7 +219,7 @@ public class CrawlJob { protected void executeCrawler() { final List crawlerCmdList = new ArrayList(); final String cpSeparator = SystemUtils.IS_OS_WINDOWS ? ";" : ":"; - final ServletContext servletContext = SingletonS2Container.getComponent(ServletContext.class); + final ServletContext servletContext = SingletonLaContainer.getComponent(ServletContext.class); final SystemHelper systemHelper = ComponentUtil.getSystemHelper(); final JobHelper jobHelper = ComponentUtil.getJobHelper(); @@ -233,7 +241,8 @@ public class CrawlJob { buf.append("classes"); // target/classes final String userDir = System.getProperty("user.dir"); - final File targetClassesDir = new File(userDir, "target" + File.separator + "classes"); + final File targetDir = new File(userDir, "target"); + final File targetClassesDir = new File(targetDir, "classes"); if (targetClassesDir.isDirectory()) { buf.append(cpSeparator); buf.append(targetClassesDir.getAbsolutePath()); @@ -243,23 +252,32 @@ public class CrawlJob { // WEB-INF/cmd/lib appendJarFile(cpSeparator, buf, new File(servletContext.getRealPath("/WEB-INF/cmd/lib")), "WEB-INF/cmd" + File.separator + "lib" + File.separator); - final File targetLibDir = - new File(userDir, "target" + File.separator + "fess" + File.separator + "WEB-INF" + File.separator + "lib"); + final File targetLibDir = new File(targetDir, "fess" + File.separator + "WEB-INF" + File.separator + "lib"); if (targetLibDir.isDirectory()) { appendJarFile(cpSeparator, buf, targetLibDir, targetLibDir.getAbsolutePath() + File.separator); } crawlerCmdList.add(buf.toString()); - final String transportAddresses = System.getProperty(Constants.FESS_ES_TRANSPORT_ADDRESSES); - if (StringUtil.isNotBlank(transportAddresses)) { - crawlerCmdList.add("-D" + Constants.FESS_ES_TRANSPORT_ADDRESSES + "=" + transportAddresses); + if (useLocaleElasticsearch) { + final String transportAddresses = System.getProperty(Constants.FESS_ES_TRANSPORT_ADDRESSES); + if (StringUtil.isNotBlank(transportAddresses)) { + crawlerCmdList.add("-D" + Constants.FESS_ES_TRANSPORT_ADDRESSES + "=" + transportAddresses); + } + final String clusterName = System.getProperty(Constants.FESS_ES_CLUSTER_NAME); + if (StringUtil.isNotBlank(clusterName)) { + crawlerCmdList.add("-D" + Constants.FESS_ES_CLUSTER_NAME + "=" + clusterName); + } } crawlerCmdList.add("-Dfess.crawler.process=true"); if (logFilePath == null) { - logFilePath = systemHelper.getLogFilePath(); + final String value = System.getProperty("fess.log.path"); + logFilePath = value != null ? value : new File(targetDir, "logs").getAbsolutePath(); } - crawlerCmdList.add("-Dfess.log.file=" + logFilePath); + crawlerCmdList.add("-Dfess.log.path=" + logFilePath); + addSystemProperty(crawlerCmdList, "lasta.env", null, null); + addSystemProperty(crawlerCmdList, "fess.log.name", "fess-crawler", "-crawler"); + addSystemProperty(crawlerCmdList, "fess.log.level", null, null); if (systemHelper.getCrawlerJavaOptions() != null) { for (final String value : systemHelper.getCrawlerJavaOptions()) { crawlerCmdList.add(value); @@ -350,6 +368,20 @@ public class CrawlJob { } } + private void addSystemProperty(final List crawlerCmdList, final String name, final String defaultValue, final String appendValue) { + final String value = System.getProperty(name); + if (value != null) { + final StringBuilder buf = new StringBuilder(); + buf.append("-D").append(name).append("=").append(value); + if (appendValue != null) { + buf.append(appendValue); + } + crawlerCmdList.add(buf.toString()); + } else if (defaultValue != null) { + crawlerCmdList.add("-D" + name + "=" + defaultValue); + } + } + protected void deleteTempDir(final File ownTmpDir) { if (ownTmpDir == null) { return; diff --git a/src/main/java/org/codelibs/fess/job/JobScheduler.java b/src/main/java/org/codelibs/fess/job/JobScheduler.java index 8a980097a..bd76c4605 100644 --- a/src/main/java/org/codelibs/fess/job/JobScheduler.java +++ b/src/main/java/org/codelibs/fess/job/JobScheduler.java @@ -24,6 +24,9 @@ import static org.quartz.TriggerBuilder.newTrigger; import java.util.ArrayList; import java.util.List; +import javax.annotation.PostConstruct; +import javax.annotation.PreDestroy; + import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; import org.codelibs.fess.es.exbhv.ScheduledJobBhv; @@ -38,8 +41,6 @@ import org.quartz.SchedulerException; import org.quartz.SchedulerFactory; import org.quartz.Trigger; import org.quartz.impl.StdSchedulerFactory; -import org.seasar.framework.container.annotation.tiger.DestroyMethod; -import org.seasar.framework.container.annotation.tiger.InitMethod; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -54,7 +55,7 @@ public class JobScheduler { public List targetList = new ArrayList(); - @InitMethod + @PostConstruct public void init() { final SchedulerFactory sf = new StdSchedulerFactory(); try { @@ -71,7 +72,7 @@ public class JobScheduler { }, scheduledJob -> register(scheduledJob)); } - @DestroyMethod + @PreDestroy public void destroy() { final JobHelper jobHelper = ComponentUtil.getJobHelper(); for (final String sessionId : jobHelper.getRunningSessionIdSet()) { diff --git a/src/main/java/org/codelibs/fess/job/ScheduledJobException.java b/src/main/java/org/codelibs/fess/job/ScheduledJobException.java index cd49ea6f1..048038fd8 100644 --- a/src/main/java/org/codelibs/fess/job/ScheduledJobException.java +++ b/src/main/java/org/codelibs/fess/job/ScheduledJobException.java @@ -16,7 +16,7 @@ package org.codelibs.fess.job; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; public class ScheduledJobException extends FessSystemException { diff --git a/src/main/java/org/codelibs/fess/job/TriggeredJob.java b/src/main/java/org/codelibs/fess/job/TriggeredJob.java index 7b616fb5b..14f0519ea 100644 --- a/src/main/java/org/codelibs/fess/job/TriggeredJob.java +++ b/src/main/java/org/codelibs/fess/job/TriggeredJob.java @@ -17,17 +17,17 @@ package org.codelibs.fess.job; import org.codelibs.fess.Constants; +import org.codelibs.fess.app.service.JobLogService; import org.codelibs.fess.es.exentity.JobLog; import org.codelibs.fess.es.exentity.ScheduledJob; import org.codelibs.fess.helper.JobHelper; import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.service.JobLogService; import org.codelibs.fess.util.ComponentUtil; +import org.lastaflute.di.core.SingletonLaContainer; import org.quartz.Job; import org.quartz.JobDataMap; import org.quartz.JobExecutionContext; import org.quartz.JobExecutionException; -import org.seasar.framework.container.SingletonS2Container; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -102,7 +102,7 @@ public class TriggeredJob implements Job { } private void storeJobLog(final JobLog jobLog) { - final JobLogService jobLogService = SingletonS2Container.getComponent(JobLogService.class); + final JobLogService jobLogService = SingletonLaContainer.getComponent(JobLogService.class); jobLogService.store(jobLog); } diff --git a/src/main/java/org/codelibs/fess/job/impl/GroovyExecutor.java b/src/main/java/org/codelibs/fess/job/impl/GroovyExecutor.java index b3d412fa7..83de7c712 100644 --- a/src/main/java/org/codelibs/fess/job/impl/GroovyExecutor.java +++ b/src/main/java/org/codelibs/fess/job/impl/GroovyExecutor.java @@ -17,7 +17,7 @@ package org.codelibs.fess.job.impl; import org.codelibs.fess.job.JobExecutor; -import org.seasar.framework.container.factory.SingletonS2ContainerFactory; +import org.lastaflute.di.core.factory.SingletonLaContainerFactory; import groovy.lang.Binding; import groovy.lang.GroovyShell; @@ -27,7 +27,7 @@ public class GroovyExecutor extends JobExecutor { @Override public Object execute(final String script) { final Binding binding = new Binding(); - binding.setVariable("container", SingletonS2ContainerFactory.getContainer()); + binding.setVariable("container", SingletonLaContainerFactory.getContainer()); binding.setVariable("executor", this); final GroovyShell shell = new GroovyShell(binding); diff --git a/src/main/java/org/codelibs/fess/lasta/core/direction/FessConfig.java b/src/main/java/org/codelibs/fess/lasta/core/direction/FessConfig.java deleted file mode 100644 index 739175190..000000000 --- a/src/main/java/org/codelibs/fess/lasta/core/direction/FessConfig.java +++ /dev/null @@ -1,146 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.lasta.core.direction; - -/** - * @author FreeGen - */ -public interface FessConfig extends FessEnv { - - /** The key of the configuration. e.g. Fess */ - String DOMAIN_TITLE = "domain.title"; - - /** The key of the configuration. e.g. / */ - String COOKIE_DEFAULT_PATH = "cookie.default.path"; - - /** The key of the configuration. e.g. 31556926 */ - String COOKIE_DEFAULT_EXPIRE = "cookie.default.expire"; - - /** The key of the configuration. e.g. 315360000 */ - String COOKIE_ETERNAL_EXPIRE = "cookie.eternal.expire"; - - /** - * Get the value of property as {@link String}. - * @param propertyKey The key of the property. (NotNull) - * @return The value of found property. (NullAllowed: if null, not found) - */ - @Override - String get(String propertyKey); - - /** - * Is the property true? - * @param propertyKey The key of the property which is boolean type. (NotNull) - * @return The determination, true or false. (if the property can be true, returns true) - */ - @Override - boolean is(String propertyKey); - - /** - * Get the value for the key 'domain.title'.
    - * The value is, e.g. Fess
    - * comment: The title of domain the application for logging - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getDomainTitle(); - - /** - * Get the value for the key 'cookie.default.path'.
    - * The value is, e.g. /
    - * comment: The default path of cookie (basically '/' if no context path) - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getCookieDefaultPath(); - - /** - * Get the value for the key 'cookie.default.expire'.
    - * The value is, e.g. 31556926
    - * comment: The default expire of cookie in seconds e.g. 31556926: one year, 86400: one day - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getCookieDefaultExpire(); - - /** - * Get the value for the key 'cookie.default.expire' as {@link Integer}.
    - * The value is, e.g. 31556926
    - * comment: The default expire of cookie in seconds e.g. 31556926: one year, 86400: one day - * @return The value of found property. (NullAllowed: if null, not found) - * @throws NumberFormatException When the property is not integer. - */ - Integer getCookieDefaultExpireAsInteger(); - - /** - * Get the value for the key 'cookie.eternal.expire'.
    - * The value is, e.g. 315360000
    - * comment: The eternal expire of cookie in seconds e.g. 315360000: ten year, 86400: one day - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getCookieEternalExpire(); - - /** - * Get the value for the key 'cookie.eternal.expire' as {@link Integer}.
    - * The value is, e.g. 315360000
    - * comment: The eternal expire of cookie in seconds e.g. 315360000: ten year, 86400: one day - * @return The value of found property. (NullAllowed: if null, not found) - * @throws NumberFormatException When the property is not integer. - */ - Integer getCookieEternalExpireAsInteger(); - - /** - * The simple implementation for configuration. - * @author FreeGen - */ - public static class SimpleImpl extends FessEnv.SimpleImpl implements FessConfig { - - /** The serial version UID for object serialization. (Default) */ - private static final long serialVersionUID = 1L; - - /** {@inheritDoc} */ - @Override - public String getDomainTitle() { - return get(FessConfig.DOMAIN_TITLE); - } - - /** {@inheritDoc} */ - @Override - public String getCookieDefaultPath() { - return get(FessConfig.COOKIE_DEFAULT_PATH); - } - - /** {@inheritDoc} */ - @Override - public String getCookieDefaultExpire() { - return get(FessConfig.COOKIE_DEFAULT_EXPIRE); - } - - /** {@inheritDoc} */ - @Override - public Integer getCookieDefaultExpireAsInteger() { - return getAsInteger(FessConfig.COOKIE_DEFAULT_EXPIRE); - } - - /** {@inheritDoc} */ - @Override - public String getCookieEternalExpire() { - return get(FessConfig.COOKIE_ETERNAL_EXPIRE); - } - - /** {@inheritDoc} */ - @Override - public Integer getCookieEternalExpireAsInteger() { - return getAsInteger(FessConfig.COOKIE_ETERNAL_EXPIRE); - } - } -} diff --git a/src/main/java/org/codelibs/fess/lasta/core/direction/FessEnv.java b/src/main/java/org/codelibs/fess/lasta/core/direction/FessEnv.java deleted file mode 100644 index 093e69f3d..000000000 --- a/src/main/java/org/codelibs/fess/lasta/core/direction/FessEnv.java +++ /dev/null @@ -1,290 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.lasta.core.direction; - -import org.dbflute.saflute.core.direction.ObjectiveConfig; - -/** - * @author FreeGen - */ -public interface FessEnv { - - /** The key of the configuration. e.g. true */ - String DEVELOPMENT_HERE = "development.here"; - - /** The key of the configuration. e.g. Local Development */ - String ENVIRONMENT_TITLE = "environment.title"; - - /** The key of the configuration. e.g. false */ - String FRAMEWORK_DEBUG = "framework.debug"; - - /** The key of the configuration. e.g. 0 */ - String TIME_ADJUST_TIME_MILLIS = "time.adjust.time.millis"; - - /** The key of the configuration. e.g. true */ - String MAIL_SEND_MOCK = "mail.send.mock"; - - /** The key of the configuration. e.g. localhost:25 */ - String MAIL_SMTP_SERVER_DEFAULT_HOST_AND_PORT = "mail.smtp.server.default.host.and.port"; - - /** The key of the configuration. e.g. jdbc:mysql://localhost:3306/maihamadb */ - String JDBC_URL = "jdbc.url"; - - /** The key of the configuration. e.g. maihamauser */ - String JDBC_USER = "jdbc.user"; - - /** The key of the configuration. e.g. maihamaword */ - String JDBC_PASSWORD = "jdbc.password"; - - /** The key of the configuration. e.g. 10 */ - String JDBC_CONNECTION_POOLING_SIZE = "jdbc.connection.pooling.size"; - - /** - * Get the value of property as {@link String}. - * @param propertyKey The key of the property. (NotNull) - * @return The value of found property. (NullAllowed: if null, not found) - */ - String get(String propertyKey); - - /** - * Is the property true? - * @param propertyKey The key of the property which is boolean type. (NotNull) - * @return The determination, true or false. (if the property can be true, returns true) - */ - boolean is(String propertyKey); - - /** - * Get the value for the key 'development.here'.
    - * The value is, e.g. true
    - * comment: Is development environment here? (used for various purpose, you should set false if unknown) - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getDevelopmentHere(); - - /** - * Is the property for the key 'development.here' true?
    - * The value is, e.g. true
    - * comment: Is development environment here? (used for various purpose, you should set false if unknown) - * @return The determination, true or false. (if the property can be true, returns true) - */ - boolean isDevelopmentHere(); - - /** - * Get the value for the key 'environment.title'.
    - * The value is, e.g. Local Development
    - * comment: The title of environment (e.g. local or integartion or production) - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getEnvironmentTitle(); - - /** - * Get the value for the key 'framework.debug'.
    - * The value is, e.g. false
    - * comment: Does it enable the Framework internal debug? (true only when emergency) - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getFrameworkDebug(); - - /** - * Is the property for the key 'framework.debug' true?
    - * The value is, e.g. false
    - * comment: Does it enable the Framework internal debug? (true only when emergency) - * @return The determination, true or false. (if the property can be true, returns true) - */ - boolean isFrameworkDebug(); - - /** - * Get the value for the key 'time.adjust.time.millis'.
    - * The value is, e.g. 0
    - * comment: The milliseconds for (relative or absolute) adjust time (set only when test) @LongType *dynamic in development - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getTimeAdjustTimeMillis(); - - /** - * Get the value for the key 'time.adjust.time.millis' as {@link Long}.
    - * The value is, e.g. 0
    - * comment: The milliseconds for (relative or absolute) adjust time (set only when test) @LongType *dynamic in development - * @return The value of found property. (NullAllowed: if null, not found) - * @throws NumberFormatException When the property is not long. - */ - Long getTimeAdjustTimeMillisAsLong(); - - /** - * Get the value for the key 'mail.send.mock'.
    - * The value is, e.g. true
    - * comment: Does it send mock mail? (true: no send actually, logging only) - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getMailSendMock(); - - /** - * Is the property for the key 'mail.send.mock' true?
    - * The value is, e.g. true
    - * comment: Does it send mock mail? (true: no send actually, logging only) - * @return The determination, true or false. (if the property can be true, returns true) - */ - boolean isMailSendMock(); - - /** - * Get the value for the key 'mail.smtp.server.default.host.and.port'.
    - * The value is, e.g. localhost:25
    - * comment: SMTP server settings for default: host:port - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getMailSmtpServerDefaultHostAndPort(); - - /** - * Get the value for the key 'jdbc.url'.
    - * The value is, e.g. jdbc:mysql://localhost:3306/maihamadb
    - * comment: The URL of database connection for JDBC - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getJdbcUrl(); - - /** - * Get the value for the key 'jdbc.user'.
    - * The value is, e.g. maihamauser
    - * comment: The user of database connection for JDBC - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getJdbcUser(); - - /** - * Get the value for the key 'jdbc.password'.
    - * The value is, e.g. maihamaword
    - * comment: @Secure The password of database connection for JDBC - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getJdbcPassword(); - - /** - * Get the value for the key 'jdbc.connection.pooling.size'.
    - * The value is, e.g. 10
    - * comment: The (max) pooling size of Seasar's connection pool - * @return The value of found property. (NullAllowed: if null, not found) - */ - String getJdbcConnectionPoolingSize(); - - /** - * Get the value for the key 'jdbc.connection.pooling.size' as {@link Integer}.
    - * The value is, e.g. 10
    - * comment: The (max) pooling size of Seasar's connection pool - * @return The value of found property. (NullAllowed: if null, not found) - * @throws NumberFormatException When the property is not integer. - */ - Integer getJdbcConnectionPoolingSizeAsInteger(); - - /** - * The simple implementation for configuration. - * @author FreeGen - */ - public static class SimpleImpl extends ObjectiveConfig implements FessEnv { - - /** The serial version UID for object serialization. (Default) */ - private static final long serialVersionUID = 1L; - - /** {@inheritDoc} */ - @Override - public String getDevelopmentHere() { - return get(FessEnv.DEVELOPMENT_HERE); - } - - /** {@inheritDoc} */ - @Override - public boolean isDevelopmentHere() { - return is(FessEnv.DEVELOPMENT_HERE); - } - - /** {@inheritDoc} */ - @Override - public String getEnvironmentTitle() { - return get(FessEnv.ENVIRONMENT_TITLE); - } - - /** {@inheritDoc} */ - @Override - public String getFrameworkDebug() { - return get(FessEnv.FRAMEWORK_DEBUG); - } - - /** {@inheritDoc} */ - @Override - public boolean isFrameworkDebug() { - return is(FessEnv.FRAMEWORK_DEBUG); - } - - /** {@inheritDoc} */ - @Override - public String getTimeAdjustTimeMillis() { - return get(FessEnv.TIME_ADJUST_TIME_MILLIS); - } - - /** {@inheritDoc} */ - @Override - public Long getTimeAdjustTimeMillisAsLong() { - return getAsLong(FessEnv.TIME_ADJUST_TIME_MILLIS); - } - - /** {@inheritDoc} */ - @Override - public String getMailSendMock() { - return get(FessEnv.MAIL_SEND_MOCK); - } - - /** {@inheritDoc} */ - @Override - public boolean isMailSendMock() { - return is(FessEnv.MAIL_SEND_MOCK); - } - - /** {@inheritDoc} */ - @Override - public String getMailSmtpServerDefaultHostAndPort() { - return get(FessEnv.MAIL_SMTP_SERVER_DEFAULT_HOST_AND_PORT); - } - - /** {@inheritDoc} */ - @Override - public String getJdbcUrl() { - return get(FessEnv.JDBC_URL); - } - - /** {@inheritDoc} */ - @Override - public String getJdbcUser() { - return get(FessEnv.JDBC_USER); - } - - /** {@inheritDoc} */ - @Override - public String getJdbcPassword() { - return get(FessEnv.JDBC_PASSWORD); - } - - /** {@inheritDoc} */ - @Override - public String getJdbcConnectionPoolingSize() { - return get(FessEnv.JDBC_CONNECTION_POOLING_SIZE); - } - - /** {@inheritDoc} */ - @Override - public Integer getJdbcConnectionPoolingSizeAsInteger() { - return getAsInteger(FessEnv.JDBC_CONNECTION_POOLING_SIZE); - } - } -} diff --git a/src/main/java/org/codelibs/fess/lasta/core/direction/FessFwAssistantDirector.java b/src/main/java/org/codelibs/fess/lasta/core/direction/FessFwAssistantDirector.java deleted file mode 100644 index 4554bb3bd..000000000 --- a/src/main/java/org/codelibs/fess/lasta/core/direction/FessFwAssistantDirector.java +++ /dev/null @@ -1,259 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.lasta.core.direction; - -import java.util.TimeZone; - -import javax.annotation.Resource; - -import org.codelibs.fess.lasta.core.direction.sponsor.FessActionAdjustmentProvider; -import org.codelibs.fess.lasta.core.direction.sponsor.FessTimeResourceProvider; -import org.codelibs.fess.lasta.core.direction.sponsor.FessUserLocaleProcessProvider; -import org.codelibs.fess.lasta.core.direction.sponsor.FessUserTimeZoneProcessProvider; -import org.dbflute.saflute.core.direction.CachedFwAssistantDirector; -import org.dbflute.saflute.core.direction.OptionalAssistDirection; -import org.dbflute.saflute.core.direction.OptionalCoreDirection; -import org.dbflute.saflute.core.security.InvertibleCipher; -import org.dbflute.saflute.db.dbflute.OptionalDBFluteDirection; -import org.dbflute.saflute.web.action.OptionalActionDirection; -import org.dbflute.saflute.web.servlet.OptionalServletDirection; -import org.dbflute.saflute.web.servlet.cookie.CookieResourceProvider; -import org.dbflute.saflute.web.task.OptionalTaskDirection; -import org.dbflute.system.DBFluteSystem; -import org.dbflute.system.provider.DfFinalTimeZoneProvider; -import org.dbflute.util.DfTypeUtil; - -/** - * @author jflute - */ -public class FessFwAssistantDirector extends CachedFwAssistantDirector { - - // =================================================================================== - // Definition - // ========== - public static final String FESS_CONFIG_FILE = "fess_config.properties"; - - public static final String FESS_ENV_FILE = "fess_env.properties"; - - // =================================================================================== - // Attribute - // ========= - @Resource - protected FessConfig fessConfig; - - // =================================================================================== - // Assist - // ====== - @Override - protected OptionalAssistDirection prepareOptionalAssistDirection() { - final OptionalAssistDirection direction = new OptionalAssistDirection(); - prepareConfiguration(direction); - return direction; - } - - protected void prepareConfiguration(OptionalAssistDirection direction) { - direction.directConfiguration(getDomainConfigFile(), getExtendsConfigFiles()); - } - - protected String getDomainConfigFile() { - return FESS_CONFIG_FILE; - } - - protected String[] getExtendsConfigFiles() { - return new String[] { FESS_ENV_FILE }; - } - - // =================================================================================== - // Core - // ==== - @Override - protected OptionalCoreDirection prepareOptionalCoreDirection() { - final OptionalCoreDirection direction = new OptionalCoreDirection(); - prepareFramework(direction); - prepareSecurity(direction); - prepareTime(direction); - return direction; - } - - // ----------------------------------------------------- - // Framework - // --------- - protected void prepareFramework(OptionalCoreDirection direction) { - // this configuration is on fess_env.properties - // because this is true only when development - direction.directDevelopmentHere(fessConfig.isDevelopmentHere()); - - // titles are from configurations - direction.directLoggingTitle(fessConfig.getDomainTitle(), fessConfig.getEnvironmentTitle()); - - // this configuration is on sea_env.properties - // because it has no influence to production - // even if you set true manually and forget to set false back - direction.directFrameworkDebug(fessConfig.isFrameworkDebug()); // basically false - - // you can add your own process when your application is booting - direction.directBootProcessCallback(assistantDirector -> processDBFluteSystem()); - } - - protected void processDBFluteSystem() { - DBFluteSystem.unlock(); - DBFluteSystem.setFinalTimeZoneProvider(new DfFinalTimeZoneProvider() { - protected final TimeZone provided = FessUserTimeZoneProcessProvider.centralTimeZone; - - @Override - public TimeZone provide() { - return provided; - } - - @Override - public String toString() { - return DfTypeUtil.toClassTitle(this) + ":{" + provided.getID() + "}"; - } - }); - DBFluteSystem.lock(); - } - - // ----------------------------------------------------- - // Security - // -------- - protected void prepareSecurity(OptionalCoreDirection direction) { - final String key = getPrimarySecurityWord(); - final InvertibleCipher primaryInvertibleCipher = InvertibleCipher.createAesCipher(key); // AES for now - direction.directSecurity(() -> primaryInvertibleCipher); - } - - protected String getPrimarySecurityWord() { - return "fess:fess"; // hard coding for now - } - - // ----------------------------------------------------- - // Time - // ---- - protected void prepareTime(OptionalCoreDirection direction) { - direction.directTime(createTimeResourceProvider()); - } - - protected FessTimeResourceProvider createTimeResourceProvider() { - return new FessTimeResourceProvider(fessConfig); - } - - // =================================================================================== - // DB - // == - @Override - protected OptionalDBFluteDirection prepareOptionalDBFluteDirection() { - final OptionalDBFluteDirection direction = new OptionalDBFluteDirection(); - return direction; - } - - // =================================================================================== - // Web - // === - // ----------------------------------------------------- - // Action - // ------ - @Override - protected OptionalActionDirection prepareOptionalActionDirection() { - final OptionalActionDirection direction = new OptionalActionDirection(); - prepareAdjustment(direction); - prepareMessage(direction); - return direction; - } - - protected void prepareAdjustment(OptionalActionDirection direction) { - direction.directAdjustment(createActionAdjustmentProvider()); - } - - protected FessActionAdjustmentProvider createActionAdjustmentProvider() { - return new FessActionAdjustmentProvider(); - } - - protected void prepareMessage(OptionalActionDirection direction) { - direction.directMessage(getDomainMessageName(), getExtendsMessageNames()); - } - - protected String getDomainMessageName() { - return "fess_message"; - } - - protected String[] getExtendsMessageNames() { - return new String[] {}; - } - - // ----------------------------------------------------- - // Servlet - // ------- - @Override - protected OptionalServletDirection prepareOptionalServletDirection() { - final OptionalServletDirection direction = new OptionalServletDirection(); - prepareRequest(direction); - prepareCookie(direction); - return direction; - } - - protected OptionalServletDirection prepareRequest(OptionalServletDirection direction) { - direction.directRequest(createUserLocaleProcessProvider(), createUserTimeZoneProcessProvider()); - return direction; - } - - protected FessUserLocaleProcessProvider createUserLocaleProcessProvider() { - return new FessUserLocaleProcessProvider(); - } - - protected FessUserTimeZoneProcessProvider createUserTimeZoneProcessProvider() { - return new FessUserTimeZoneProcessProvider(); - } - - protected void prepareCookie(OptionalServletDirection direction) { - final String key = getCookieSecurityWord(); - final String cookieDefaultPath = fessConfig.getCookieDefaultPath(); - final Integer cookieDefaultExpire = fessConfig.getCookieDefaultExpireAsInteger(); - final InvertibleCipher cookieCipher = InvertibleCipher.createAesCipher(key); // AES for now - direction.directCookie(new CookieResourceProvider() { - @Override - public String provideDefaultPath() { - return cookieDefaultPath; - } - - @Override - public Integer provideDefaultExpire() { - return cookieDefaultExpire; - } - - @Override - public InvertibleCipher provideCipher() { - return cookieCipher; - } - - @Override - public String toString() { - return "{" + cookieDefaultPath + ", " + cookieDefaultExpire + "}"; - } - }); - } - - protected String getCookieSecurityWord() { - return "fess:fess"; // hard coding for now - } - - // ----------------------------------------------------- - // Task - // ---- - @Override - protected OptionalTaskDirection prepareOptionalTaskDirection() { - return new OptionalTaskDirection(); - } -} diff --git a/src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessActionAdjustmentProvider.java b/src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessActionAdjustmentProvider.java deleted file mode 100644 index 04825f0d1..000000000 --- a/src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessActionAdjustmentProvider.java +++ /dev/null @@ -1,73 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.lasta.core.direction.sponsor; - -import java.util.List; - -import javax.servlet.http.HttpServletRequest; - -import org.dbflute.saflute.web.action.processor.ActionAdjustmentProvider; -import org.dbflute.saflute.web.action.processor.ActionMappingWrapper; -import org.dbflute.util.DfTypeUtil; -import org.seasar.struts.config.S2ExecuteConfig; - -/** - * @author jflute - */ -public class FessActionAdjustmentProvider implements ActionAdjustmentProvider { - - private static final int INDEXED_PROPERTY_SIZE_LIMIT = 200; // hard coding for now - - @Override - public int provideIndexedPropertySizeLimit() { - return INDEXED_PROPERTY_SIZE_LIMIT; - } - - @Override - public String decodeUrlParameterPropertyValue(Object bean, String name, String value) { - return null; - } - - @Override - public String filterJspPath(String path, ActionMappingWrapper actionMappingWrapper) { - return null; - } - - @Override - public List prepareJspRetryWordList(String requestPath, List wordList) { - return null; - } - - @Override - public boolean isForcedRoutingTarget(HttpServletRequest request, String requestPath) { - return false; - } - - @Override - public boolean isForcedSuppressRedirectWithSlash(HttpServletRequest request, String requestPath, S2ExecuteConfig executeConfig) { - return false; - } - - @Override - public String customizeActionMappingRequestPath(String requestPath) { - return null; - } - - @Override - public String toString() { - return DfTypeUtil.toClassTitle(this) + ":{indexedLimit=" + INDEXED_PROPERTY_SIZE_LIMIT + "}"; - } -} diff --git a/src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessTimeResourceProvider.java b/src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessTimeResourceProvider.java deleted file mode 100644 index 888b794bd..000000000 --- a/src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessTimeResourceProvider.java +++ /dev/null @@ -1,96 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.lasta.core.direction.sponsor; - -import java.util.Date; - -import org.codelibs.fess.lasta.core.direction.FessConfig; -import org.dbflute.saflute.core.time.BusinessTimeHandler; -import org.dbflute.saflute.core.time.RelativeDateScript; -import org.dbflute.saflute.core.time.TimeManager; -import org.dbflute.saflute.core.time.TimeResourceProvider; -import org.dbflute.saflute.core.time.TypicalBusinessTimeHandler; - -/** - * @author jflute - */ -public class FessTimeResourceProvider implements TimeResourceProvider { - - // =================================================================================== - // Attribute - // ========= - protected final FessConfig maihamaConfig; - - protected final RelativeDateScript script = new RelativeDateScript(); - - // =================================================================================== - // Constructor - // =========== - public FessTimeResourceProvider(FessConfig maihamaConfig) { - this.maihamaConfig = maihamaConfig; - } - - // =================================================================================== - // Basic Handling - // ============== - @Override - public BusinessTimeHandler provideBusinessTimeHandler(TimeManager timeManager) { - return new TypicalBusinessTimeHandler(() -> { - return timeManager.getCurrentMillis(); - }, () -> { - return FessUserTimeZoneProcessProvider.centralTimeZone; - }); - } - - @Override - public boolean isCurrentIgnoreTransaction() { - // this project uses transaction time for current date - return false; // fixedly - } - - // =================================================================================== - // Time Adjustment - // =============== - @Override - public boolean isAdjustAbsoluteMode() { // *1 - final String exp = maihamaConfig.getTimeAdjustTimeMillis(); - return exp.startsWith("$"); // means absolute e.g. $(2014/07/10) - } - - @Override - public long provideAdjustTimeMillis() { // *1 - final String exp = maihamaConfig.getTimeAdjustTimeMillis(); - try { - return doProvideAdjustTimeMillis(exp); - } catch (final RuntimeException e) { - final String msg = "Illegal property for time.adjust.time.millis: " + exp; - throw new IllegalStateException(msg); - } - } - - protected long doProvideAdjustTimeMillis(final String exp) { - if (exp.startsWith("$")) { // absolute e.g. $(2014/07/10) - return script.resolveHardCodingDate(exp).getTime(); - } else if (exp.contains("(")) { // relative e.g. addDay(3) - final long current = System.currentTimeMillis(); - final Date resolved = script.resolveRelativeDate(exp, new Date(current)); - return resolved.getTime() - current; - } else { // should be millisecond as relative - return maihamaConfig.getTimeAdjustTimeMillisAsLong(); - } - } - // *1: called per called for dynamic change in development -} diff --git a/src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessUserLocaleProcessProvider.java b/src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessUserLocaleProcessProvider.java deleted file mode 100644 index 0b21164d5..000000000 --- a/src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessUserLocaleProcessProvider.java +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.lasta.core.direction.sponsor; - -import java.util.Locale; - -import org.dbflute.saflute.web.action.callback.ActionExecuteMeta; -import org.dbflute.saflute.web.servlet.request.RequestManager; -import org.dbflute.saflute.web.servlet.request.UserLocaleProcessProvider; - -/** - * @author jflute - */ -public class FessUserLocaleProcessProvider implements UserLocaleProcessProvider { - - public static final Locale centralLocale = Locale.getDefault(); // you can change it if you like - - /** - * {@inheritDoc} - */ - @Override - public boolean isAcceptCookieLocale() { - return false; - } - - /** - * {@inheritDoc} - */ - @Override - public Locale findBusinessLocale(ActionExecuteMeta executeMeta, RequestManager requestManager) { - return null; - } - - /** - * {@inheritDoc} - */ - @Override - public Locale getRequestedLocale(RequestManager requestManager) { - return null; // null means browser default - } - - /** - * {@inheritDoc} - */ - @Override - public Locale getFallbackLocale() { - return centralLocale; - } - - @Override - public String toString() { - return "{acceptCookieLocale=" + isAcceptCookieLocale() + ", fallbackLocale=" + getFallbackLocale() + "}"; - } -} diff --git a/src/main/java/org/codelibs/fess/lasta/web/action/FessJspPath.java b/src/main/java/org/codelibs/fess/lasta/web/action/FessJspPath.java deleted file mode 100644 index 4d7b34f97..000000000 --- a/src/main/java/org/codelibs/fess/lasta/web/action/FessJspPath.java +++ /dev/null @@ -1,416 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.lasta.web.action; - -/** - * The path definition of JSP. - * @author FreeGen - */ -public interface FessJspPath { - - /** The path of the JSP: /admin/boostDocumentRule/confirm.jsp */ - String path_AdminBoostDocumentRule_ConfirmJsp = "/admin/boostDocumentRule/confirm.jsp"; - - /** The path of the JSP: /admin/boostDocumentRule/edit.jsp */ - String path_AdminBoostDocumentRule_EditJsp = "/admin/boostDocumentRule/edit.jsp"; - - /** The path of the JSP: /admin/boostDocumentRule/error.jsp */ - String path_AdminBoostDocumentRule_ErrorJsp = "/admin/boostDocumentRule/error.jsp"; - - /** The path of the JSP: /admin/boostDocumentRule/index.jsp */ - String path_AdminBoostDocumentRule_IndexJsp = "/admin/boostDocumentRule/index.jsp"; - - /** The path of the JSP: /admin/crawl/index.jsp */ - String path_AdminCrawl_IndexJsp = "/admin/crawl/index.jsp"; - - /** The path of the JSP: /admin/crawlingSession/confirm.jsp */ - String path_AdminCrawlingSession_ConfirmJsp = "/admin/crawlingSession/confirm.jsp"; - - /** The path of the JSP: /admin/crawlingSession/error.jsp */ - String path_AdminCrawlingSession_ErrorJsp = "/admin/crawlingSession/error.jsp"; - - /** The path of the JSP: /admin/crawlingSession/index.jsp */ - String path_AdminCrawlingSession_IndexJsp = "/admin/crawlingSession/index.jsp"; - - /** The path of the JSP: /admin/data/index.jsp */ - String path_AdminData_IndexJsp = "/admin/data/index.jsp"; - - /** The path of the JSP: /admin/dataConfig/confirm.jsp */ - String path_AdminDataConfig_ConfirmJsp = "/admin/dataConfig/confirm.jsp"; - - /** The path of the JSP: /admin/dataConfig/edit.jsp */ - String path_AdminDataConfig_EditJsp = "/admin/dataConfig/edit.jsp"; - - /** The path of the JSP: /admin/dataConfig/error.jsp */ - String path_AdminDataConfig_ErrorJsp = "/admin/dataConfig/error.jsp"; - - /** The path of the JSP: /admin/dataConfig/index.jsp */ - String path_AdminDataConfig_IndexJsp = "/admin/dataConfig/index.jsp"; - - /** The path of the JSP: /admin/design/edit.jsp */ - String path_AdminDesign_EditJsp = "/admin/design/edit.jsp"; - - /** The path of the JSP: /admin/design/index.jsp */ - String path_AdminDesign_IndexJsp = "/admin/design/index.jsp"; - - /** The path of the JSP: /admin/dict/error.jsp */ - String path_AdminDict_ErrorJsp = "/admin/dict/error.jsp"; - - /** The path of the JSP: /admin/dict/index.jsp */ - String path_AdminDict_IndexJsp = "/admin/dict/index.jsp"; - - /** The path of the JSP: /admin/dict/synonym/confirm.jsp */ - String path_AdminDictSynonym_ConfirmJsp = "/admin/dict/synonym/confirm.jsp"; - - /** The path of the JSP: /admin/dict/synonym/download.jsp */ - String path_AdminDictSynonym_DownloadJsp = "/admin/dict/synonym/download.jsp"; - - /** The path of the JSP: /admin/dict/synonym/edit.jsp */ - String path_AdminDictSynonym_EditJsp = "/admin/dict/synonym/edit.jsp"; - - /** The path of the JSP: /admin/dict/synonym/error.jsp */ - String path_AdminDictSynonym_ErrorJsp = "/admin/dict/synonym/error.jsp"; - - /** The path of the JSP: /admin/dict/synonym/index.jsp */ - String path_AdminDictSynonym_IndexJsp = "/admin/dict/synonym/index.jsp"; - - /** The path of the JSP: /admin/dict/synonym/upload.jsp */ - String path_AdminDictSynonym_UploadJsp = "/admin/dict/synonym/upload.jsp"; - - /** The path of the JSP: /admin/dict/userDict/confirm.jsp */ - String path_AdminDictUserDict_ConfirmJsp = "/admin/dict/userDict/confirm.jsp"; - - /** The path of the JSP: /admin/dict/userDict/download.jsp */ - String path_AdminDictUserDict_DownloadJsp = "/admin/dict/userDict/download.jsp"; - - /** The path of the JSP: /admin/dict/userDict/edit.jsp */ - String path_AdminDictUserDict_EditJsp = "/admin/dict/userDict/edit.jsp"; - - /** The path of the JSP: /admin/dict/userDict/error.jsp */ - String path_AdminDictUserDict_ErrorJsp = "/admin/dict/userDict/error.jsp"; - - /** The path of the JSP: /admin/dict/userDict/index.jsp */ - String path_AdminDictUserDict_IndexJsp = "/admin/dict/userDict/index.jsp"; - - /** The path of the JSP: /admin/dict/userDict/upload.jsp */ - String path_AdminDictUserDict_UploadJsp = "/admin/dict/userDict/upload.jsp"; - - /** The path of the JSP: /admin/document/index.jsp */ - String path_AdminDocument_IndexJsp = "/admin/document/index.jsp"; - - /** The path of the JSP: /admin/failureUrl/confirm.jsp */ - String path_AdminFailureUrl_ConfirmJsp = "/admin/failureUrl/confirm.jsp"; - - /** The path of the JSP: /admin/failureUrl/error.jsp */ - String path_AdminFailureUrl_ErrorJsp = "/admin/failureUrl/error.jsp"; - - /** The path of the JSP: /admin/failureUrl/index.jsp */ - String path_AdminFailureUrl_IndexJsp = "/admin/failureUrl/index.jsp"; - - /** The path of the JSP: /admin/favoriteLog/confirm.jsp */ - String path_AdminFavoriteLog_ConfirmJsp = "/admin/favoriteLog/confirm.jsp"; - - /** The path of the JSP: /admin/favoriteLog/error.jsp */ - String path_AdminFavoriteLog_ErrorJsp = "/admin/favoriteLog/error.jsp"; - - /** The path of the JSP: /admin/favoriteLog/index.jsp */ - String path_AdminFavoriteLog_IndexJsp = "/admin/favoriteLog/index.jsp"; - - /** The path of the JSP: /admin/fileAuthentication/confirm.jsp */ - String path_AdminFileAuthentication_ConfirmJsp = "/admin/fileAuthentication/confirm.jsp"; - - /** The path of the JSP: /admin/fileAuthentication/edit.jsp */ - String path_AdminFileAuthentication_EditJsp = "/admin/fileAuthentication/edit.jsp"; - - /** The path of the JSP: /admin/fileAuthentication/error.jsp */ - String path_AdminFileAuthentication_ErrorJsp = "/admin/fileAuthentication/error.jsp"; - - /** The path of the JSP: /admin/fileAuthentication/index.jsp */ - String path_AdminFileAuthentication_IndexJsp = "/admin/fileAuthentication/index.jsp"; - - /** The path of the JSP: /admin/fileConfig/confirm.jsp */ - String path_AdminFileConfig_ConfirmJsp = "/admin/fileConfig/confirm.jsp"; - - /** The path of the JSP: /admin/fileConfig/edit.jsp */ - String path_AdminFileConfig_EditJsp = "/admin/fileConfig/edit.jsp"; - - /** The path of the JSP: /admin/fileConfig/error.jsp */ - String path_AdminFileConfig_ErrorJsp = "/admin/fileConfig/error.jsp"; - - /** The path of the JSP: /admin/fileConfig/index.jsp */ - String path_AdminFileConfig_IndexJsp = "/admin/fileConfig/index.jsp"; - - /** The path of the JSP: /admin/jobLog/confirm.jsp */ - String path_AdminJobLog_ConfirmJsp = "/admin/jobLog/confirm.jsp"; - - /** The path of the JSP: /admin/jobLog/error.jsp */ - String path_AdminJobLog_ErrorJsp = "/admin/jobLog/error.jsp"; - - /** The path of the JSP: /admin/jobLog/index.jsp */ - String path_AdminJobLog_IndexJsp = "/admin/jobLog/index.jsp"; - - /** The path of the JSP: /admin/keyMatch/confirm.jsp */ - String path_AdminKeyMatch_ConfirmJsp = "/admin/keyMatch/confirm.jsp"; - - /** The path of the JSP: /admin/keyMatch/edit.jsp */ - String path_AdminKeyMatch_EditJsp = "/admin/keyMatch/edit.jsp"; - - /** The path of the JSP: /admin/keyMatch/error.jsp */ - String path_AdminKeyMatch_ErrorJsp = "/admin/keyMatch/error.jsp"; - - /** The path of the JSP: /admin/keyMatch/index.jsp */ - String path_AdminKeyMatch_IndexJsp = "/admin/keyMatch/index.jsp"; - - /** The path of the JSP: /admin/labelType/confirm.jsp */ - String path_AdminLabelType_ConfirmJsp = "/admin/labelType/confirm.jsp"; - - /** The path of the JSP: /admin/labelType/edit.jsp */ - String path_AdminLabelType_EditJsp = "/admin/labelType/edit.jsp"; - - /** The path of the JSP: /admin/labelType/error.jsp */ - String path_AdminLabelType_ErrorJsp = "/admin/labelType/error.jsp"; - - /** The path of the JSP: /admin/labelType/index.jsp */ - String path_AdminLabelType_IndexJsp = "/admin/labelType/index.jsp"; - - /** The path of the JSP: /admin/log/index.jsp */ - String path_AdminLog_IndexJsp = "/admin/log/index.jsp"; - - /** The path of the JSP: /admin/overlappingHost/confirm.jsp */ - String path_AdminOverlappingHost_ConfirmJsp = "/admin/overlappingHost/confirm.jsp"; - - /** The path of the JSP: /admin/overlappingHost/edit.jsp */ - String path_AdminOverlappingHost_EditJsp = "/admin/overlappingHost/edit.jsp"; - - /** The path of the JSP: /admin/overlappingHost/error.jsp */ - String path_AdminOverlappingHost_ErrorJsp = "/admin/overlappingHost/error.jsp"; - - /** The path of the JSP: /admin/overlappingHost/index.jsp */ - String path_AdminOverlappingHost_IndexJsp = "/admin/overlappingHost/index.jsp"; - - /** The path of the JSP: /admin/pathMapping/confirm.jsp */ - String path_AdminPathMapping_ConfirmJsp = "/admin/pathMapping/confirm.jsp"; - - /** The path of the JSP: /admin/pathMapping/edit.jsp */ - String path_AdminPathMapping_EditJsp = "/admin/pathMapping/edit.jsp"; - - /** The path of the JSP: /admin/pathMapping/error.jsp */ - String path_AdminPathMapping_ErrorJsp = "/admin/pathMapping/error.jsp"; - - /** The path of the JSP: /admin/pathMapping/index.jsp */ - String path_AdminPathMapping_IndexJsp = "/admin/pathMapping/index.jsp"; - - /** The path of the JSP: /admin/requestHeader/confirm.jsp */ - String path_AdminRequestHeader_ConfirmJsp = "/admin/requestHeader/confirm.jsp"; - - /** The path of the JSP: /admin/requestHeader/edit.jsp */ - String path_AdminRequestHeader_EditJsp = "/admin/requestHeader/edit.jsp"; - - /** The path of the JSP: /admin/requestHeader/error.jsp */ - String path_AdminRequestHeader_ErrorJsp = "/admin/requestHeader/error.jsp"; - - /** The path of the JSP: /admin/requestHeader/index.jsp */ - String path_AdminRequestHeader_IndexJsp = "/admin/requestHeader/index.jsp"; - - /** The path of the JSP: /admin/roleType/confirm.jsp */ - String path_AdminRoleType_ConfirmJsp = "/admin/roleType/confirm.jsp"; - - /** The path of the JSP: /admin/roleType/edit.jsp */ - String path_AdminRoleType_EditJsp = "/admin/roleType/edit.jsp"; - - /** The path of the JSP: /admin/roleType/error.jsp */ - String path_AdminRoleType_ErrorJsp = "/admin/roleType/error.jsp"; - - /** The path of the JSP: /admin/roleType/index.jsp */ - String path_AdminRoleType_IndexJsp = "/admin/roleType/index.jsp"; - - /** The path of the JSP: /admin/scheduledJob/confirm.jsp */ - String path_AdminScheduledJob_ConfirmJsp = "/admin/scheduledJob/confirm.jsp"; - - /** The path of the JSP: /admin/scheduledJob/edit.jsp */ - String path_AdminScheduledJob_EditJsp = "/admin/scheduledJob/edit.jsp"; - - /** The path of the JSP: /admin/scheduledJob/error.jsp */ - String path_AdminScheduledJob_ErrorJsp = "/admin/scheduledJob/error.jsp"; - - /** The path of the JSP: /admin/scheduledJob/index.jsp */ - String path_AdminScheduledJob_IndexJsp = "/admin/scheduledJob/index.jsp"; - - /** The path of the JSP: /admin/searchList/confirmDelete.jsp */ - String path_AdminSearchList_ConfirmDeleteJsp = "/admin/searchList/confirmDelete.jsp"; - - /** The path of the JSP: /admin/searchList/index.jsp */ - String path_AdminSearchList_IndexJsp = "/admin/searchList/index.jsp"; - - /** The path of the JSP: /admin/searchLog/confirm.jsp */ - String path_AdminSearchLog_ConfirmJsp = "/admin/searchLog/confirm.jsp"; - - /** The path of the JSP: /admin/searchLog/error.jsp */ - String path_AdminSearchLog_ErrorJsp = "/admin/searchLog/error.jsp"; - - /** The path of the JSP: /admin/searchLog/index.jsp */ - String path_AdminSearchLog_IndexJsp = "/admin/searchLog/index.jsp"; - - /** The path of the JSP: /admin/stats/index.jsp */ - String path_AdminStats_IndexJsp = "/admin/stats/index.jsp"; - - /** The path of the JSP: /admin/suggestBadWord/confirm.jsp */ - String path_AdminSuggestBadWord_ConfirmJsp = "/admin/suggestBadWord/confirm.jsp"; - - /** The path of the JSP: /admin/suggestBadWord/download.jsp */ - String path_AdminSuggestBadWord_DownloadJsp = "/admin/suggestBadWord/download.jsp"; - - /** The path of the JSP: /admin/suggestBadWord/edit.jsp */ - String path_AdminSuggestBadWord_EditJsp = "/admin/suggestBadWord/edit.jsp"; - - /** The path of the JSP: /admin/suggestBadWord/error.jsp */ - String path_AdminSuggestBadWord_ErrorJsp = "/admin/suggestBadWord/error.jsp"; - - /** The path of the JSP: /admin/suggestBadWord/index.jsp */ - String path_AdminSuggestBadWord_IndexJsp = "/admin/suggestBadWord/index.jsp"; - - /** The path of the JSP: /admin/suggestBadWord/upload.jsp */ - String path_AdminSuggestBadWord_UploadJsp = "/admin/suggestBadWord/upload.jsp"; - - /** The path of the JSP: /admin/suggestElevateWord/confirm.jsp */ - String path_AdminSuggestElevateWord_ConfirmJsp = "/admin/suggestElevateWord/confirm.jsp"; - - /** The path of the JSP: /admin/suggestElevateWord/download.jsp */ - String path_AdminSuggestElevateWord_DownloadJsp = "/admin/suggestElevateWord/download.jsp"; - - /** The path of the JSP: /admin/suggestElevateWord/edit.jsp */ - String path_AdminSuggestElevateWord_EditJsp = "/admin/suggestElevateWord/edit.jsp"; - - /** The path of the JSP: /admin/suggestElevateWord/error.jsp */ - String path_AdminSuggestElevateWord_ErrorJsp = "/admin/suggestElevateWord/error.jsp"; - - /** The path of the JSP: /admin/suggestElevateWord/index.jsp */ - String path_AdminSuggestElevateWord_IndexJsp = "/admin/suggestElevateWord/index.jsp"; - - /** The path of the JSP: /admin/suggestElevateWord/upload.jsp */ - String path_AdminSuggestElevateWord_UploadJsp = "/admin/suggestElevateWord/upload.jsp"; - - /** The path of the JSP: /admin/system/index.jsp */ - String path_AdminSystem_IndexJsp = "/admin/system/index.jsp"; - - /** The path of the JSP: /admin/systemInfo/index.jsp */ - String path_AdminSystemInfo_IndexJsp = "/admin/systemInfo/index.jsp"; - - /** The path of the JSP: /admin/userInfo/confirm.jsp */ - String path_AdminUserInfo_ConfirmJsp = "/admin/userInfo/confirm.jsp"; - - /** The path of the JSP: /admin/userInfo/error.jsp */ - String path_AdminUserInfo_ErrorJsp = "/admin/userInfo/error.jsp"; - - /** The path of the JSP: /admin/userInfo/index.jsp */ - String path_AdminUserInfo_IndexJsp = "/admin/userInfo/index.jsp"; - - /** The path of the JSP: /admin/webAuthentication/confirm.jsp */ - String path_AdminWebAuthentication_ConfirmJsp = "/admin/webAuthentication/confirm.jsp"; - - /** The path of the JSP: /admin/webAuthentication/edit.jsp */ - String path_AdminWebAuthentication_EditJsp = "/admin/webAuthentication/edit.jsp"; - - /** The path of the JSP: /admin/webAuthentication/error.jsp */ - String path_AdminWebAuthentication_ErrorJsp = "/admin/webAuthentication/error.jsp"; - - /** The path of the JSP: /admin/webAuthentication/index.jsp */ - String path_AdminWebAuthentication_IndexJsp = "/admin/webAuthentication/index.jsp"; - - /** The path of the JSP: /admin/webConfig/confirm.jsp */ - String path_AdminWebConfig_ConfirmJsp = "/admin/webConfig/confirm.jsp"; - - /** The path of the JSP: /admin/webConfig/edit.jsp */ - String path_AdminWebConfig_EditJsp = "/admin/webConfig/edit.jsp"; - - /** The path of the JSP: /admin/webConfig/error.jsp */ - String path_AdminWebConfig_ErrorJsp = "/admin/webConfig/error.jsp"; - - /** The path of the JSP: /admin/webConfig/index.jsp */ - String path_AdminWebConfig_IndexJsp = "/admin/webConfig/index.jsp"; - - /** The path of the JSP: /admin/wizard/crawlingConfig.jsp */ - String path_AdminWizard_CrawlingConfigJsp = "/admin/wizard/crawlingConfig.jsp"; - - /** The path of the JSP: /admin/wizard/error.jsp */ - String path_AdminWizard_ErrorJsp = "/admin/wizard/error.jsp"; - - /** The path of the JSP: /admin/wizard/index.jsp */ - String path_AdminWizard_IndexJsp = "/admin/wizard/index.jsp"; - - /** The path of the JSP: /admin/wizard/startCrawling.jsp */ - String path_AdminWizard_StartCrawlingJsp = "/admin/wizard/startCrawling.jsp"; - - /** The path of the JSP: /error/badRequest.jsp */ - String path_Error_BadRequestJsp = "/error/badRequest.jsp"; - - /** The path of the JSP: /error/error_message.jsp */ - String path_Error_ErrorMessageJsp = "/error/error_message.jsp"; - - /** The path of the JSP: /error/footer.jsp */ - String path_Error_FooterJsp = "/error/footer.jsp"; - - /** The path of the JSP: /error/header.jsp */ - String path_Error_HeaderJsp = "/error/header.jsp"; - - /** The path of the JSP: /error/notFound.jsp */ - String path_Error_NotFoundJsp = "/error/notFound.jsp"; - - /** The path of the JSP: /error/redirect.jsp */ - String path_Error_RedirectJsp = "/error/redirect.jsp"; - - /** The path of the JSP: /error/system.jsp */ - String path_Error_SystemJsp = "/error/system.jsp"; - - /** The path of the JSP: /error.jsp */ - String path_ErrorJsp = "/error.jsp"; - - /** The path of the JSP: /footer.jsp */ - String path_FooterJsp = "/footer.jsp"; - - /** The path of the JSP: /header.jsp */ - String path_HeaderJsp = "/header.jsp"; - - /** The path of the JSP: /help.jsp */ - String path_HelpJsp = "/help.jsp"; - - /** The path of the JSP: /index.jsp */ - String path_IndexJsp = "/index.jsp"; - - /** The path of the JSP: /login/error.jsp */ - String path_Login_ErrorJsp = "/login/error.jsp"; - - /** The path of the JSP: /login/footer.jsp */ - String path_Login_FooterJsp = "/login/footer.jsp"; - - /** The path of the JSP: /login/header.jsp */ - String path_Login_HeaderJsp = "/login/header.jsp"; - - /** The path of the JSP: /login/index.jsp */ - String path_Login_IndexJsp = "/login/index.jsp"; - - /** The path of the JSP: /login/logout.jsp */ - String path_Login_LogoutJsp = "/login/logout.jsp"; - - /** The path of the JSP: /search.jsp */ - String path_SearchJsp = "/search.jsp"; - - /** The path of the JSP: /searchNoResult.jsp */ - String path_SearchNoResultJsp = "/searchNoResult.jsp"; - - /** The path of the JSP: /searchResults.jsp */ - String path_SearchResultsJsp = "/searchResults.jsp"; -} diff --git a/src/main/java/org/codelibs/fess/lasta/web/action/FessLoginRequired.java b/src/main/java/org/codelibs/fess/lasta/web/action/FessLoginRequired.java deleted file mode 100644 index 5f646a34d..000000000 --- a/src/main/java/org/codelibs/fess/lasta/web/action/FessLoginRequired.java +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.lasta.web.action; - -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; - -/** - * @author jflute - */ -// needs inheritance when type because action is enhanced -@Inherited -@Retention(RetentionPolicy.RUNTIME) -@Target({ ElementType.TYPE, ElementType.METHOD }) -public @interface FessLoginRequired { -} diff --git a/src/main/java/org/codelibs/fess/lasta/web/action/FessMessages.java b/src/main/java/org/codelibs/fess/lasta/web/action/FessMessages.java deleted file mode 100644 index 1cbf9311f..000000000 --- a/src/main/java/org/codelibs/fess/lasta/web/action/FessMessages.java +++ /dev/null @@ -1,736 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.lasta.web.action; - -import org.apache.struts.action.ActionMessage; -import org.apache.struts.action.ActionMessages; - -/** - * The keys for message. - * @author FreeGen - */ -public class FessMessages extends ActionMessages { - - /** The serial version UID for object serialization. (Default) */ - private static final long serialVersionUID = 1L; - - /** The key of the message:
      */ - public static final String ERRORS_HEADER = "errors.header"; - - /** The key of the message:
    */ - public static final String ERRORS_FOOTER = "errors.footer"; - - /** The key of the message:
  • */ - public static final String ERRORS_PREFIX = "errors.prefix"; - - /** The key of the message:
  • */ - public static final String ERRORS_SUFFIX = "errors.suffix"; - - /** The key of the message: {0}は必須です。 */ - public static final String ERRORS_REQUIRED = "errors.required"; - - /** The key of the message: {0}の長さが最小値({1})未満です。 */ - public static final String ERRORS_MINLENGTH = "errors.minlength"; - - /** The key of the message: {0}の長さが最大値({1})を超えています。 */ - public static final String ERRORS_MAXLENGTH = "errors.maxlength"; - - /** The key of the message: {0}のバイト長が最小値({1})未満です。 */ - public static final String ERRORS_MINBYTELENGTH = "errors.minbytelength"; - - /** The key of the message: {0}のバイト長が最大値({1})を超えています。 */ - public static final String ERRORS_MAXBYTELENGTH = "errors.maxbytelength"; - - /** The key of the message: {0}が不正です。 */ - public static final String ERRORS_INVALID = "errors.invalid"; - - /** The key of the message: {0}は{1}と{2}の間でなければいけません。 */ - public static final String ERRORS_RANGE = "errors.range"; - - /** The key of the message: {0}はバイトでなければいけません。 */ - public static final String ERRORS_BYTE = "errors.byte"; - - /** The key of the message: {0}は短整数でなければいけません。 */ - public static final String ERRORS_SHORT = "errors.short"; - - /** The key of the message: {0}は整数でなければいけません。 */ - public static final String ERRORS_INTEGER = "errors.integer"; - - /** The key of the message: {0}は長整数でなければいけません。 */ - public static final String ERRORS_LONG = "errors.long"; - - /** The key of the message: {0}は単精度実数でなければいけません。 */ - public static final String ERRORS_FLOAT = "errors.float"; - - /** The key of the message: {0}は倍精度実数でなければいけません。 */ - public static final String ERRORS_DOUBLE = "errors.double"; - - /** The key of the message: {0}は日付でなければいけません */ - public static final String ERRORS_DATE = "errors.date"; - - /** The key of the message: {0}はクレジットカード番号として不正です。 */ - public static final String ERRORS_CREDITCARD = "errors.creditcard"; - - /** The key of the message: {0}はメールアドレスとして不正です。 */ - public static final String ERRORS_EMAIL = "errors.email"; - - /** The key of the message: {0}はURLとして不正です。 */ - public static final String ERRORS_URL = "errors.url"; - - /** The key of the message: {0}は数値を入力してください */ - public static final String ERRORS_NUMBER = "errors.number"; - - /** The key of the message: {0}に同一の項目が選ばれています */ - public static final String ERRORS_SAME_VALUE = "errors.same.value"; - - /** The key of the message: {0}は{1}より大きい数値を入力してください */ - public static final String ERRORS_GREATER_THAN = "errors.greater.than"; - - /** The key of the message: {0}のいずれかを入力してください */ - public static final String ERRORS_REQUIRED_AT_LEAST_ONE = "errors.required.at.least.one"; - - /** The key of the message: {0}と{1}のどちらかを入力してください */ - public static final String ERRORS_REQUIRED_OR = "errors.required.or"; - - /** The key of the message: 上限が{1}バイトなのに実際は{0}バイトだったのでアップロードできませんでした。 */ - public static final String ERRORS_UPLOAD_SIZE = "errors.upload.size"; - - /** The key of the message: メールアドレスまたはパスワードが未入力です */ - public static final String ERRORS_EMPTY_LOGIN = "errors.empty.login"; - - /** The key of the message: メールアドレス又はパスワードが間違っています */ - public static final String ERRORS_NOT_LOGIN = "errors.not.login"; - - /** The key of the message: 既に登録済みのメールアドレスです */ - public static final String ERRORS_EMAIL_EXISTS = "errors.email.exists"; - - /** The key of the message: {0}はすでに登録されている{1}です */ - public static final String ERRORS_ALREADY_REGISTERED = "errors.already.registered"; - - /** The key of the message: 他の人が更新した可能性があります。再度やり直してください */ - public static final String ERRORS_APP_ALREADY_DELETED = "errors.app.already.deleted"; - - /** The key of the message: 他の人が更新した可能性があります。再度やり直してください */ - public static final String ERRORS_APP_ALREADY_UPDATED = "errors.app.already.updated"; - - /** The key of the message: 既に登録されているデータです。再度やり直してください */ - public static final String ERRORS_APP_ALREADY_EXISTS = "errors.app.already.exists"; - - /** The key of the message: 不正なアクセスがされました。再度やり直してください */ - public static final String ERRORS_APP_ILLEGAL_TRANSITION = "errors.app.illegal.transition"; - - /** The key of the message: 検索キーワードを入力 */ - public static final String MESSAGES_INPUT_NOTE_KEYWORD = "messages.input.note.keyword"; - - /** The key of the message: メールアドレスを入力 */ - public static final String MESSAGES_INPUT_NOTE_EMAIL = "messages.input.note.email"; - - /** The key of the message: Pixy って入れてー */ - public static final String MESSAGES_INPUT_NOTE_EMAIL_OR_ACCOUNT = "messages.input.note.emailOrAccount"; - - /** The key of the message: sea って入れてー */ - public static final String MESSAGES_INPUT_NOTE_PASSWORD = "messages.input.note.password"; - - /** The key of the message: 例: 153-0051 */ - public static final String MESSAGES_INPUT_NOTE_ZIP_CODE = "messages.input.note.zipCode"; - - /** - * Add the created action message for the key 'errors.header' with parameters. - *
    -     * message: 
      - *
    - * @param property The property name for the message. (NotNull) - */ - public void addErrorsHeader(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_HEADER, (Object[]) null)); - } - - /** - * Add the created action message for the key 'errors.footer' with parameters. - *
    -     * message: 
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addErrorsFooter(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_FOOTER, (Object[]) null)); - } - - /** - * Add the created action message for the key 'errors.prefix' with parameters. - *
    -     * message: 
  • - *
  • - * @param property The property name for the message. (NotNull) - */ - public void addErrorsPrefix(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_PREFIX, (Object[]) null)); - } - - /** - * Add the created action message for the key 'errors.suffix' with parameters. - *
    -     * message: 
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addErrorsSuffix(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_SUFFIX, (Object[]) null)); - } - - /** - * Add the created action message for the key 'errors.required' with parameters. - *
    -     * message: {0}は必須です。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsRequired(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_REQUIRED, arg0)); - } - - /** - * Add the created action message for the key 'errors.minlength' with parameters. - *
    -     * message: {0}の長さが最小値({1})未満です。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - * @param arg1 The parameter 1 for message. (NotNull) - */ - public void addErrorsMinlength(String property, String arg0, String arg1) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_MINLENGTH, arg0, arg1)); - } - - /** - * Add the created action message for the key 'errors.maxlength' with parameters. - *
    -     * message: {0}の長さが最大値({1})を超えています。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - * @param arg1 The parameter 1 for message. (NotNull) - */ - public void addErrorsMaxlength(String property, String arg0, String arg1) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_MAXLENGTH, arg0, arg1)); - } - - /** - * Add the created action message for the key 'errors.minbytelength' with parameters. - *
    -     * message: {0}のバイト長が最小値({1})未満です。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - * @param arg1 The parameter 1 for message. (NotNull) - */ - public void addErrorsMinbytelength(String property, String arg0, String arg1) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_MINBYTELENGTH, arg0, arg1)); - } - - /** - * Add the created action message for the key 'errors.maxbytelength' with parameters. - *
    -     * message: {0}のバイト長が最大値({1})を超えています。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - * @param arg1 The parameter 1 for message. (NotNull) - */ - public void addErrorsMaxbytelength(String property, String arg0, String arg1) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_MAXBYTELENGTH, arg0, arg1)); - } - - /** - * Add the created action message for the key 'errors.invalid' with parameters. - *
    -     * message: {0}が不正です。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsInvalid(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_INVALID, arg0)); - } - - /** - * Add the created action message for the key 'errors.range' with parameters. - *
    -     * message: {0}は{1}と{2}の間でなければいけません。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - * @param arg1 The parameter 1 for message. (NotNull) - * @param arg2 The parameter 2 for message. (NotNull) - */ - public void addErrorsRange(String property, String arg0, String arg1, String arg2) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_RANGE, arg0, arg1, arg2)); - } - - /** - * Add the created action message for the key 'errors.byte' with parameters. - *
    -     * message: {0}はバイトでなければいけません。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsByte(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_BYTE, arg0)); - } - - /** - * Add the created action message for the key 'errors.short' with parameters. - *
    -     * message: {0}は短整数でなければいけません。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsShort(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_SHORT, arg0)); - } - - /** - * Add the created action message for the key 'errors.integer' with parameters. - *
    -     * message: {0}は整数でなければいけません。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsInteger(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_INTEGER, arg0)); - } - - /** - * Add the created action message for the key 'errors.long' with parameters. - *
    -     * message: {0}は長整数でなければいけません。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsLong(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_LONG, arg0)); - } - - /** - * Add the created action message for the key 'errors.float' with parameters. - *
    -     * message: {0}は単精度実数でなければいけません。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsFloat(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_FLOAT, arg0)); - } - - /** - * Add the created action message for the key 'errors.double' with parameters. - *
    -     * message: {0}は倍精度実数でなければいけません。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsDouble(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_DOUBLE, arg0)); - } - - /** - * Add the created action message for the key 'errors.date' with parameters. - *
    -     * message: {0}は日付でなければいけません
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsDate(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_DATE, arg0)); - } - - /** - * Add the created action message for the key 'errors.creditcard' with parameters. - *
    -     * message: {0}はクレジットカード番号として不正です。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsCreditcard(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_CREDITCARD, arg0)); - } - - /** - * Add the created action message for the key 'errors.email' with parameters. - *
    -     * message: {0}はメールアドレスとして不正です。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsEmail(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_EMAIL, arg0)); - } - - /** - * Add the created action message for the key 'errors.url' with parameters. - *
    -     * message: {0}はURLとして不正です。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsUrl(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_URL, arg0)); - } - - /** - * Add the created action message for the key 'errors.number' with parameters. - *
    -     * message: {0}は数値を入力してください
    -     * comment: -------------
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsNumber(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_NUMBER, arg0)); - } - - /** - * Add the created action message for the key 'errors.same.value' with parameters. - *
    -     * message: {0}に同一の項目が選ばれています
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsSameValue(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_SAME_VALUE, arg0)); - } - - /** - * Add the created action message for the key 'errors.greater.than' with parameters. - *
    -     * message: {0}は{1}より大きい数値を入力してください
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - * @param arg1 The parameter 1 for message. (NotNull) - */ - public void addErrorsGreaterThan(String property, String arg0, String arg1) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_GREATER_THAN, arg0, arg1)); - } - - /** - * Add the created action message for the key 'errors.required.at.least.one' with parameters. - *
    -     * message: {0}のいずれかを入力してください
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsRequiredAtLeastOne(String property, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_REQUIRED_AT_LEAST_ONE, arg0)); - } - - /** - * Add the created action message for the key 'errors.required.or' with parameters. - *
    -     * message: {0}と{1}のどちらかを入力してください
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - * @param arg1 The parameter 1 for message. (NotNull) - */ - public void addErrorsRequiredOr(String property, String arg0, String arg1) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_REQUIRED_OR, arg0, arg1)); - } - - /** - * Add the created action message for the key 'errors.upload.size' with parameters. - *
    -     * message: 上限が{1}バイトなのに実際は{0}バイトだったのでアップロードできませんでした。
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg1 The parameter 1 for message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - */ - public void addErrorsUploadSize(String property, String arg1, String arg0) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_UPLOAD_SIZE, arg1, arg0)); - } - - /** - * Add the created action message for the key 'errors.empty.login' with parameters. - *
    -     * message: メールアドレスまたはパスワードが未入力です
    -     * comment: ----------------
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addErrorsEmptyLogin(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_EMPTY_LOGIN, (Object[]) null)); - } - - /** - * Add the created action message for the key 'errors.not.login' with parameters. - *
    -     * message: メールアドレス又はパスワードが間違っています
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addErrorsNotLogin(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_NOT_LOGIN, (Object[]) null)); - } - - /** - * Add the created action message for the key 'errors.email.exists' with parameters. - *
    -     * message: 既に登録済みのメールアドレスです
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addErrorsEmailExists(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_EMAIL_EXISTS, (Object[]) null)); - } - - /** - * Add the created action message for the key 'errors.already.registered' with parameters. - *
    -     * message: {0}はすでに登録されている{1}です
    -     * 
    - * @param property The property name for the message. (NotNull) - * @param arg0 The parameter 0 for message. (NotNull) - * @param arg1 The parameter 1 for message. (NotNull) - */ - public void addErrorsAlreadyRegistered(String property, String arg0, String arg1) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_ALREADY_REGISTERED, arg0, arg1)); - } - - /** - * Add the created action message for the key 'errors.app.already.deleted' with parameters. - *
    -     * message: 他の人が更新した可能性があります。再度やり直してください
    -     * comment: ---------------------
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addErrorsAppAlreadyDeleted(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_APP_ALREADY_DELETED, (Object[]) null)); - } - - /** - * Add the created action message for the key 'errors.app.already.updated' with parameters. - *
    -     * message: 他の人が更新した可能性があります。再度やり直してください
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addErrorsAppAlreadyUpdated(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_APP_ALREADY_UPDATED, (Object[]) null)); - } - - /** - * Add the created action message for the key 'errors.app.already.exists' with parameters. - *
    -     * message: 既に登録されているデータです。再度やり直してください
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addErrorsAppAlreadyExists(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_APP_ALREADY_EXISTS, (Object[]) null)); - } - - /** - * Add the created action message for the key 'errors.app.illegal.transition' with parameters. - *
    -     * message: 不正なアクセスがされました。再度やり直してください
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addErrorsAppIllegalTransition(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(ERRORS_APP_ILLEGAL_TRANSITION, (Object[]) null)); - } - - /** - * Add the created action message for the key 'messages.input.note.keyword' with parameters. - *
    -     * message: 検索キーワードを入力
    -     * comment: ----------
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addMessagesInputNoteKeyword(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(MESSAGES_INPUT_NOTE_KEYWORD, (Object[]) null)); - } - - /** - * Add the created action message for the key 'messages.input.note.email' with parameters. - *
    -     * message: メールアドレスを入力
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addMessagesInputNoteEmail(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(MESSAGES_INPUT_NOTE_EMAIL, (Object[]) null)); - } - - /** - * Add the created action message for the key 'messages.input.note.emailOrAccount' with parameters. - *
    -     * message: Pixy って入れてー
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addMessagesInputNoteEmailOrAccount(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(MESSAGES_INPUT_NOTE_EMAIL_OR_ACCOUNT, (Object[]) null)); - } - - /** - * Add the created action message for the key 'messages.input.note.password' with parameters. - *
    -     * message: sea って入れてー
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addMessagesInputNotePassword(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(MESSAGES_INPUT_NOTE_PASSWORD, (Object[]) null)); - } - - /** - * Add the created action message for the key 'messages.input.note.zipCode' with parameters. - *
    -     * message: 例: 153-0051
    -     * 
    - * @param property The property name for the message. (NotNull) - */ - public void addMessagesInputNoteZipCode(String property) { - assertPropertyNotNull(property); - add(property, new ActionMessage(MESSAGES_INPUT_NOTE_ZIP_CODE, (Object[]) null)); - } - - /** - * Assert the property is not null. - * @param property The value of the property. (NotNull) - */ - protected void assertPropertyNotNull(String property) { - if (property == null) { - final String msg = "The argument 'property' for message should not be null."; - throw new IllegalArgumentException(msg); - } - } - - /** - * The definition of keys for labels. - * @author FreeGen - */ - public static interface LabelKey { - - /** The key of the label: 会員 */ - String LABELS_MEMBER = "labels.member"; - - /** The key of the label: 会員ID */ - String LABELS_MEMBER_ID = "labels.memberId"; - - /** The key of the label: 会員名称 */ - String LABELS_MEMBER_NAME = "labels.memberName"; - - /** The key of the label: メールアドレス */ - String LABELS_EMAIL = "labels.email"; - - /** The key of the label: メアドもしくはアカウント */ - String LABELS_EMAIL_OR_ACCOUNT = "labels.emailOrAccount"; - - /** The key of the label: パスワード */ - String LABELS_PASSWORD = "labels.password"; - - /** The key of the label: バージョンNo */ - String LABELS_VERSION_NO = "labels.versionNo"; - - /** The key of the label: 一覧 */ - String LABELS_LIST = "labels.list"; - - /** The key of the label: 追加 */ - String LABELS_ADD = "labels.add"; - - /** The key of the label: 編集 */ - String LABELS_EDIT = "labels.edit"; - - /** The key of the label: 検索 */ - String LABELS_SEARCH = "labels.search"; - - /** The key of the label: 登録 */ - String LABELS_REGISTER = "labels.register"; - - /** The key of the label: 更新 */ - String LABELS_UPDATE = "labels.update"; - - /** The key of the label: @[labels.member]@[labels.list] */ - String LABELS_MEMBER_LIST = "labels.member.list"; - - /** The key of the label: @[labels.member]@[labels.add] */ - String LABELS_MEMBER_ADD = "labels.member.add"; - - /** The key of the label: @[labels.member]@[labels.edit] */ - String LABELS_MEMBER_EDIT = "labels.member.edit"; - - /** The key of the label: お知らせ */ - String LABELS_HEADER_TITLE_ERROR_MESSAGE = "labels.header.title.error.message"; - } -} diff --git a/src/main/java/org/codelibs/fess/lasta/web/action/FessPerformLogin.java b/src/main/java/org/codelibs/fess/lasta/web/action/FessPerformLogin.java deleted file mode 100644 index 2b380190e..000000000 --- a/src/main/java/org/codelibs/fess/lasta/web/action/FessPerformLogin.java +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.lasta.web.action; - -import java.lang.annotation.ElementType; -import java.lang.annotation.Retention; -import java.lang.annotation.RetentionPolicy; -import java.lang.annotation.Target; - -/** - * @author jflute - */ -@Retention(RetentionPolicy.RUNTIME) -@Target(value = ElementType.METHOD) -public @interface FessPerformLogin { -} diff --git a/src/main/java/org/codelibs/fess/mylasta/action/FessHtmlPath.java b/src/main/java/org/codelibs/fess/mylasta/action/FessHtmlPath.java new file mode 100644 index 000000000..e17347fe8 --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/action/FessHtmlPath.java @@ -0,0 +1,403 @@ +package org.codelibs.fess.mylasta.action; + +import org.lastaflute.web.response.next.HtmlNext; + +/** + * The path definition of HTML. + * @author FreeGen + */ +public interface FessHtmlPath { + + /** The path of the HTML: /admin/boostdocumentrule/confirm.jsp */ + HtmlNext path_AdminBoostdocumentrule_ConfirmJsp = new HtmlNext("/admin/boostdocumentrule/confirm.jsp"); + + /** The path of the HTML: /admin/boostdocumentrule/edit.jsp */ + HtmlNext path_AdminBoostdocumentrule_EditJsp = new HtmlNext("/admin/boostdocumentrule/edit.jsp"); + + /** The path of the HTML: /admin/boostdocumentrule/error.jsp */ + HtmlNext path_AdminBoostdocumentrule_ErrorJsp = new HtmlNext("/admin/boostdocumentrule/error.jsp"); + + /** The path of the HTML: /admin/boostdocumentrule/index.jsp */ + HtmlNext path_AdminBoostdocumentrule_IndexJsp = new HtmlNext("/admin/boostdocumentrule/index.jsp"); + + /** The path of the HTML: /admin/crawl/index.jsp */ + HtmlNext path_AdminCrawl_IndexJsp = new HtmlNext("/admin/crawl/index.jsp"); + + /** The path of the HTML: /admin/crawlingsession/confirm.jsp */ + HtmlNext path_AdminCrawlingsession_ConfirmJsp = new HtmlNext("/admin/crawlingsession/confirm.jsp"); + + /** The path of the HTML: /admin/crawlingsession/error.jsp */ + HtmlNext path_AdminCrawlingsession_ErrorJsp = new HtmlNext("/admin/crawlingsession/error.jsp"); + + /** The path of the HTML: /admin/crawlingsession/index.jsp */ + HtmlNext path_AdminCrawlingsession_IndexJsp = new HtmlNext("/admin/crawlingsession/index.jsp"); + + /** The path of the HTML: /admin/data/index.jsp */ + HtmlNext path_AdminData_IndexJsp = new HtmlNext("/admin/data/index.jsp"); + + /** The path of the HTML: /admin/dataconfig/confirm.jsp */ + HtmlNext path_AdminDataconfig_ConfirmJsp = new HtmlNext("/admin/dataconfig/confirm.jsp"); + + /** The path of the HTML: /admin/dataconfig/edit.jsp */ + HtmlNext path_AdminDataconfig_EditJsp = new HtmlNext("/admin/dataconfig/edit.jsp"); + + /** The path of the HTML: /admin/dataconfig/error.jsp */ + HtmlNext path_AdminDataconfig_ErrorJsp = new HtmlNext("/admin/dataconfig/error.jsp"); + + /** The path of the HTML: /admin/dataconfig/index.jsp */ + HtmlNext path_AdminDataconfig_IndexJsp = new HtmlNext("/admin/dataconfig/index.jsp"); + + /** The path of the HTML: /admin/design/admin_design.jsp */ + HtmlNext path_AdminDesign_AdminDesignJsp = new HtmlNext("/admin/design/admin_design.jsp"); + + /** The path of the HTML: /admin/design/admin_design_edit.jsp */ + HtmlNext path_AdminDesign_AdminDesignEditJsp = new HtmlNext("/admin/design/admin_design_edit.jsp"); + + /** The path of the HTML: /admin/dict/error.jsp */ + HtmlNext path_AdminDict_ErrorJsp = new HtmlNext("/admin/dict/error.jsp"); + + /** The path of the HTML: /admin/dict/index.jsp */ + HtmlNext path_AdminDict_IndexJsp = new HtmlNext("/admin/dict/index.jsp"); + + /** The path of the HTML: /admin/dict/synonym/confirm.jsp */ + HtmlNext path_AdminDictSynonym_ConfirmJsp = new HtmlNext("/admin/dict/synonym/confirm.jsp"); + + /** The path of the HTML: /admin/dict/synonym/download.jsp */ + HtmlNext path_AdminDictSynonym_DownloadJsp = new HtmlNext("/admin/dict/synonym/download.jsp"); + + /** The path of the HTML: /admin/dict/synonym/edit.jsp */ + HtmlNext path_AdminDictSynonym_EditJsp = new HtmlNext("/admin/dict/synonym/edit.jsp"); + + /** The path of the HTML: /admin/dict/synonym/error.jsp */ + HtmlNext path_AdminDictSynonym_ErrorJsp = new HtmlNext("/admin/dict/synonym/error.jsp"); + + /** The path of the HTML: /admin/dict/synonym/index.jsp */ + HtmlNext path_AdminDictSynonym_IndexJsp = new HtmlNext("/admin/dict/synonym/index.jsp"); + + /** The path of the HTML: /admin/dict/synonym/upload.jsp */ + HtmlNext path_AdminDictSynonym_UploadJsp = new HtmlNext("/admin/dict/synonym/upload.jsp"); + + /** The path of the HTML: /admin/dict/userdict/confirm.jsp */ + HtmlNext path_AdminDictUserdict_ConfirmJsp = new HtmlNext("/admin/dict/userdict/confirm.jsp"); + + /** The path of the HTML: /admin/dict/userdict/download.jsp */ + HtmlNext path_AdminDictUserdict_DownloadJsp = new HtmlNext("/admin/dict/userdict/download.jsp"); + + /** The path of the HTML: /admin/dict/userdict/edit.jsp */ + HtmlNext path_AdminDictUserdict_EditJsp = new HtmlNext("/admin/dict/userdict/edit.jsp"); + + /** The path of the HTML: /admin/dict/userdict/error.jsp */ + HtmlNext path_AdminDictUserdict_ErrorJsp = new HtmlNext("/admin/dict/userdict/error.jsp"); + + /** The path of the HTML: /admin/dict/userdict/index.jsp */ + HtmlNext path_AdminDictUserdict_IndexJsp = new HtmlNext("/admin/dict/userdict/index.jsp"); + + /** The path of the HTML: /admin/dict/userdict/upload.jsp */ + HtmlNext path_AdminDictUserdict_UploadJsp = new HtmlNext("/admin/dict/userdict/upload.jsp"); + + /** The path of the HTML: /admin/failureurl/confirm.jsp */ + HtmlNext path_AdminFailureurl_ConfirmJsp = new HtmlNext("/admin/failureurl/confirm.jsp"); + + /** The path of the HTML: /admin/failureurl/error.jsp */ + HtmlNext path_AdminFailureurl_ErrorJsp = new HtmlNext("/admin/failureurl/error.jsp"); + + /** The path of the HTML: /admin/failureurl/index.jsp */ + HtmlNext path_AdminFailureurl_IndexJsp = new HtmlNext("/admin/failureurl/index.jsp"); + + /** The path of the HTML: /admin/fileauthentication/confirm.jsp */ + HtmlNext path_AdminFileauthentication_ConfirmJsp = new HtmlNext("/admin/fileauthentication/confirm.jsp"); + + /** The path of the HTML: /admin/fileauthentication/edit.jsp */ + HtmlNext path_AdminFileauthentication_EditJsp = new HtmlNext("/admin/fileauthentication/edit.jsp"); + + /** The path of the HTML: /admin/fileauthentication/error.jsp */ + HtmlNext path_AdminFileauthentication_ErrorJsp = new HtmlNext("/admin/fileauthentication/error.jsp"); + + /** The path of the HTML: /admin/fileauthentication/index.jsp */ + HtmlNext path_AdminFileauthentication_IndexJsp = new HtmlNext("/admin/fileauthentication/index.jsp"); + + /** The path of the HTML: /admin/fileconfig/confirm.jsp */ + HtmlNext path_AdminFileconfig_ConfirmJsp = new HtmlNext("/admin/fileconfig/confirm.jsp"); + + /** The path of the HTML: /admin/fileconfig/edit.jsp */ + HtmlNext path_AdminFileconfig_EditJsp = new HtmlNext("/admin/fileconfig/edit.jsp"); + + /** The path of the HTML: /admin/fileconfig/error.jsp */ + HtmlNext path_AdminFileconfig_ErrorJsp = new HtmlNext("/admin/fileconfig/error.jsp"); + + /** The path of the HTML: /admin/fileconfig/index.jsp */ + HtmlNext path_AdminFileconfig_IndexJsp = new HtmlNext("/admin/fileconfig/index.jsp"); + + /** The path of the HTML: /admin/group/confirm.jsp */ + HtmlNext path_AdminGroup_ConfirmJsp = new HtmlNext("/admin/group/confirm.jsp"); + + /** The path of the HTML: /admin/group/edit.jsp */ + HtmlNext path_AdminGroup_EditJsp = new HtmlNext("/admin/group/edit.jsp"); + + /** The path of the HTML: /admin/group/error.jsp */ + HtmlNext path_AdminGroup_ErrorJsp = new HtmlNext("/admin/group/error.jsp"); + + /** The path of the HTML: /admin/group/index.jsp */ + HtmlNext path_AdminGroup_IndexJsp = new HtmlNext("/admin/group/index.jsp"); + + /** The path of the HTML: /admin/joblog/confirm.jsp */ + HtmlNext path_AdminJoblog_ConfirmJsp = new HtmlNext("/admin/joblog/confirm.jsp"); + + /** The path of the HTML: /admin/joblog/error.jsp */ + HtmlNext path_AdminJoblog_ErrorJsp = new HtmlNext("/admin/joblog/error.jsp"); + + /** The path of the HTML: /admin/joblog/index.jsp */ + HtmlNext path_AdminJoblog_IndexJsp = new HtmlNext("/admin/joblog/index.jsp"); + + /** The path of the HTML: /admin/keymatch/confirm.jsp */ + HtmlNext path_AdminKeymatch_ConfirmJsp = new HtmlNext("/admin/keymatch/confirm.jsp"); + + /** The path of the HTML: /admin/keymatch/edit.jsp */ + HtmlNext path_AdminKeymatch_EditJsp = new HtmlNext("/admin/keymatch/edit.jsp"); + + /** The path of the HTML: /admin/keymatch/error.jsp */ + HtmlNext path_AdminKeymatch_ErrorJsp = new HtmlNext("/admin/keymatch/error.jsp"); + + /** The path of the HTML: /admin/keymatch/index.jsp */ + HtmlNext path_AdminKeymatch_IndexJsp = new HtmlNext("/admin/keymatch/index.jsp"); + + /** The path of the HTML: /admin/labeltype/confirm.jsp */ + HtmlNext path_AdminLabeltype_ConfirmJsp = new HtmlNext("/admin/labeltype/confirm.jsp"); + + /** The path of the HTML: /admin/labeltype/edit.jsp */ + HtmlNext path_AdminLabeltype_EditJsp = new HtmlNext("/admin/labeltype/edit.jsp"); + + /** The path of the HTML: /admin/labeltype/error.jsp */ + HtmlNext path_AdminLabeltype_ErrorJsp = new HtmlNext("/admin/labeltype/error.jsp"); + + /** The path of the HTML: /admin/labeltype/index.jsp */ + HtmlNext path_AdminLabeltype_IndexJsp = new HtmlNext("/admin/labeltype/index.jsp"); + + /** The path of the HTML: /admin/log/index.jsp */ + HtmlNext path_AdminLog_IndexJsp = new HtmlNext("/admin/log/index.jsp"); + + /** The path of the HTML: /admin/overlappinghost/confirm.jsp */ + HtmlNext path_AdminOverlappinghost_ConfirmJsp = new HtmlNext("/admin/overlappinghost/confirm.jsp"); + + /** The path of the HTML: /admin/overlappinghost/edit.jsp */ + HtmlNext path_AdminOverlappinghost_EditJsp = new HtmlNext("/admin/overlappinghost/edit.jsp"); + + /** The path of the HTML: /admin/overlappinghost/error.jsp */ + HtmlNext path_AdminOverlappinghost_ErrorJsp = new HtmlNext("/admin/overlappinghost/error.jsp"); + + /** The path of the HTML: /admin/overlappinghost/index.jsp */ + HtmlNext path_AdminOverlappinghost_IndexJsp = new HtmlNext("/admin/overlappinghost/index.jsp"); + + /** The path of the HTML: /admin/pathmapping/confirm.jsp */ + HtmlNext path_AdminPathmapping_ConfirmJsp = new HtmlNext("/admin/pathmapping/confirm.jsp"); + + /** The path of the HTML: /admin/pathmapping/edit.jsp */ + HtmlNext path_AdminPathmapping_EditJsp = new HtmlNext("/admin/pathmapping/edit.jsp"); + + /** The path of the HTML: /admin/pathmapping/error.jsp */ + HtmlNext path_AdminPathmapping_ErrorJsp = new HtmlNext("/admin/pathmapping/error.jsp"); + + /** The path of the HTML: /admin/pathmapping/index.jsp */ + HtmlNext path_AdminPathmapping_IndexJsp = new HtmlNext("/admin/pathmapping/index.jsp"); + + /** The path of the HTML: /admin/requestheader/confirm.jsp */ + HtmlNext path_AdminRequestheader_ConfirmJsp = new HtmlNext("/admin/requestheader/confirm.jsp"); + + /** The path of the HTML: /admin/requestheader/edit.jsp */ + HtmlNext path_AdminRequestheader_EditJsp = new HtmlNext("/admin/requestheader/edit.jsp"); + + /** The path of the HTML: /admin/requestheader/error.jsp */ + HtmlNext path_AdminRequestheader_ErrorJsp = new HtmlNext("/admin/requestheader/error.jsp"); + + /** The path of the HTML: /admin/requestheader/index.jsp */ + HtmlNext path_AdminRequestheader_IndexJsp = new HtmlNext("/admin/requestheader/index.jsp"); + + /** The path of the HTML: /admin/role/confirm.jsp */ + HtmlNext path_AdminRole_ConfirmJsp = new HtmlNext("/admin/role/confirm.jsp"); + + /** The path of the HTML: /admin/role/edit.jsp */ + HtmlNext path_AdminRole_EditJsp = new HtmlNext("/admin/role/edit.jsp"); + + /** The path of the HTML: /admin/role/error.jsp */ + HtmlNext path_AdminRole_ErrorJsp = new HtmlNext("/admin/role/error.jsp"); + + /** The path of the HTML: /admin/role/index.jsp */ + HtmlNext path_AdminRole_IndexJsp = new HtmlNext("/admin/role/index.jsp"); + + /** The path of the HTML: /admin/roletype/confirm.jsp */ + HtmlNext path_AdminRoletype_ConfirmJsp = new HtmlNext("/admin/roletype/confirm.jsp"); + + /** The path of the HTML: /admin/roletype/edit.jsp */ + HtmlNext path_AdminRoletype_EditJsp = new HtmlNext("/admin/roletype/edit.jsp"); + + /** The path of the HTML: /admin/roletype/error.jsp */ + HtmlNext path_AdminRoletype_ErrorJsp = new HtmlNext("/admin/roletype/error.jsp"); + + /** The path of the HTML: /admin/roletype/index.jsp */ + HtmlNext path_AdminRoletype_IndexJsp = new HtmlNext("/admin/roletype/index.jsp"); + + /** The path of the HTML: /admin/scheduledjob/confirm.jsp */ + HtmlNext path_AdminScheduledjob_ConfirmJsp = new HtmlNext("/admin/scheduledjob/confirm.jsp"); + + /** The path of the HTML: /admin/scheduledjob/edit.jsp */ + HtmlNext path_AdminScheduledjob_EditJsp = new HtmlNext("/admin/scheduledjob/edit.jsp"); + + /** The path of the HTML: /admin/scheduledjob/error.jsp */ + HtmlNext path_AdminScheduledjob_ErrorJsp = new HtmlNext("/admin/scheduledjob/error.jsp"); + + /** The path of the HTML: /admin/scheduledjob/index.jsp */ + HtmlNext path_AdminScheduledjob_IndexJsp = new HtmlNext("/admin/scheduledjob/index.jsp"); + + /** The path of the HTML: /admin/searchlist/confirmDelete.jsp */ + HtmlNext path_AdminSearchlist_ConfirmDeleteJsp = new HtmlNext("/admin/searchlist/confirmDelete.jsp"); + + /** The path of the HTML: /admin/searchlist/index.jsp */ + HtmlNext path_AdminSearchlist_IndexJsp = new HtmlNext("/admin/searchlist/index.jsp"); + + /** The path of the HTML: /admin/suggestbadword/confirm.jsp */ + HtmlNext path_AdminSuggestbadword_ConfirmJsp = new HtmlNext("/admin/suggestbadword/confirm.jsp"); + + /** The path of the HTML: /admin/suggestbadword/download.jsp */ + HtmlNext path_AdminSuggestbadword_DownloadJsp = new HtmlNext("/admin/suggestbadword/download.jsp"); + + /** The path of the HTML: /admin/suggestbadword/edit.jsp */ + HtmlNext path_AdminSuggestbadword_EditJsp = new HtmlNext("/admin/suggestbadword/edit.jsp"); + + /** The path of the HTML: /admin/suggestbadword/error.jsp */ + HtmlNext path_AdminSuggestbadword_ErrorJsp = new HtmlNext("/admin/suggestbadword/error.jsp"); + + /** The path of the HTML: /admin/suggestbadword/index.jsp */ + HtmlNext path_AdminSuggestbadword_IndexJsp = new HtmlNext("/admin/suggestbadword/index.jsp"); + + /** The path of the HTML: /admin/suggestbadword/upload.jsp */ + HtmlNext path_AdminSuggestbadword_UploadJsp = new HtmlNext("/admin/suggestbadword/upload.jsp"); + + /** The path of the HTML: /admin/suggestelevateword/confirm.jsp */ + HtmlNext path_AdminSuggestelevateword_ConfirmJsp = new HtmlNext("/admin/suggestelevateword/confirm.jsp"); + + /** The path of the HTML: /admin/suggestelevateword/download.jsp */ + HtmlNext path_AdminSuggestelevateword_DownloadJsp = new HtmlNext("/admin/suggestelevateword/download.jsp"); + + /** The path of the HTML: /admin/suggestelevateword/edit.jsp */ + HtmlNext path_AdminSuggestelevateword_EditJsp = new HtmlNext("/admin/suggestelevateword/edit.jsp"); + + /** The path of the HTML: /admin/suggestelevateword/error.jsp */ + HtmlNext path_AdminSuggestelevateword_ErrorJsp = new HtmlNext("/admin/suggestelevateword/error.jsp"); + + /** The path of the HTML: /admin/suggestelevateword/index.jsp */ + HtmlNext path_AdminSuggestelevateword_IndexJsp = new HtmlNext("/admin/suggestelevateword/index.jsp"); + + /** The path of the HTML: /admin/suggestelevateword/upload.jsp */ + HtmlNext path_AdminSuggestelevateword_UploadJsp = new HtmlNext("/admin/suggestelevateword/upload.jsp"); + + /** The path of the HTML: /admin/system/index.jsp */ + HtmlNext path_AdminSystem_IndexJsp = new HtmlNext("/admin/system/index.jsp"); + + /** The path of the HTML: /admin/systeminfo/index.jsp */ + HtmlNext path_AdminSysteminfo_IndexJsp = new HtmlNext("/admin/systeminfo/index.jsp"); + + /** The path of the HTML: /admin/user/confirm.jsp */ + HtmlNext path_AdminUser_ConfirmJsp = new HtmlNext("/admin/user/confirm.jsp"); + + /** The path of the HTML: /admin/user/edit.jsp */ + HtmlNext path_AdminUser_EditJsp = new HtmlNext("/admin/user/edit.jsp"); + + /** The path of the HTML: /admin/user/error.jsp */ + HtmlNext path_AdminUser_ErrorJsp = new HtmlNext("/admin/user/error.jsp"); + + /** The path of the HTML: /admin/user/index.jsp */ + HtmlNext path_AdminUser_IndexJsp = new HtmlNext("/admin/user/index.jsp"); + + /** The path of the HTML: /admin/webauthentication/confirm.jsp */ + HtmlNext path_AdminWebauthentication_ConfirmJsp = new HtmlNext("/admin/webauthentication/confirm.jsp"); + + /** The path of the HTML: /admin/webauthentication/edit.jsp */ + HtmlNext path_AdminWebauthentication_EditJsp = new HtmlNext("/admin/webauthentication/edit.jsp"); + + /** The path of the HTML: /admin/webauthentication/error.jsp */ + HtmlNext path_AdminWebauthentication_ErrorJsp = new HtmlNext("/admin/webauthentication/error.jsp"); + + /** The path of the HTML: /admin/webauthentication/index.jsp */ + HtmlNext path_AdminWebauthentication_IndexJsp = new HtmlNext("/admin/webauthentication/index.jsp"); + + /** The path of the HTML: /admin/webconfig/confirm.jsp */ + HtmlNext path_AdminWebconfig_ConfirmJsp = new HtmlNext("/admin/webconfig/confirm.jsp"); + + /** The path of the HTML: /admin/webconfig/edit.jsp */ + HtmlNext path_AdminWebconfig_EditJsp = new HtmlNext("/admin/webconfig/edit.jsp"); + + /** The path of the HTML: /admin/webconfig/error.jsp */ + HtmlNext path_AdminWebconfig_ErrorJsp = new HtmlNext("/admin/webconfig/error.jsp"); + + /** The path of the HTML: /admin/webconfig/index.jsp */ + HtmlNext path_AdminWebconfig_IndexJsp = new HtmlNext("/admin/webconfig/index.jsp"); + + /** The path of the HTML: /admin/wizard/crawlingConfig.jsp */ + HtmlNext path_AdminWizard_CrawlingConfigJsp = new HtmlNext("/admin/wizard/crawlingConfig.jsp"); + + /** The path of the HTML: /admin/wizard/error.jsp */ + HtmlNext path_AdminWizard_ErrorJsp = new HtmlNext("/admin/wizard/error.jsp"); + + /** The path of the HTML: /admin/wizard/index.jsp */ + HtmlNext path_AdminWizard_IndexJsp = new HtmlNext("/admin/wizard/index.jsp"); + + /** The path of the HTML: /admin/wizard/startCrawling.jsp */ + HtmlNext path_AdminWizard_StartCrawlingJsp = new HtmlNext("/admin/wizard/startCrawling.jsp"); + + /** The path of the HTML: /error/badRequest.jsp */ + HtmlNext path_Error_BadRequestJsp = new HtmlNext("/error/badRequest.jsp"); + + /** The path of the HTML: /error/error_message.jsp */ + HtmlNext path_Error_ErrorMessageJsp = new HtmlNext("/error/error_message.jsp"); + + /** The path of the HTML: /error/footer.jsp */ + HtmlNext path_Error_FooterJsp = new HtmlNext("/error/footer.jsp"); + + /** The path of the HTML: /error/header.jsp */ + HtmlNext path_Error_HeaderJsp = new HtmlNext("/error/header.jsp"); + + /** The path of the HTML: /error/notFound.jsp */ + HtmlNext path_Error_NotFoundJsp = new HtmlNext("/error/notFound.jsp"); + + /** The path of the HTML: /error/redirect.jsp */ + HtmlNext path_Error_RedirectJsp = new HtmlNext("/error/redirect.jsp"); + + /** The path of the HTML: /error/system.jsp */ + HtmlNext path_Error_SystemJsp = new HtmlNext("/error/system.jsp"); + + /** The path of the HTML: /error.jsp */ + HtmlNext path_ErrorJsp = new HtmlNext("/error.jsp"); + + /** The path of the HTML: /footer.jsp */ + HtmlNext path_FooterJsp = new HtmlNext("/footer.jsp"); + + /** The path of the HTML: /header.jsp */ + HtmlNext path_HeaderJsp = new HtmlNext("/header.jsp"); + + /** The path of the HTML: /help.jsp */ + HtmlNext path_HelpJsp = new HtmlNext("/help.jsp"); + + /** The path of the HTML: /index.jsp */ + HtmlNext path_IndexJsp = new HtmlNext("/index.jsp"); + + /** The path of the HTML: /login/footer.jsp */ + HtmlNext path_Login_FooterJsp = new HtmlNext("/login/footer.jsp"); + + /** The path of the HTML: /login/header.jsp */ + HtmlNext path_Login_HeaderJsp = new HtmlNext("/login/header.jsp"); + + /** The path of the HTML: /login/index.jsp */ + HtmlNext path_Login_IndexJsp = new HtmlNext("/login/index.jsp"); + + /** The path of the HTML: /login/logout.jsp */ + HtmlNext path_Login_LogoutJsp = new HtmlNext("/login/logout.jsp"); + + /** The path of the HTML: /search.jsp */ + HtmlNext path_SearchJsp = new HtmlNext("/search.jsp"); + + /** The path of the HTML: /searchNoResult.jsp */ + HtmlNext path_SearchNoResultJsp = new HtmlNext("/searchNoResult.jsp"); + + /** The path of the HTML: /searchResults.jsp */ + HtmlNext path_SearchResultsJsp = new HtmlNext("/searchResults.jsp"); +} diff --git a/src/main/java/org/codelibs/fess/mylasta/action/FessLabels.java b/src/main/java/org/codelibs/fess/mylasta/action/FessLabels.java new file mode 100644 index 000000000..4b6cec436 --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/action/FessLabels.java @@ -0,0 +1,3551 @@ +package org.codelibs.fess.mylasta.action; + +import org.lastaflute.web.ruts.message.ActionMessages; + +/** + * The keys for message. + * @author FreeGen + */ +public class FessLabels extends ActionMessages { + + /** The serial version UID for object serialization. (Default) */ + private static final long serialVersionUID = 1L; + + /** The key of the message: Realm */ + public static final String LABELS_AUTH_REALM = "{labels.authRealm}"; + + /** The key of the message: Status */ + public static final String LABELS_AVAILABLE = "{labels.available}"; + + /** The key of the message: Created by */ + public static final String LABELS_CREATED_BY = "{labels.createdBy}"; + + /** The key of the message: Created Time */ + public static final String LABELS_CREATED_TIME = "{labels.createdTime}"; + + /** The key of the message: Deleted by */ + public static final String LABELS_DELETED_BY = "{labels.deletedBy}"; + + /** The key of the message: Deleted Time */ + public static final String LABELS_DELETED_TIME = "{labels.deletedTime}"; + + /** The key of the message: Depth */ + public static final String LABELS_DEPTH = "{labels.depth}"; + + /** The key of the message: Excluded Paths For Crawling */ + public static final String LABELS_EXCLUDED_PATHS = "{labels.excludedPaths}"; + + /** The key of the message: Excluded URLs For Crawling */ + public static final String LABELS_EXCLUDED_URLS = "{labels.excludedUrls}"; + + /** The key of the message: Excluded Paths For Indexing */ + public static final String LABELS_EXCLUDED_DOC_PATHS = "{labels.excludedDocPaths}"; + + /** The key of the message: Excluded URLs For Indexing */ + public static final String LABELS_EXCLUDED_DOC_URLS = "{labels.excludedDocUrls}"; + + /** The key of the message: Hostname */ + public static final String LABELS_HOSTNAME = "{labels.hostname}"; + + /** The key of the message: ID */ + public static final String LABELS_ID = "{labels.id}"; + + /** The key of the message: Included Paths For Crawling */ + public static final String LABELS_INCLUDED_PATHS = "{labels.includedPaths}"; + + /** The key of the message: Included URLs For Crawling */ + public static final String LABELS_INCLUDED_URLS = "{labels.includedUrls}"; + + /** The key of the message: Included Paths For Indexing */ + public static final String LABELS_INCLUDED_DOC_PATHS = "{labels.includedDocPaths}"; + + /** The key of the message: Included URLs For Indexing */ + public static final String LABELS_INCLUDED_DOC_URLS = "{labels.includedDocUrls}"; + + /** The key of the message: Max Access Count */ + public static final String LABELS_MAX_ACCESS_COUNT = "{labels.maxAccessCount}"; + + /** The key of the message: Name */ + public static final String LABELS_NAME = "{labels.name}"; + + /** The key of the message: Num of Thread */ + public static final String LABELS_NUM_OF_THREAD = "{labels.numOfThread}"; + + /** The key of the message: Overlapping Name */ + public static final String LABELS_OVERLAPPING_NAME = "{labels.overlappingName}"; + + /** The key of the message: Page Number */ + public static final String LABELS_PAGE_NUMBER = "{labels.pageNumber}"; + + /** The key of the message: Password */ + public static final String LABELS_PASSWORD = "{labels.password}"; + + /** The key of the message: Paths */ + public static final String LABELS_PATHS = "{labels.paths}"; + + /** The key of the message: Port */ + public static final String LABELS_PORT = "{labels.port}"; + + /** The key of the message: Regexp. */ + public static final String LABELS_REGEX = "{labels.regex}"; + + /** The key of the message: Regular Name */ + public static final String LABELS_REGULAR_NAME = "{labels.regularName}"; + + /** The key of the message: Replacement */ + public static final String LABELS_REPLACEMENT = "{labels.replacement}"; + + /** The key of the message: Session ID */ + public static final String LABELS_SESSION_ID = "{labels.sessionId}"; + + /** The key of the message: Display Order */ + public static final String LABELS_SORT_ORDER = "{labels.sortOrder}"; + + /** The key of the message: Updated by */ + public static final String LABELS_UPDATED_BY = "{labels.updatedBy}"; + + /** The key of the message: Updated Time */ + public static final String LABELS_UPDATED_TIME = "{labels.updatedTime}"; + + /** The key of the message: URLs */ + public static final String LABELS_URLS = "{labels.urls}"; + + /** The key of the message: User Agent */ + public static final String LABELS_USER_AGENT = "{labels.userAgent}"; + + /** The key of the message: Username */ + public static final String LABELS_USERNAME = "{labels.username}"; + + /** The key of the message: Value */ + public static final String LABELS_VALUE = "{labels.value}"; + + /** The key of the message: Version No. */ + public static final String LABELS_VERSION_NO = "{labels.versionNo}"; + + /** The key of the message: Log File Name */ + public static final String LABELS_LOG_FILE_NAME = "{labels.logFileName}"; + + /** The key of the message: Schedule */ + public static final String LABELS_CRON_EXPRESSION = "{labels.cronExpression}"; + + /** The key of the message: Remove Index Before Days */ + public static final String LABELS_DAY_FOR_CLEANUP = "{labels.dayForCleanup}"; + + /** The key of the message: Commit per Document Size */ + public static final String LABELS_COMMIT_PER_COUNT = "{labels.commitPerCount}"; + + /** The key of the message: Num of Simultaneous Crawler Config */ + public static final String LABELS_CRAWLING_THREAD_COUNT = "{labels.crawlingThreadCount}"; + + /** The key of the message: Snapshot Path */ + public static final String LABELS_SNAPSHOT_PATH = "{labels.snapshotPath}"; + + /** The key of the message: Boost */ + public static final String LABELS_BOOST = "{labels.boost}"; + + /** The key of the message: File */ + public static final String LABELS_UPLOADED_FILE = "{labels.uploadedFile}"; + + /** The key of the message: Use Schedule */ + public static final String LABELS_SCHEDULE_ENABLED = "{labels.scheduleEnabled}"; + + /** The key of the message: Month */ + public static final String LABELS_SCHEDULE_MONTH = "{labels.scheduleMonth}"; + + /** The key of the message: Date */ + public static final String LABELS_SCHEDULE_DATE = "{labels.scheduleDate}"; + + /** The key of the message: Hours */ + public static final String LABELS_SCHEDULE_HOUR = "{labels.scheduleHour}"; + + /** The key of the message: Minutes */ + public static final String LABELS_SCHEDULE_MIN = "{labels.scheduleMin}"; + + /** The key of the message: Name */ + public static final String LABELS_CRAWLING_CONFIG_NAME = "{labels.crawlingConfigName}"; + + /** The key of the message: Crawling Path */ + public static final String LABELS_CRAWLING_CONFIG_PATH = "{labels.crawlingConfigPath}"; + + /** The key of the message: URL */ + public static final String LABELS_DELETE_URL = "{labels.deleteUrl}"; + + /** The key of the message: Process Type */ + public static final String LABELS_PROCESS_TYPE = "{labels.processType}"; + + /** The key of the message: Parameters */ + public static final String LABELS_PARAMETERS = "{labels.parameters}"; + + /** The key of the message: Upaload File */ + public static final String LABELS_DESIGN_FILE = "{labels.designFile}"; + + /** The key of the message: Access Type */ + public static final String LABELS_ACCESS_TYPE = "{labels.accessType}"; + + /** The key of the message: Additional Parameters */ + public static final String LABELS_ADDITIONAL = "{labels.additional}"; + + /** The key of the message: Additional Query Parameters */ + public static final String LABELS_APPEND_QUERY_PARAMETER = "{labels.appendQueryParameter}"; + + /** The key of the message: callback */ + public static final String LABELS_CALLBACK = "{labels.callback}"; + + /** The key of the message: Client IP */ + public static final String LABELS_CLIENT_IP = "{labels.clientIp}"; + + /** The key of the message: User ID */ + public static final String LABELS_CODE = "{labels.code}"; + + /** The key of the message: Config ID */ + public static final String LABELS_CONFIG_ID = "{labels.configId}"; + + /** The key of the message: Config Parameters */ + public static final String LABELS_CONFIG_PARAMETER = "{labels.configParameter}"; + + /** The key of the message: Content */ + public static final String LABELS_CONTENT = "{labels.content}"; + + /** The key of the message: CSV Encoding */ + public static final String LABELS_CSV_ENCODING = "{labels.csvEncoding}"; + + /** The key of the message: CSV Encoding */ + public static final String LABELS_CSV_FILE_ENCODING = "{labels.csvFileEncoding}"; + + /** The key of the message: Current Server (Select) */ + public static final String LABELS_CURRENT_SERVER_FOR_SELECT = "{labels.currentServerForSelect}"; + + /** The key of the message: Current Server (Update) */ + public static final String LABELS_CURRENT_SERVER_FOR_UPDATE = "{labels.currentServerForUpdate}"; + + /** The key of the message: Current Server Status (Select) */ + public static final String LABELS_CURRENT_SERVER_STATUS_FOR_SELECT = "{labels.currentServerStatusForSelect}"; + + /** The key of the message: Current Server Status (Update) */ + public static final String LABELS_CURRENT_SERVER_STATUS_FOR_UPDATE = "{labels.currentServerStatusForUpdate}"; + + /** The key of the message: Default Label */ + public static final String LABELS_DEFAULT_LABEL_VALUE = "{labels.defaultLabelValue}"; + + /** The key of the message: File Name */ + public static final String LABELS_DESIGN_FILE_NAME = "{labels.designFileName}"; + + /** The key of the message: Check Last Modified */ + public static final String LABELS_DIFF_CRAWLING = "{labels.diffCrawling}"; + + /** The key of the message: Distance */ + public static final String LABELS_DISTANCE = "{labels.distance}"; + + /** The key of the message: Encoding */ + public static final String LABELS_ENCODING = "{labels.encoding}"; + + /** The key of the message: Error Count */ + public static final String LABELS_ERROR_COUNT = "{labels.errorCount}"; + + /** The key of the message: Error Log */ + public static final String LABELS_ERROR_LOG = "{labels.errorLog}"; + + /** The key of the message: Error Name */ + public static final String LABELS_ERROR_NAME = "{labels.errorName}"; + + /** The key of the message: Expired */ + public static final String LABELS_EXPIRED_TIME = "{labels.expiredTime}"; + + /** The key of the message: Failure Count */ + public static final String LABELS_FAILURE_COUNT_THRESHOLD = "{labels.failureCountThreshold}"; + + /** The key of the message: Config Name */ + public static final String LABELS_FILE_CONFIG_NAME = "{labels.fileConfigName}"; + + /** The key of the message: FS Config Name */ + public static final String LABELS_FILE_CONFIG_ID = "{labels.fileConfigId}"; + + /** The key of the message: File name */ + public static final String LABELS_FILE_NAME = "{labels.fileName}"; + + /** The key of the message: Solr Group */ + public static final String LABELS_GROUP_NAME = "{labels.groupName}"; + + /** The key of the message: Handler Name */ + public static final String LABELS_HANDLER_NAME = "{labels.handlerName}"; + + /** The key of the message: Parameters */ + public static final String LABELS_HANDLER_PARAMETER = "{labels.handlerParameter}"; + + /** The key of the message: Scripts */ + public static final String LABELS_HANDLER_SCRIPT = "{labels.handlerScript}"; + + /** The key of the message: Hit Count */ + public static final String LABELS_HIT_COUNT = "{labels.hitCount}"; + + /** The key of the message: Popular words */ + public static final String LABELS_HOT_SEARCH_WORD = "{labels.hotSearchWord}"; + + /** The key of the message: Ignored Failure Type */ + public static final String LABELS_IGNORE_FAILURE_TYPE = "{labels.ignoreFailureType}"; + + /** The key of the message: Interval */ + public static final String LABELS_INTERVAL_TIME = "{labels.intervalTime}"; + + /** The key of the message: Last Accessed */ + public static final String LABELS_LAST_ACCESS_TIME = "{labels.lastAccessTime}"; + + /** The key of the message: Latitude */ + public static final String LABELS_LATITUDE = "{labels.latitude}"; + + /** The key of the message: Longitude */ + public static final String LABELS_LONGITUDE = "{labels.longitude}"; + + /** The key of the message: Notification To */ + public static final String LABELS_NOTIFICATION_TO = "{labels.notificationTo}"; + + /** The key of the message: Num */ + public static final String LABELS_NUM = "{labels.num}"; + + /** The key of the message: Overwrite */ + public static final String LABELS_OVERWRITE = "{labels.overwrite}"; + + /** The key of the message: Page Numger */ + public static final String LABELS_PN = "{labels.pn}"; + + /** The key of the message: Scheme */ + public static final String LABELS_PROTOCOL_SCHEME = "{labels.protocolScheme}"; + + /** The key of the message: Purge By Bots */ + public static final String LABELS_PURGE_BY_BOTS = "{labels.purgeByBots}"; + + /** The key of the message: Purge Search Log */ + public static final String LABELS_PURGE_SEARCH_LOG_DAY = "{labels.purgeSearchLogDay}"; + + /** The key of the message: Query */ + public static final String LABELS_QUERY = "{labels.query}"; + + /** The key of the message: Query ID */ + public static final String LABELS_QUERY_ID = "{labels.queryId}"; + + /** The key of the message: Offset */ + public static final String LABELS_QUERY_OFFSET = "{labels.queryOffset}"; + + /** The key of the message: Page Size */ + public static final String LABELS_QUERY_PAGE_SIZE = "{labels.queryPageSize}"; + + /** The key of the message: Range */ + public static final String LABELS_RANGE = "{labels.range}"; + + /** The key of the message: Referrer */ + public static final String LABELS_REFERER = "{labels.referer}"; + + /** The key of the message: Requested Time */ + public static final String LABELS_REQUESTED_TIME = "{labels.requestedTime}"; + + /** The key of the message: Response Time */ + public static final String LABELS_RESPONSE_TIME = "{labels.responseTime}"; + + /** The key of the message: Return Path */ + public static final String LABELS_RETURN_PATH = "{labels.returnPath}"; + + /** The key of the message: rt */ + public static final String LABELS_RT = "{labels.rt}"; + + /** The key of the message: Schedule */ + public static final String LABELS_SCHEDULE_DAY = "{labels.scheduleDay}"; + + /** The key of the message: Search Log */ + public static final String LABELS_SEARCH_LOG = "{labels.searchLog}"; + + /** The key of the message: Search Word */ + public static final String LABELS_SEARCH_WORD = "{labels.searchWord}"; + + /** The key of the message: Server Rotation */ + public static final String LABELS_SERVER_ROTATION = "{labels.serverRotation}"; + + /** The key of the message: Index Replication */ + public static final String LABELS_SNAPSHOT_REPLICATION = "{labels.snapshotReplication}"; + + /** The key of the message: Solr Instance Name */ + public static final String LABELS_SOLR_INSTANCE_NAME = "{labels.solrInstanceName}"; + + /** The key of the message: Sort */ + public static final String LABELS_SORT = "{labels.sort}"; + + /** The key of the message: Start Pos */ + public static final String LABELS_START = "{labels.start}"; + + /** The key of the message: Supported Search */ + public static final String LABELS_SUPPORTED_SEARCH = "{labels.supportedSearch}"; + + /** The key of the message: Thread Name */ + public static final String LABELS_THREAD_NAME = "{labels.threadName}"; + + /** The key of the message: Type */ + public static final String LABELS_TYPE = "{labels.type}"; + + /** The key of the message: URL */ + public static final String LABELS_U = "{labels.u}"; + + /** The key of the message: URI */ + public static final String LABELS_URI = "{labels.uri}"; + + /** The key of the message: URL */ + public static final String LABELS_URL = "{labels.url}"; + + /** The key of the message: Favorite Log */ + public static final String LABELS_USER_FAVORITE = "{labels.userFavorite}"; + + /** The key of the message: User ID */ + public static final String LABELS_USER_ID = "{labels.userId}"; + + /** The key of the message: User Info */ + public static final String LABELS_USER_INFO = "{labels.userInfo}"; + + /** The key of the message: User ID */ + public static final String LABELS_USER_SESSION_ID = "{labels.userSessionId}"; + + /** The key of the message: JSON Response */ + public static final String LABELS_WEB_API_JSON = "{labels.webApiJson}"; + + /** The key of the message: XML Response */ + public static final String LABELS_WEB_API_XML = "{labels.webApiXml}"; + + /** The key of the message: ID */ + public static final String LABELS_WEB_CONFIG_ID = "{labels.webConfigId}"; + + /** The key of the message: Config Name */ + public static final String LABELS_WEB_CONFIG_NAME = "{labels.webConfigName}"; + + /** The key of the message: All Languages */ + public static final String LABELS_ALL_LANGUAGES = "{labels.allLanguages}"; + + /** The key of the message: Dictionary ID */ + public static final String LABELS_DICT_ID = "{labels.dictId}"; + + /** The key of the message: Document ID */ + public static final String LABELS_DOC_ID = "{labels.docId}"; + + /** The key of the message: End Time */ + public static final String LABELS_END_TIME = "{labels.endTime}"; + + /** The key of the message: fn */ + public static final String LABELS_FN = "{labels.fn}"; + + /** The key of the message: hq */ + public static final String LABELS_HQ = "{labels.hq}"; + + /** The key of the message: Source */ + public static final String LABELS_INPUTS = "{labels.inputs}"; + + /** The key of the message: Logging */ + public static final String LABELS_JOB_LOGGING = "{labels.jobLogging}"; + + /** The key of the message: Name */ + public static final String LABELS_JOB_NAME = "{labels.jobName}"; + + /** The key of the message: Status */ + public static final String LABELS_JOB_STATUS = "{labels.jobStatus}"; + + /** The key of the message: lang */ + public static final String LABELS_LANG = "{labels.lang}"; + + /** The key of the message: Target */ + public static final String LABELS_OUTPUTS = "{labels.outputs}"; + + /** The key of the message: POS */ + public static final String LABELS_POS = "{labels.pos}"; + + /** The key of the message: Purge Job Log Before */ + public static final String LABELS_PURGE_JOB_LOG_DAY = "{labels.purgeJobLogDay}"; + + /** The key of the message: Purge User Before */ + public static final String LABELS_PURGE_USER_INFO_DAY = "{labels.purgeUserInfoDay}"; + + /** The key of the message: Reading */ + public static final String LABELS_READING = "{labels.reading}"; + + /** The key of the message: Role ID */ + public static final String LABELS_ROLE_TYPE_IDS = "{labels.roleTypeIds}"; + + /** The key of the message: Script */ + public static final String LABELS_SCRIPT_DATA = "{labels.scriptData}"; + + /** The key of the message: Result */ + public static final String LABELS_SCRIPT_RESULT = "{labels.scriptResult}"; + + /** The key of the message: Executor */ + public static final String LABELS_SCRIPT_TYPE = "{labels.scriptType}"; + + /** The key of the message: Segmentation */ + public static final String LABELS_SEGMENTATION = "{labels.segmentation}"; + + /** The key of the message: Start Time */ + public static final String LABELS_START_TIME = "{labels.startTime}"; + + /** The key of the message: Target */ + public static final String LABELS_TARGET = "{labels.target}"; + + /** The key of the message: Token */ + public static final String LABELS_TOKEN = "{labels.token}"; + + /** The key of the message: Use ACL as Role */ + public static final String LABELS_USE_ACL_AS_ROLE = "{labels.useAclAsRole}"; + + /** The key of the message: Synonym File */ + public static final String LABELS_SYNONYM_FILE = "{labels.synonymFile}"; + + /** The key of the message: UserDict File */ + public static final String LABELS_USER_DICT_FILE = "{labels.userDictFile}"; + + /** The key of the message: Additional Word File */ + public static final String LABELS_SUGGEST_ELEVATE_WORD_FILE = "{labels.suggestElevateWordFile}"; + + /** The key of the message: Bad Word File */ + public static final String LABELS_SUGGEST_BAD_WORD_FILE = "{labels.suggestBadWordFile}"; + + /** The key of the message: System */ + public static final String LABELS_menu_system = "{labels.menu_system}"; + + /** The key of the message: » Wizard */ + public static final String LABELS_MENU_WIZARD = "{labels.menu.wizard}"; + + /** The key of the message: » General */ + public static final String LABELS_MENU_crawl_config = "{labels.menu.crawl_config}"; + + /** The key of the message: » Scheduled Jobs */ + public static final String LABELS_MENU_scheduled_job_config = "{labels.menu.scheduled_job_config}"; + + /** The key of the message: » System */ + public static final String LABELS_MENU_system_config = "{labels.menu.system_config}"; + + /** The key of the message: » Index */ + public static final String LABELS_MENU_document_config = "{labels.menu.document_config}"; + + /** The key of the message: » Design */ + public static final String LABELS_MENU_DESIGN = "{labels.menu.design}"; + + /** The key of the message: » Dictionary */ + public static final String LABELS_MENU_DICT = "{labels.menu.dict}"; + + /** The key of the message: » Backup/Restore */ + public static final String LABELS_MENU_DATA = "{labels.menu.data}"; + + /** The key of the message: Crawler */ + public static final String LABELS_menu_crawl = "{labels.menu_crawl}"; + + /** The key of the message: » Web */ + public static final String LABELS_MENU_WEB = "{labels.menu.web}"; + + /** The key of the message: » File System */ + public static final String LABELS_MENU_file_system = "{labels.menu.file_system}"; + + /** The key of the message: » Data Store */ + public static final String LABELS_MENU_data_store = "{labels.menu.data_store}"; + + /** The key of the message: » Label */ + public static final String LABELS_MENU_label_type = "{labels.menu.label_type}"; + + /** The key of the message: » Key Match */ + public static final String LABELS_MENU_key_match = "{labels.menu.key_match}"; + + /** The key of the message: » Doc Boost */ + public static final String LABELS_MENU_boost_document_rule = "{labels.menu.boost_document_rule}"; + + /** The key of the message: » Path Mapping */ + public static final String LABELS_MENU_path_mapping = "{labels.menu.path_mapping}"; + + /** The key of the message: » Web Authentication */ + public static final String LABELS_MENU_web_authentication = "{labels.menu.web_authentication}"; + + /** The key of the message: » File Authentication */ + public static final String LABELS_MENU_file_authentication = "{labels.menu.file_authentication}"; + + /** The key of the message: » Request Header */ + public static final String LABELS_MENU_request_header = "{labels.menu.request_header}"; + + /** The key of the message: » Overlapping Host */ + public static final String LABELS_MENU_overlapping_host = "{labels.menu.overlapping_host}"; + + /** The key of the message: » Role */ + public static final String LABELS_MENU_role_type = "{labels.menu.role_type}"; + + /** The key of the message: User */ + public static final String LABELS_menu_user = "{labels.menu_user}"; + + /** The key of the message: User */ + public static final String LABELS_MENU_USER = "{labels.menu.user}"; + + /** The key of the message: Role */ + public static final String LABELS_MENU_ROLE = "{labels.menu.role}"; + + /** The key of the message: Group */ + public static final String LABELS_MENU_GROUP = "{labels.menu.group}"; + + /** The key of the message: Suggest */ + public static final String LABELS_menu_suggest = "{labels.menu_suggest}"; + + /** The key of the message: » Additional Word */ + public static final String LABELS_MENU_suggest_elevate_word = "{labels.menu.suggest_elevate_word}"; + + /** The key of the message: » Bad Word */ + public static final String LABELS_MENU_suggest_bad_word = "{labels.menu.suggest_bad_word}"; + + /** The key of the message: System Info */ + public static final String LABELS_menu_system_log = "{labels.menu_system_log}"; + + /** The key of the message: » Config Info */ + public static final String LABELS_MENU_system_info = "{labels.menu.system_info}"; + + /** The key of the message: » Session Info */ + public static final String LABELS_MENU_session_info = "{labels.menu.session_info}"; + + /** The key of the message: » Log Files */ + public static final String LABELS_MENU_LOG = "{labels.menu.log}"; + + /** The key of the message: » Job Log */ + public static final String LABELS_MENU_JOB_LOG = "{labels.menu.jobLog}"; + + /** The key of the message: » Failure URL */ + public static final String LABELS_MENU_failure_url = "{labels.menu.failure_url}"; + + /** The key of the message: » Search */ + public static final String LABELS_MENU_search_list = "{labels.menu.search_list}"; + + /** The key of the message: User Info */ + public static final String LABELS_menu_user_log = "{labels.menu_user_log}"; + + /** The key of the message: » Search Log */ + public static final String LABELS_MENU_search_log = "{labels.menu.search_log}"; + + /** The key of the message: » Statistics */ + public static final String LABELS_MENU_STATS = "{labels.menu.stats}"; + + /** The key of the message: » Popular URL */ + public static final String LABELS_MENU_FAVORITE_LOG = "{labels.menu.favoriteLog}"; + + /** The key of the message: Logout */ + public static final String LABELS_MENU_LOGOUT = "{labels.menu.logout}"; + + /** The key of the message: Fess */ + public static final String LABELS_HEADER_logo_alt = "{labels.header.logo_alt}"; + + /** The key of the message: Home */ + public static final String LABELS_HEADER_HOME = "{labels.header.home}"; + + /** The key of the message: Help */ + public static final String LABELS_HEADER_HELP = "{labels.header.help}"; + + /** The key of the message: Copyright(C) 2009-2015 CodeLibs Project. All Rights Reserved. */ + public static final String LABELS_FOOTER_COPYRIGHT = "{labels.footer.copyright}"; + + /** The key of the message: Search */ + public static final String LABELS_SEARCH = "{labels.search}"; + + /** The key of the message: Results {2} - {3} of {1} pages for {0} */ + public static final String LABELS_search_result_status = "{labels.search_result_status}"; + + /** The key of the message: ({0} sec) */ + public static final String LABELS_search_result_time = "{labels.search_result_time}"; + + /** The key of the message: Prev */ + public static final String LABELS_prev_page = "{labels.prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_next_page = "{labels.next_page}"; + + /** The key of the message: Your search - {0} - did not match any documents. */ + public static final String LABELS_did_not_match = "{labels.did_not_match}"; + + /** The key of the message: Fess */ + public static final String LABELS_search_header_logo_alt = "{labels.search_header_logo_alt}"; + + /** The key of the message: -- Label -- */ + public static final String LABELS_search_result_noneselect_label = "{labels.search_result_noneselect_label}"; + + /** The key of the message: # selected */ + public static final String LABELS_search_result_select_label = "{labels.search_result_select_label}"; + + /** The key of the message: Fess */ + public static final String LABELS_search_title = "{labels.search_title}"; + + /** The key of the message: Popular Words: */ + public static final String LABELS_search_hot_search_word = "{labels.search_hot_search_word}"; + + /** The key of the message: -- Sort -- */ + public static final String LABELS_search_result_select_sort = "{labels.search_result_select_sort}"; + + /** The key of the message: -- Results per page -- */ + public static final String LABELS_search_result_select_num = "{labels.search_result_select_num}"; + + /** The key of the message: Date (ascending) */ + public static final String LABELS_search_result_sort_created_asc = "{labels.search_result_sort_created_asc}"; + + /** The key of the message: Date (descending) */ + public static final String LABELS_search_result_sort_created_desc = "{labels.search_result_sort_created_desc}"; + + /** The key of the message: Size (ascending) */ + public static final String LABELS_search_result_sort_contentLength_asc = "{labels.search_result_sort_contentLength_asc}"; + + /** The key of the message: Size (descending) */ + public static final String LABELS_search_result_sort_contentLength_desc = "{labels.search_result_sort_contentLength_desc}"; + + /** The key of the message: Last Modified (ascending) */ + public static final String LABELS_search_result_sort_lastModified_asc = "{labels.search_result_sort_lastModified_asc}"; + + /** The key of the message: Last Modified (descending) */ + public static final String LABELS_search_result_sort_lastModified_desc = "{labels.search_result_sort_lastModified_desc}"; + + /** The key of the message: Click (ascending) */ + public static final String LABELS_search_result_sort_clickCount_asc = "{labels.search_result_sort_clickCount_asc}"; + + /** The key of the message: Click (descending) */ + public static final String LABELS_search_result_sort_clickCount_desc = "{labels.search_result_sort_clickCount_desc}"; + + /** The key of the message: Favorite (ascending) */ + public static final String LABELS_search_result_sort_favoriteCount_asc = "{labels.search_result_sort_favoriteCount_asc}"; + + /** The key of the message: Favorite (descending) */ + public static final String LABELS_search_result_sort_favoriteCount_desc = "{labels.search_result_sort_favoriteCount_desc}"; + + /** The key of the message: {0} bytes */ + public static final String LABELS_search_result_size = "{labels.search_result_size}"; + + /** The key of the message: Registered: */ + public static final String LABELS_search_result_created = "{labels.search_result_created}"; + + /** The key of the message: Last Modified: */ + public static final String LABELS_search_result_last_modified = "{labels.search_result_last_modified}"; + + /** The key of the message: Vote it */ + public static final String LABELS_search_result_favorite = "{labels.search_result_favorite}"; + + /** The key of the message: Voted */ + public static final String LABELS_search_result_favorited = "{labels.search_result_favorited}"; + + /** The key of the message: Click: {0} */ + public static final String LABELS_search_click_count = "{labels.search_click_count}"; + + /** The key of the message: more.. */ + public static final String LABELS_search_result_more = "{labels.search_result_more}"; + + /** The key of the message: Cache */ + public static final String LABELS_search_result_cache = "{labels.search_result_cache}"; + + /** The key of the message: All */ + public static final String LABELS_searchoptions_all = "{labels.searchoptions_all}"; + + /** The key of the message: Score */ + public static final String LABELS_searchoptions_score = "{labels.searchoptions_score}"; + + /** The key of the message: Sort: */ + public static final String LABELS_searchoptions_menu_sort = "{labels.searchoptions_menu_sort}"; + + /** The key of the message: Result Per Page: */ + public static final String LABELS_searchoptions_menu_num = "{labels.searchoptions_menu_num}"; + + /** The key of the message: {0} results */ + public static final String LABELS_searchoptions_num = "{labels.searchoptions_num}"; + + /** The key of the message: Language: */ + public static final String LABELS_searchoptions_menu_lang = "{labels.searchoptions_menu_lang}"; + + /** The key of the message: Labels: */ + public static final String LABELS_searchoptions_menu_labels = "{labels.searchoptions_menu_labels}"; + + /** The key of the message: Username: {0} */ + public static final String LABELS_searchheader_username = "{labels.searchheader_username}"; + + /** The key of the message: Error */ + public static final String LABELS_error_title = "{labels.error_title}"; + + /** The key of the message: System Error */ + public static final String LABELS_system_error_title = "{labels.system_error_title}"; + + /** The key of the message: Contact the Site Administrator. */ + public static final String LABELS_contact_site_admin = "{labels.contact_site_admin}"; + + /** The key of the message: Bad Request */ + public static final String LABELS_request_error_title = "{labels.request_error_title}"; + + /** The key of the message: Invalid request for the url. */ + public static final String LABELS_bad_request = "{labels.bad_request}"; + + /** The key of the message: Page Not Found */ + public static final String LABELS_page_not_found_title = "{labels.page_not_found_title}"; + + /** The key of the message: Check the url. */ + public static final String LABELS_check_url = "{labels.check_url}"; + + /** The key of the message: Home */ + public static final String LABELS_HOME = "{labels.home}"; + + /** The key of the message: Login */ + public static final String LABELS_LOGIN = "{labels.login}"; + + /** The key of the message: Copyright(C) 2009-2014 CodeLibs Project. All Rights Reserved. */ + public static final String LABELS_LOGIN_footer_copyright = "{labels.login.footer_copyright}"; + + /** The key of the message: Login */ + public static final String LABELS_login_title = "{labels.login_title}"; + + /** The key of the message: Labels */ + public static final String LABELS_index_label = "{labels.index_label}"; + + /** The key of the message: Languages */ + public static final String LABELS_index_lang = "{labels.index_lang}"; + + /** The key of the message: Sort */ + public static final String LABELS_index_sort = "{labels.index_sort}"; + + /** The key of the message: Results per page */ + public static final String LABELS_index_num = "{labels.index_num}"; + + /** The key of the message: Logout */ + public static final String LABELS_logout_title = "{labels.logout_title}"; + + /** The key of the message: Logout */ + public static final String LABELS_LOGOUT = "{labels.logout}"; + + /** The key of the message: Do you want to logout? */ + public static final String LABELS_do_you_want_to_logout = "{labels.do_you_want_to_logout}"; + + /** The key of the message: Logout */ + public static final String LABELS_logout_button = "{labels.logout_button}"; + + /** The key of the message: Search */ + public static final String LABELS_TOP_SEARCH = "{labels.top.search}"; + + /** The key of the message: Fess */ + public static final String LABELS_search_top_logo_alt = "{labels.search_top_logo_alt}"; + + /** The key of the message: Fess */ + public static final String LABELS_index_title = "{labels.index_title}"; + + /** The key of the message: Full tExt Search Server */ + public static final String LABELS_index_subtitle = "{labels.index_subtitle}"; + + /** The key of the message: Search */ + public static final String LABELS_index_search_title = "{labels.index_search_title}"; + + /** The key of the message: Search the Web/Document */ + public static final String LABELS_index_form_query_label = "{labels.index_form_query_label}"; + + /** The key of the message: Select a label */ + public static final String LABELS_index_form_label_label = "{labels.index_form_label_label}"; + + /** The key of the message: Search */ + public static final String LABELS_index_form_search_btn = "{labels.index_form_search_btn}"; + + /** The key of the message: Reset */ + public static final String LABELS_index_form_reset_btn = "{labels.index_form_reset_btn}"; + + /** The key of the message: Popular Words */ + public static final String LABELS_index_hotkeywords_title = "{labels.index_hotkeywords_title}"; + + /** The key of the message: Fess Search */ + public static final String LABELS_index_osdd_title = "{labels.index_osdd_title}"; + + /** The key of the message: Options */ + public static final String LABELS_index_form_option_btn = "{labels.index_form_option_btn}"; + + /** The key of the message: Help */ + public static final String LABELS_index_help = "{labels.index_help}"; + + /** The key of the message: Search Options */ + public static final String LABELS_search_options = "{labels.search_options}"; + + /** The key of the message: Close */ + public static final String LABELS_search_options_close = "{labels.search_options_close}"; + + /** The key of the message: Clear */ + public static final String LABELS_search_options_clear = "{labels.search_options_clear}"; + + /** The key of the message: This is a cache of {0}. It is a snapshot of the page at {1}. */ + public static final String LABELS_search_cache_msg = "{labels.search_cache_msg}"; + + /** The key of the message: Unknown */ + public static final String LABELS_search_unknown = "{labels.search_unknown}"; + + /** The key of the message: Back to top */ + public static final String LABELS_footer_back_to_top = "{labels.footer_back_to_top}"; + + /** The key of the message: Fess */ + public static final String LABELS_header_brand_name = "{labels.header_brand_name}"; + + /** The key of the message: Options */ + public static final String LABELS_header_form_option_btn = "{labels.header_form_option_btn}"; + + /** The key of the message: File Crawling Configuration */ + public static final String LABELS_file_crawling_configuration = "{labels.file_crawling_configuration}"; + + /** The key of the message: File Crawling Configuration */ + public static final String LABELS_file_crawling_title_details = "{labels.file_crawling_title_details}"; + + /** The key of the message: Included Paths For Crawling */ + public static final String LABELS_included_paths = "{labels.included_paths}"; + + /** The key of the message: Excluded Paths For Crawling */ + public static final String LABELS_excluded_paths = "{labels.excluded_paths}"; + + /** The key of the message: Included Paths For Indexing */ + public static final String LABELS_included_doc_paths = "{labels.included_doc_paths}"; + + /** The key of the message: Excluded Paths For Indexing */ + public static final String LABELS_excluded_doc_paths = "{labels.excluded_doc_paths}"; + + /** The key of the message: Config Parameters */ + public static final String LABELS_config_parameter = "{labels.config_parameter}"; + + /** The key of the message: Max Access Count */ + public static final String LABELS_max_access_count = "{labels.max_access_count}"; + + /** The key of the message: The number of Tread */ + public static final String LABELS_number_of_thread = "{labels.number_of_thread}"; + + /** The key of the message: Interval time */ + public static final String LABELS_interval_time = "{labels.interval_time}"; + + /** The key of the message: ms */ + public static final String LABELS_MILLISEC = "{labels.millisec}"; + + /** The key of the message: Create */ + public static final String LABELS_file_crawling_button_create = "{labels.file_crawling_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_file_crawling_button_back = "{labels.file_crawling_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_file_crawling_button_confirm = "{labels.file_crawling_button_confirm}"; + + /** The key of the message: Confirm File Crawling Configuration */ + public static final String LABELS_file_crawling_title_confirm = "{labels.file_crawling_title_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_file_crawling_button_update = "{labels.file_crawling_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_file_crawling_button_delete = "{labels.file_crawling_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_file_crawling_button_edit = "{labels.file_crawling_button_edit}"; + + /** The key of the message: Create New */ + public static final String LABELS_file_crawling_link_create_new = "{labels.file_crawling_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_file_crawling_link_list = "{labels.file_crawling_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_file_crawling_link_create = "{labels.file_crawling_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_file_crawling_link_update = "{labels.file_crawling_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_file_crawling_link_confirm = "{labels.file_crawling_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_file_crawling_link_details = "{labels.file_crawling_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_file_crawling_link_edit = "{labels.file_crawling_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_file_crawling_link_delete = "{labels.file_crawling_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_file_crawling_link_prev_page = "{labels.file_crawling_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_file_crawling_link_next_page = "{labels.file_crawling_link_next_page}"; + + /** The key of the message: Web Crawling Configuration */ + public static final String LABELS_web_crawling_configuration = "{labels.web_crawling_configuration}"; + + /** The key of the message: Web Crawling Configuration */ + public static final String LABELS_web_crawling_title_details = "{labels.web_crawling_title_details}"; + + /** The key of the message: Included URLs For Crawling */ + public static final String LABELS_included_urls = "{labels.included_urls}"; + + /** The key of the message: Excluded URLs For Crawling */ + public static final String LABELS_excluded_urls = "{labels.excluded_urls}"; + + /** The key of the message: Included URLs For Indexing */ + public static final String LABELS_included_doc_urls = "{labels.included_doc_urls}"; + + /** The key of the message: Excluded URLs For Indexing */ + public static final String LABELS_excluded_doc_urls = "{labels.excluded_doc_urls}"; + + /** The key of the message: User Agent */ + public static final String LABELS_user_agent = "{labels.user_agent}"; + + /** The key of the message: Create */ + public static final String LABELS_web_crawling_button_create = "{labels.web_crawling_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_web_crawling_button_back = "{labels.web_crawling_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_web_crawling_button_confirm = "{labels.web_crawling_button_confirm}"; + + /** The key of the message: Confirm Web Crawling Configuration */ + public static final String LABELS_web_crawling_title_confirm = "{labels.web_crawling_title_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_web_crawling_button_update = "{labels.web_crawling_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_web_crawling_button_delete = "{labels.web_crawling_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_web_crawling_button_edit = "{labels.web_crawling_button_edit}"; + + /** The key of the message: Create New */ + public static final String LABELS_web_crawling_link_create_new = "{labels.web_crawling_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_web_crawling_link_list = "{labels.web_crawling_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_web_crawling_link_create = "{labels.web_crawling_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_web_crawling_link_update = "{labels.web_crawling_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_web_crawling_link_confirm = "{labels.web_crawling_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_web_crawling_link_details = "{labels.web_crawling_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_web_crawling_link_edit = "{labels.web_crawling_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_web_crawling_link_delete = "{labels.web_crawling_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_web_crawling_link_prev_page = "{labels.web_crawling_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_web_crawling_link_next_page = "{labels.web_crawling_link_next_page}"; + + /** The key of the message: General Configuration */ + public static final String LABELS_crawler_configuration = "{labels.crawler_configuration}"; + + /** The key of the message: General Configuration */ + public static final String LABELS_crawler_title_edit = "{labels.crawler_title_edit}"; + + /** The key of the message: Schedule */ + public static final String LABELS_SCHEDULE = "{labels.schedule}"; + + /** The key of the message: Optimize Index */ + public static final String LABELS_OPTIMIZE = "{labels.optimize}"; + + /** The key of the message: Enabled */ + public static final String LABELS_ENABLED = "{labels.enabled}"; + + /** The key of the message: Commit Index */ + public static final String LABELS_COMMIT = "{labels.commit}"; + + /** The key of the message: Server Rotation */ + public static final String LABELS_server_rotation = "{labels.server_rotation}"; + + /** The key of the message: Remove Index Before */ + public static final String LABELS_day_for_cleanup = "{labels.day_for_cleanup}"; + + /** The key of the message: Day */ + public static final String LABELS_DAY = "{labels.day}"; + + /** The key of the message: Update */ + public static final String LABELS_crawl_button_update = "{labels.crawl_button_update}"; + + /** The key of the message: None */ + public static final String LABELS_NONE = "{labels.none}"; + + /** The key of the message: Commit per Document Size */ + public static final String LABELS_commit_per_count = "{labels.commit_per_count}"; + + /** The key of the message: Num of Simultaneous Crawler Config */ + public static final String LABELS_crawling_thread_count = "{labels.crawling_thread_count}"; + + /** The key of the message: Check Last Modified */ + public static final String LABELS_diff_crawling = "{labels.diff_crawling}"; + + /** The key of the message: Use ACL as Role */ + public static final String LABELS_use_acl_as_role = "{labels.use_acl_as_role}"; + + /** The key of the message: Search Logging */ + public static final String LABELS_search_log_enabled = "{labels.search_log_enabled}"; + + /** The key of the message: User Logging */ + public static final String LABELS_user_info_enabled = "{labels.user_info_enabled}"; + + /** The key of the message: Favarite Logging */ + public static final String LABELS_user_favorite_enabled = "{labels.user_favorite_enabled}"; + + /** The key of the message: XML Response */ + public static final String LABELS_web_api_xml_enabled = "{labels.web_api_xml_enabled}"; + + /** The key of the message: JSON Response */ + public static final String LABELS_web_api_json_enabled = "{labels.web_api_json_enabled}"; + + /** The key of the message: Suggest API Response */ + public static final String LABELS_web_api_suggest_enabled = "{labels.web_api_suggest_enabled}"; + + /** The key of the message: Analysis API Response */ + public static final String LABELS_web_api_analysis_enabled = "{labels.web_api_analysis_enabled}"; + + /** The key of the message: Default Label Value */ + public static final String LABELS_default_label_value = "{labels.default_label_value}"; + + /** The key of the message: Append Params to URL */ + public static final String LABELS_append_query_param_enabled = "{labels.append_query_param_enabled}"; + + /** The key of the message: Supported Search */ + public static final String LABELS_supported_search_feature = "{labels.supported_search_feature}"; + + /** The key of the message: Excluded Failure Type */ + public static final String LABELS_ignore_failure_type = "{labels.ignore_failure_type}"; + + /** The key of the message: Failure Count Threshold */ + public static final String LABELS_failure_count_threshold = "{labels.failure_count_threshold}"; + + /** The key of the message: Popular Word Response */ + public static final String LABELS_hot_search_word_enabled = "{labels.hot_search_word_enabled}"; + + /** The key of the message: Web */ + public static final String LABELS_supported_search_web = "{labels.supported_search_web}"; + + /** The key of the message: Not Available */ + public static final String LABELS_supported_search_none = "{labels.supported_search_none}"; + + /** The key of the message: Purge Session Info Before */ + public static final String LABELS_purge_session_info_day = "{labels.purge_session_info_day}"; + + /** The key of the message: Purge Search Log Before */ + public static final String LABELS_purge_search_log_day = "{labels.purge_search_log_day}"; + + /** The key of the message: Purge Job Log Before */ + public static final String LABELS_purge_job_log_day = "{labels.purge_job_log_day}"; + + /** The key of the message: Purge User Before */ + public static final String LABELS_purge_user_info_day = "{labels.purge_user_info_day}"; + + /** The key of the message: Bots Name For Purge */ + public static final String LABELS_purge_by_bots = "{labels.purge_by_bots}"; + + /** The key of the message: Encoding for CSV */ + public static final String LABELS_csv_file_encoding = "{labels.csv_file_encoding}"; + + /** The key of the message: Notification Email */ + public static final String LABELS_notification_to = "{labels.notification_to}"; + + /** The key of the message: Path Mapping Configuration */ + public static final String LABELS_path_mapping_configuration = "{labels.path_mapping_configuration}"; + + /** The key of the message: Path Mapping */ + public static final String LABELS_path_mapping_title_details = "{labels.path_mapping_title_details}"; + + /** The key of the message: Confirm */ + public static final String LABELS_path_mapping_button_confirm = "{labels.path_mapping_button_confirm}"; + + /** The key of the message: Disabled */ + public static final String LABELS_DISABLED = "{labels.disabled}"; + + /** The key of the message: Crawling */ + public static final String LABELS_path_mapping_pt_crawling = "{labels.path_mapping_pt_crawling}"; + + /** The key of the message: Displaying */ + public static final String LABELS_path_mapping_pt_displaying = "{labels.path_mapping_pt_displaying}"; + + /** The key of the message: Crawling/Displaying */ + public static final String LABELS_path_mapping_pt_both = "{labels.path_mapping_pt_both}"; + + /** The key of the message: Confirm Path Mapping */ + public static final String LABELS_path_mapping_title_confirm = "{labels.path_mapping_title_confirm}"; + + /** The key of the message: Regular Name */ + public static final String LABELS_regular_name = "{labels.regular_name}"; + + /** The key of the message: Overlapping Name */ + public static final String LABELS_overlapping_name = "{labels.overlapping_name}"; + + /** The key of the message: Create */ + public static final String LABELS_path_mapping_button_create = "{labels.path_mapping_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_path_mapping_button_back = "{labels.path_mapping_button_back}"; + + /** The key of the message: Update */ + public static final String LABELS_path_mapping_button_update = "{labels.path_mapping_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_path_mapping_button_delete = "{labels.path_mapping_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_path_mapping_button_edit = "{labels.path_mapping_button_edit}"; + + /** The key of the message: Create New */ + public static final String LABELS_path_mapping_link_create_new = "{labels.path_mapping_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_path_mapping_link_list = "{labels.path_mapping_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_path_mapping_link_create = "{labels.path_mapping_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_path_mapping_link_update = "{labels.path_mapping_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_path_mapping_link_confirm = "{labels.path_mapping_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_path_mapping_link_details = "{labels.path_mapping_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_path_mapping_link_edit = "{labels.path_mapping_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_path_mapping_link_delete = "{labels.path_mapping_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_path_mapping_link_prev_page = "{labels.path_mapping_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_path_mapping_link_next_page = "{labels.path_mapping_link_next_page}"; + + /** The key of the message: Overlapping Host Configuration */ + public static final String LABELS_overlapping_host_configuration = "{labels.overlapping_host_configuration}"; + + /** The key of the message: Overlapping Host */ + public static final String LABELS_overlapping_host_title_details = "{labels.overlapping_host_title_details}"; + + /** The key of the message: Confirm */ + public static final String LABELS_overlapping_host_button_confirm = "{labels.overlapping_host_button_confirm}"; + + /** The key of the message: Confirm Overlapping Host */ + public static final String LABELS_overlapping_host_title_confirm = "{labels.overlapping_host_title_confirm}"; + + /** The key of the message: Create */ + public static final String LABELS_overlapping_host_button_create = "{labels.overlapping_host_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_overlapping_host_button_back = "{labels.overlapping_host_button_back}"; + + /** The key of the message: Update */ + public static final String LABELS_overlapping_host_button_update = "{labels.overlapping_host_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_overlapping_host_button_delete = "{labels.overlapping_host_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_overlapping_host_button_edit = "{labels.overlapping_host_button_edit}"; + + /** The key of the message: Create New */ + public static final String LABELS_overlapping_host_link_create_new = "{labels.overlapping_host_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_overlapping_host_link_list = "{labels.overlapping_host_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_overlapping_host_link_create = "{labels.overlapping_host_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_overlapping_host_link_update = "{labels.overlapping_host_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_overlapping_host_link_confirm = "{labels.overlapping_host_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_overlapping_host_link_details = "{labels.overlapping_host_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_overlapping_host_link_edit = "{labels.overlapping_host_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_overlapping_host_link_delete = "{labels.overlapping_host_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_overlapping_host_link_prev_page = "{labels.overlapping_host_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_overlapping_host_link_next_page = "{labels.overlapping_host_link_next_page}"; + + /** The key of the message: System Configuration */ + public static final String LABELS_system_title_configuration = "{labels.system_title_configuration}"; + + /** The key of the message: System Status */ + public static final String LABELS_system_title_system_status = "{labels.system_title_system_status}"; + + /** The key of the message: Update */ + public static final String LABELS_es_button_update = "{labels.es_button_update}"; + + /** The key of the message: Active */ + public static final String LABELS_es_active = "{labels.es_active}"; + + /** The key of the message: Inactive */ + public static final String LABELS_es_inactive = "{labels.es_inactive}"; + + /** The key of the message: Ready */ + public static final String LABELS_es_ready = "{labels.es_ready}"; + + /** The key of the message: Completed */ + public static final String LABELS_es_completed = "{labels.es_completed}"; + + /** The key of the message: Unfinished */ + public static final String LABELS_es_unfinished = "{labels.es_unfinished}"; + + /** The key of the message: None */ + public static final String LABELS_es_action_none = "{labels.es_action_none}"; + + /** The key of the message: Commit */ + public static final String LABELS_es_action_commit = "{labels.es_action_commit}"; + + /** The key of the message: Optimize */ + public static final String LABELS_es_action_optimize = "{labels.es_action_optimize}"; + + /** The key of the message: Delete */ + public static final String LABELS_es_action_delete = "{labels.es_action_delete}"; + + /** The key of the message: Results */ + public static final String LABELS_es_action_confirm_list = "{labels.es_action_confirm_list}"; + + /** The key of the message: All */ + public static final String LABELS_es_action_all = "{labels.es_action_all}"; + + /** The key of the message: Cluster Name */ + public static final String LABELS_es_cluster_name = "{labels.es_cluster_name}"; + + /** The key of the message: Solr Action */ + public static final String LABELS_es_title_action = "{labels.es_title_action}"; + + /** The key of the message: Delete Docs From Index */ + public static final String LABELS_es_title_delete = "{labels.es_title_delete}"; + + /** The key of the message: Crawler Process */ + public static final String LABELS_crawler_process_running = "{labels.crawler_process_running}"; + + /** The key of the message: Running */ + public static final String LABELS_crawler_running = "{labels.crawler_running}"; + + /** The key of the message: Stopped */ + public static final String LABELS_crawler_stopped = "{labels.crawler_stopped}"; + + /** The key of the message: Action */ + public static final String LABELS_crawler_process_action = "{labels.crawler_process_action}"; + + /** The key of the message: Added Docs */ + public static final String LABELS_es_document_title = "{labels.es_document_title}"; + + /** The key of the message: Server Group */ + public static final String LABELS_es_group_name = "{labels.es_group_name}"; + + /** The key of the message: Session */ + public static final String LABELS_session_name = "{labels.session_name}"; + + /** The key of the message: Num of Docs */ + public static final String LABELS_es_num_of_docs = "{labels.es_num_of_docs}"; + + /** The key of the message: Solr Status */ + public static final String LABELS_es_title_edit = "{labels.es_title_edit}"; + + /** The key of the message: Start Crawler */ + public static final String LABELS_crawler_button_start = "{labels.crawler_button_start}"; + + /** The key of the message: Stop Crawker */ + public static final String LABELS_crawler_button_stop = "{labels.crawler_button_stop}"; + + /** The key of the message: Solr Instance */ + public static final String LABELS_es_management_title = "{labels.es_management_title}"; + + /** The key of the message: Name */ + public static final String LABELS_es_instance_name = "{labels.es_instance_name}"; + + /** The key of the message: Status */ + public static final String LABELS_es_instance_status = "{labels.es_instance_status}"; + + /** The key of the message: Action */ + public static final String LABELS_es_instance_action = "{labels.es_instance_action}"; + + /** The key of the message: Start */ + public static final String LABELS_es_instance_start = "{labels.es_instance_start}"; + + /** The key of the message: Stop */ + public static final String LABELS_es_instance_stop = "{labels.es_instance_stop}"; + + /** The key of the message: Reload */ + public static final String LABELS_es_instance_reload = "{labels.es_instance_reload}"; + + /** The key of the message: URL */ + public static final String LABELS_es_action_url_delete = "{labels.es_action_url_delete}"; + + /** The key of the message: All */ + public static final String LABELS_system_document_all = "{labels.system_document_all}"; + + /** The key of the message: Group : Server */ + public static final String LABELS_system_group_server_name = "{labels.system_group_server_name}"; + + /** The key of the message: Server Status */ + public static final String LABELS_system_server_status = "{labels.system_server_status}"; + + /** The key of the message: Index Status */ + public static final String LABELS_system_index_status = "{labels.system_index_status}"; + + /** The key of the message: Crawler Status */ + public static final String LABELS_crawler_status_title = "{labels.crawler_status_title}"; + + /** The key of the message: All */ + public static final String LABELS_crawler_sessionid_all = "{labels.crawler_sessionid_all}"; + + /** The key of the message: No available Solr server. */ + public static final String LABELS_no_available_solr_servers = "{labels.no_available_solr_servers}"; + + /** The key of the message: Added Suggest Docs */ + public static final String LABELS_suggest_document_title = "{labels.suggest_document_title}"; + + /** The key of the message: type */ + public static final String LABELS_suggest_type = "{labels.suggest_type}"; + + /** The key of the message: all */ + public static final String LABELS_suggest_type_all = "{labels.suggest_type_all}"; + + /** The key of the message: content */ + public static final String LABELS_suggest_type_content = "{labels.suggest_type_content}"; + + /** The key of the message: search words */ + public static final String LABELS_suggest_type_searchlog = "{labels.suggest_type_searchlog}"; + + /** The key of the message: Suggest by Search Words */ + public static final String LABELS_suggest_search_log_enabled = "{labels.suggest_search_log_enabled}"; + + /** The key of the message: Purge Suggest Docs by Search Words */ + public static final String LABELS_purge_suggest_search_log_day = "{labels.purge_suggest_search_log_day}"; + + /** The key of the message: Session Information */ + public static final String LABELS_crawling_session_title = "{labels.crawling_session_title}"; + + /** The key of the message: Crawling Information */ + public static final String LABELS_crawling_session_title_confirm = "{labels.crawling_session_title_confirm}"; + + /** The key of the message: Back */ + public static final String LABELS_crawling_session_button_back = "{labels.crawling_session_button_back}"; + + /** The key of the message: Delete */ + public static final String LABELS_crawling_session_button_delete = "{labels.crawling_session_button_delete}"; + + /** The key of the message: Crawling Session */ + public static final String LABELS_crawling_session_configuration = "{labels.crawling_session_configuration}"; + + /** The key of the message: Search */ + public static final String LABELS_crawling_session_search = "{labels.crawling_session_search}"; + + /** The key of the message: Reset */ + public static final String LABELS_crawling_session_reset = "{labels.crawling_session_reset}"; + + /** The key of the message: List */ + public static final String LABELS_crawling_session_link_list = "{labels.crawling_session_link_list}"; + + /** The key of the message: Details */ + public static final String LABELS_crawling_session_link_details = "{labels.crawling_session_link_details}"; + + /** The key of the message: Delete */ + public static final String LABELS_crawling_session_link_delete = "{labels.crawling_session_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_crawling_session_prev_page = "{labels.crawling_session_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_crawling_session_next_page = "{labels.crawling_session_next_page}"; + + /** The key of the message: Session ID: */ + public static final String LABELS_crawling_session_session_id_search = "{labels.crawling_session_session_id_search}"; + + /** The key of the message: Session ID */ + public static final String LABELS_crawling_session_session_id = "{labels.crawling_session_session_id}"; + + /** The key of the message: Name */ + public static final String LABELS_crawling_session_name = "{labels.crawling_session_name}"; + + /** The key of the message: Created */ + public static final String LABELS_crawling_session_created_time = "{labels.crawling_session_created_time}"; + + /** The key of the message: Expired */ + public static final String LABELS_crawling_session_expired_time = "{labels.crawling_session_expired_time}"; + + /** The key of the message: Delete All */ + public static final String LABELS_crawling_session_delete_all_link = "{labels.crawling_session_delete_all_link}"; + + /** The key of the message: Do you want to delete all? */ + public static final String LABELS_crawling_session_delete_all_confirmation = "{labels.crawling_session_delete_all_confirmation}"; + + /** The key of the message: Crawling Status */ + public static final String LABELS_crawling_session_CrawlerStatus = "{labels.crawling_session_CrawlerStatus}"; + + /** The key of the message: Start Time (Crawling) */ + public static final String LABELS_crawling_session_CrawlerStartTime = "{labels.crawling_session_CrawlerStartTime}"; + + /** The key of the message: End Time (Crawling) */ + public static final String LABELS_crawling_session_CrawlerEndTime = "{labels.crawling_session_CrawlerEndTime}"; + + /** The key of the message: Exec Time (Crawling) */ + public static final String LABELS_crawling_session_CrawlerExecTime = "{labels.crawling_session_CrawlerExecTime}"; + + /** The key of the message: Start Time (Web/File) */ + public static final String LABELS_crawling_session_WebFsCrawlStartTime = "{labels.crawling_session_WebFsCrawlStartTime}"; + + /** The key of the message: End Time (Web/File) */ + public static final String LABELS_crawling_session_WebFsCrawlEndTime = "{labels.crawling_session_WebFsCrawlEndTime}"; + + /** The key of the message: Start Time (Data Store) */ + public static final String LABELS_crawling_session_DataCrawlStartTime = "{labels.crawling_session_DataCrawlStartTime}"; + + /** The key of the message: End Time (Data Store) */ + public static final String LABELS_crawling_session_DataCrawlEndTime = "{labels.crawling_session_DataCrawlEndTime}"; + + /** The key of the message: Start Time (Optimize) */ + public static final String LABELS_crawling_session_OptimizeStartTime = "{labels.crawling_session_OptimizeStartTime}"; + + /** The key of the message: End Time (Optimize) */ + public static final String LABELS_crawling_session_OptimizeEndTime = "{labels.crawling_session_OptimizeEndTime}"; + + /** The key of the message: Exec Time (Optimize) */ + public static final String LABELS_crawling_session_OptimizeExecTime = "{labels.crawling_session_OptimizeExecTime}"; + + /** The key of the message: Start Time (Commit) */ + public static final String LABELS_crawling_session_CommitStartTime = "{labels.crawling_session_CommitStartTime}"; + + /** The key of the message: End Time (Commit) */ + public static final String LABELS_crawling_session_CommitEndTime = "{labels.crawling_session_CommitEndTime}"; + + /** The key of the message: Exec Time (Commit) */ + public static final String LABELS_crawling_session_CommitExecTime = "{labels.crawling_session_CommitExecTime}"; + + /** The key of the message: Exec Time (Web/File) */ + public static final String LABELS_crawling_session_WebFsCrawlExecTime = "{labels.crawling_session_WebFsCrawlExecTime}"; + + /** The key of the message: Indexing Exec Time (Web/File) */ + public static final String LABELS_crawling_session_WebFsIndexExecTime = "{labels.crawling_session_WebFsIndexExecTime}"; + + /** The key of the message: Index Size (Web/File) */ + public static final String LABELS_crawling_session_WebFsIndexSize = "{labels.crawling_session_WebFsIndexSize}"; + + /** The key of the message: Exec Time (Data Store) */ + public static final String LABELS_crawling_session_DataCrawlExecTime = "{labels.crawling_session_DataCrawlExecTime}"; + + /** The key of the message: Indexing Exec Time (Data Store) */ + public static final String LABELS_crawling_session_DataIndexExecTime = "{labels.crawling_session_DataIndexExecTime}"; + + /** The key of the message: Index Size (Data Store) */ + public static final String LABELS_crawling_session_DataIndexSize = "{labels.crawling_session_DataIndexSize}"; + + /** The key of the message: Replication Status */ + public static final String LABELS_crawling_session_ReplicationStatus = "{labels.crawling_session_ReplicationStatus}"; + + /** The key of the message: Start Time (Replication) */ + public static final String LABELS_crawling_session_ReplicationStartTime = "{labels.crawling_session_ReplicationStartTime}"; + + /** The key of the message: End Time (Replication) */ + public static final String LABELS_crawling_session_ReplicationEndTime = "{labels.crawling_session_ReplicationEndTime}"; + + /** The key of the message: Exec Time (Replication) */ + public static final String LABELS_crawling_session_ReplicationExecTime = "{labels.crawling_session_ReplicationExecTime}"; + + /** The key of the message: Backup/Restore Configuration */ + public static final String LABELS_data_configuration = "{labels.data_configuration}"; + + /** The key of the message: Backup */ + public static final String LABELS_backup_title_edit = "{labels.backup_title_edit}"; + + /** The key of the message: Backup */ + public static final String LABELS_BACKUP = "{labels.backup}"; + + /** The key of the message: Download as XML File */ + public static final String LABELS_download_data = "{labels.download_data}"; + + /** The key of the message: Download as CSV File */ + public static final String LABELS_download_data_csv = "{labels.download_data_csv}"; + + /** The key of the message: Restore */ + public static final String LABELS_restore_title_edit = "{labels.restore_title_edit}"; + + /** The key of the message: File */ + public static final String LABELS_RESTORE = "{labels.restore}"; + + /** The key of the message: Restore Data */ + public static final String LABELS_upload_button = "{labels.upload_button}"; + + /** The key of the message: Confinguration */ + public static final String LABELS_backup_config = "{labels.backup_config}"; + + /** The key of the message: Session Info */ + public static final String LABELS_backup_session_info = "{labels.backup_session_info}"; + + /** The key of the message: Search Log */ + public static final String LABELS_backup_search_log = "{labels.backup_search_log}"; + + /** The key of the message: Click Long */ + public static final String LABELS_backup_click_log = "{labels.backup_click_log}"; + + /** The key of the message: Web Authentication */ + public static final String LABELS_web_authentication_configuration = "{labels.web_authentication_configuration}"; + + /** The key of the message: Create New */ + public static final String LABELS_web_authentication_link_create_new = "{labels.web_authentication_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_web_authentication_link_list = "{labels.web_authentication_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_web_authentication_link_create = "{labels.web_authentication_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_web_authentication_link_update = "{labels.web_authentication_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_web_authentication_link_confirm = "{labels.web_authentication_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_web_authentication_link_details = "{labels.web_authentication_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_web_authentication_link_edit = "{labels.web_authentication_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_web_authentication_link_delete = "{labels.web_authentication_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_web_authentication_link_prev_page = "{labels.web_authentication_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_web_authentication_link_next_page = "{labels.web_authentication_link_next_page}"; + + /** The key of the message: Hostname */ + public static final String LABELS_web_authentication_list_hostname = "{labels.web_authentication_list_hostname}"; + + /** The key of the message: Realm */ + public static final String LABELS_web_authentication_list_realm = "{labels.web_authentication_list_realm}"; + + /** The key of the message: Config Name */ + public static final String LABELS_web_authentication_list_web_crawling_config = "{labels.web_authentication_list_web_crawling_config}"; + + /** The key of the message: Any */ + public static final String LABELS_web_authentication_any = "{labels.web_authentication_any}"; + + /** The key of the message: Create New Web Config */ + public static final String LABELS_web_authentication_create_web_config = "{labels.web_authentication_create_web_config}"; + + /** The key of the message: Web Authentication */ + public static final String LABELS_web_authentication_title_details = "{labels.web_authentication_title_details}"; + + /** The key of the message: Create */ + public static final String LABELS_web_authentication_button_create = "{labels.web_authentication_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_web_authentication_button_back = "{labels.web_authentication_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_web_authentication_button_confirm = "{labels.web_authentication_button_confirm}"; + + /** The key of the message: Hostname */ + public static final String LABELS_web_authentication_hostname = "{labels.web_authentication_hostname}"; + + /** The key of the message: Port */ + public static final String LABELS_web_authentication_port = "{labels.web_authentication_port}"; + + /** The key of the message: Realm */ + public static final String LABELS_web_authentication_realm = "{labels.web_authentication_realm}"; + + /** The key of the message: Scheme */ + public static final String LABELS_web_authentication_scheme = "{labels.web_authentication_scheme}"; + + /** The key of the message: Username */ + public static final String LABELS_web_authentication_username = "{labels.web_authentication_username}"; + + /** The key of the message: Password */ + public static final String LABELS_web_authentication_password = "{labels.web_authentication_password}"; + + /** The key of the message: Parameters */ + public static final String LABELS_web_authentication_parameters = "{labels.web_authentication_parameters}"; + + /** The key of the message: Web Config */ + public static final String LABELS_web_authentication_web_crawling_config = "{labels.web_authentication_web_crawling_config}"; + + /** The key of the message: Basic */ + public static final String LABELS_web_authentication_scheme_basic = "{labels.web_authentication_scheme_basic}"; + + /** The key of the message: Digest */ + public static final String LABELS_web_authentication_scheme_digest = "{labels.web_authentication_scheme_digest}"; + + /** The key of the message: NTLM */ + public static final String LABELS_web_authentication_scheme_ntlm = "{labels.web_authentication_scheme_ntlm}"; + + /** The key of the message: Web Authentication */ + public static final String LABELS_web_authentication_title_confirm = "{labels.web_authentication_title_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_web_authentication_button_update = "{labels.web_authentication_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_web_authentication_button_delete = "{labels.web_authentication_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_web_authentication_button_edit = "{labels.web_authentication_button_edit}"; + + /** The key of the message: Log Files */ + public static final String LABELS_log_configuration = "{labels.log_configuration}"; + + /** The key of the message: Log Files */ + public static final String LABELS_log_file_download_title = "{labels.log_file_download_title}"; + + /** The key of the message: File Name */ + public static final String LABELS_log_file_name = "{labels.log_file_name}"; + + /** The key of the message: Timestamp */ + public static final String LABELS_log_file_date = "{labels.log_file_date}"; + + /** The key of the message: Label */ + public static final String LABELS_labeltype_configuration = "{labels.labeltype_configuration}"; + + /** The key of the message: Label */ + public static final String LABELS_labeltype_title_details = "{labels.labeltype_title_details}"; + + /** The key of the message: Confirm */ + public static final String LABELS_labeltype_button_confirm = "{labels.labeltype_button_confirm}"; + + /** The key of the message: Name */ + public static final String LABELS_labeltype_name = "{labels.labeltype_name}"; + + /** The key of the message: Value */ + public static final String LABELS_labeltype_value = "{labels.labeltype_value}"; + + /** The key of the message: Confirm Label */ + public static final String LABELS_labeltype_title_confirm = "{labels.labeltype_title_confirm}"; + + /** The key of the message: Create */ + public static final String LABELS_labeltype_button_create = "{labels.labeltype_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_labeltype_button_back = "{labels.labeltype_button_back}"; + + /** The key of the message: Update */ + public static final String LABELS_labeltype_button_update = "{labels.labeltype_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_labeltype_button_delete = "{labels.labeltype_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_labeltype_button_edit = "{labels.labeltype_button_edit}"; + + /** The key of the message: Included Paths */ + public static final String LABELS_labeltype_included_paths = "{labels.labeltype_included_paths}"; + + /** The key of the message: Excluded Paths */ + public static final String LABELS_labeltype_excluded_paths = "{labels.labeltype_excluded_paths}"; + + /** The key of the message: Create New */ + public static final String LABELS_labeltype_link_create_new = "{labels.labeltype_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_labeltype_link_list = "{labels.labeltype_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_labeltype_link_create = "{labels.labeltype_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_labeltype_link_update = "{labels.labeltype_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_labeltype_link_confirm = "{labels.labeltype_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_labeltype_link_details = "{labels.labeltype_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_labeltype_link_edit = "{labels.labeltype_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_labeltype_link_delete = "{labels.labeltype_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_labeltype_link_prev_page = "{labels.labeltype_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_labeltype_link_next_page = "{labels.labeltype_link_next_page}"; + + /** The key of the message: Role */ + public static final String LABELS_roletype_configuration = "{labels.roletype_configuration}"; + + /** The key of the message: Role */ + public static final String LABELS_roletype_title_details = "{labels.roletype_title_details}"; + + /** The key of the message: Confirm */ + public static final String LABELS_roletype_button_confirm = "{labels.roletype_button_confirm}"; + + /** The key of the message: Name */ + public static final String LABELS_roletype_name = "{labels.roletype_name}"; + + /** The key of the message: Value */ + public static final String LABELS_roletype_value = "{labels.roletype_value}"; + + /** The key of the message: Confirm Role */ + public static final String LABELS_roletype_title_confirm = "{labels.roletype_title_confirm}"; + + /** The key of the message: Create */ + public static final String LABELS_roletype_button_create = "{labels.roletype_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_roletype_button_back = "{labels.roletype_button_back}"; + + /** The key of the message: Update */ + public static final String LABELS_roletype_button_update = "{labels.roletype_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_roletype_button_delete = "{labels.roletype_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_roletype_button_edit = "{labels.roletype_button_edit}"; + + /** The key of the message: Create New */ + public static final String LABELS_roletype_link_create_new = "{labels.roletype_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_roletype_link_list = "{labels.roletype_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_roletype_link_create = "{labels.roletype_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_roletype_link_update = "{labels.roletype_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_roletype_link_confirm = "{labels.roletype_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_roletype_link_details = "{labels.roletype_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_roletype_link_edit = "{labels.roletype_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_roletype_link_delete = "{labels.roletype_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_roletype_link_prev_page = "{labels.roletype_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_roletype_link_next_page = "{labels.roletype_link_next_page}"; + + /** The key of the message: Request Header */ + public static final String LABELS_request_header_configuration = "{labels.request_header_configuration}"; + + /** The key of the message: Create New */ + public static final String LABELS_request_header_link_create_new = "{labels.request_header_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_request_header_link_list = "{labels.request_header_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_request_header_link_create = "{labels.request_header_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_request_header_link_update = "{labels.request_header_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_request_header_link_confirm = "{labels.request_header_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_request_header_link_details = "{labels.request_header_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_request_header_link_edit = "{labels.request_header_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_request_header_link_delete = "{labels.request_header_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_request_header_link_prev_page = "{labels.request_header_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_request_header_link_next_page = "{labels.request_header_link_next_page}"; + + /** The key of the message: Name */ + public static final String LABELS_request_header_list_name = "{labels.request_header_list_name}"; + + /** The key of the message: Config Name */ + public static final String LABELS_request_header_list_web_crawling_config = "{labels.request_header_list_web_crawling_config}"; + + /** The key of the message: Create New Web Config */ + public static final String LABELS_request_header_create_web_config = "{labels.request_header_create_web_config}"; + + /** The key of the message: Request Header */ + public static final String LABELS_request_header_title_details = "{labels.request_header_title_details}"; + + /** The key of the message: Create */ + public static final String LABELS_request_header_button_create = "{labels.request_header_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_request_header_button_back = "{labels.request_header_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_request_header_button_confirm = "{labels.request_header_button_confirm}"; + + /** The key of the message: Name */ + public static final String LABELS_request_header_name = "{labels.request_header_name}"; + + /** The key of the message: Value */ + public static final String LABELS_request_header_value = "{labels.request_header_value}"; + + /** The key of the message: Web Config */ + public static final String LABELS_request_header_web_crawling_config = "{labels.request_header_web_crawling_config}"; + + /** The key of the message: Request Header */ + public static final String LABELS_request_header_title_confirm = "{labels.request_header_title_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_request_header_button_update = "{labels.request_header_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_request_header_button_delete = "{labels.request_header_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_request_header_button_edit = "{labels.request_header_button_edit}"; + + /** The key of the message: Key Match */ + public static final String LABELS_key_match_configuration = "{labels.key_match_configuration}"; + + /** The key of the message: Create New */ + public static final String LABELS_key_match_link_create_new = "{labels.key_match_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_key_match_link_list = "{labels.key_match_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_key_match_link_create = "{labels.key_match_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_key_match_link_update = "{labels.key_match_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_key_match_link_confirm = "{labels.key_match_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_key_match_link_details = "{labels.key_match_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_key_match_link_edit = "{labels.key_match_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_key_match_link_delete = "{labels.key_match_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_key_match_link_prev_page = "{labels.key_match_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_key_match_link_next_page = "{labels.key_match_link_next_page}"; + + /** The key of the message: Term */ + public static final String LABELS_key_match_list_term = "{labels.key_match_list_term}"; + + /** The key of the message: Query */ + public static final String LABELS_key_match_list_query = "{labels.key_match_list_query}"; + + /** The key of the message: Term */ + public static final String LABELS_key_match_term = "{labels.key_match_term}"; + + /** The key of the message: Query */ + public static final String LABELS_key_match_query = "{labels.key_match_query}"; + + /** The key of the message: Size */ + public static final String LABELS_key_match_size = "{labels.key_match_size}"; + + /** The key of the message: Boost */ + public static final String LABELS_key_match_boost = "{labels.key_match_boost}"; + + /** The key of the message: Key Match */ + public static final String LABELS_key_match_title_details = "{labels.key_match_title_details}"; + + /** The key of the message: Create */ + public static final String LABELS_key_match_button_create = "{labels.key_match_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_key_match_button_back = "{labels.key_match_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_key_match_button_confirm = "{labels.key_match_button_confirm}"; + + /** The key of the message: Name */ + public static final String LABELS_key_match_name = "{labels.key_match_name}"; + + /** The key of the message: Value */ + public static final String LABELS_key_match_value = "{labels.key_match_value}"; + + /** The key of the message: Confirm Key Match */ + public static final String LABELS_key_match_title_confirm = "{labels.key_match_title_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_key_match_button_update = "{labels.key_match_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_key_match_button_delete = "{labels.key_match_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_key_match_button_edit = "{labels.key_match_button_edit}"; + + /** The key of the message: Design */ + public static final String LABELS_design_configuration = "{labels.design_configuration}"; + + /** The key of the message: File Upload */ + public static final String LABELS_design_title_file_upload = "{labels.design_title_file_upload}"; + + /** The key of the message: File Manager */ + public static final String LABELS_design_title_file = "{labels.design_title_file}"; + + /** The key of the message: Upload File */ + public static final String LABELS_design_file = "{labels.design_file}"; + + /** The key of the message: Upload File Name (Optional) */ + public static final String LABELS_design_file_name = "{labels.design_file_name}"; + + /** The key of the message: Upload */ + public static final String LABELS_design_button_upload = "{labels.design_button_upload}"; + + /** The key of the message: Page View Files */ + public static final String LABELS_design_file_title_edit = "{labels.design_file_title_edit}"; + + /** The key of the message: Edit */ + public static final String LABELS_design_edit_button = "{labels.design_edit_button}"; + + /** The key of the message: Download */ + public static final String LABELS_design_download_button = "{labels.design_download_button}"; + + /** The key of the message: Delete */ + public static final String LABELS_design_delete_button = "{labels.design_delete_button}"; + + /** The key of the message: Use Default */ + public static final String LABELS_design_use_default_button = "{labels.design_use_default_button}"; + + /** The key of the message: Top Page */ + public static final String LABELS_design_file_index = "{labels.design_file_index}"; + + /** The key of the message: Footer */ + public static final String LABELS_design_file_footer = "{labels.design_file_footer}"; + + /** The key of the message: Results Page (Frame) */ + public static final String LABELS_design_file_search = "{labels.design_file_search}"; + + /** The key of the message: Results Page (Content) */ + public static final String LABELS_design_file_searchResults = "{labels.design_file_searchResults}"; + + /** The key of the message: Results Page (No Result) */ + public static final String LABELS_design_file_searchNoResult = "{labels.design_file_searchNoResult}"; + + /** The key of the message: Help Page (Content) */ + public static final String LABELS_design_file_help = "{labels.design_file_help}"; + + /** The key of the message: Header */ + public static final String LABELS_design_file_header = "{labels.design_file_header}"; + + /** The key of the message: Search Error Page */ + public static final String LABELS_design_file_error = "{labels.design_file_error}"; + + /** The key of the message: Cache Page */ + public static final String LABELS_design_file_cache = "{labels.design_file_cache}"; + + /** The key of the message: Error Page (Header) */ + public static final String LABELS_design_file_errorHeader = "{labels.design_file_errorHeader}"; + + /** The key of the message: Error Page (Footer) */ + public static final String LABELS_design_file_errorFooter = "{labels.design_file_errorFooter}"; + + /** The key of the message: Error Page (Not Found) */ + public static final String LABELS_design_file_errorNotFound = "{labels.design_file_errorNotFound}"; + + /** The key of the message: Error Page (System Error) */ + public static final String LABELS_design_file_errorSystem = "{labels.design_file_errorSystem}"; + + /** The key of the message: Error Page (Redirect) */ + public static final String LABELS_design_file_errorRedirect = "{labels.design_file_errorRedirect}"; + + /** The key of the message: Error Page (BadRequest) */ + public static final String LABELS_design_file_errorBadRequest = "{labels.design_file_errorBadRequest}"; + + /** The key of the message: Do you want to delete it? */ + public static final String LABELS_design_delete_confirmation = "{labels.design_delete_confirmation}"; + + /** The key of the message: Edit Page View File */ + public static final String LABELS_design_title_edit_content = "{labels.design_title_edit_content}"; + + /** The key of the message: Update */ + public static final String LABELS_design_button_update = "{labels.design_button_update}"; + + /** The key of the message: Back */ + public static final String LABELS_design_button_back = "{labels.design_button_back}"; + + /** The key of the message: Data Crawling Configuration */ + public static final String LABELS_data_crawling_configuration = "{labels.data_crawling_configuration}"; + + /** The key of the message: Data Crawling Configuration */ + public static final String LABELS_data_crawling_title_details = "{labels.data_crawling_title_details}"; + + /** The key of the message: Handler Name */ + public static final String LABELS_handler_name = "{labels.handler_name}"; + + /** The key of the message: Parameter */ + public static final String LABELS_handler_parameter = "{labels.handler_parameter}"; + + /** The key of the message: Script */ + public static final String LABELS_handler_script = "{labels.handler_script}"; + + /** The key of the message: Role */ + public static final String LABELS_role_type = "{labels.role_type}"; + + /** The key of the message: Label */ + public static final String LABELS_label_type = "{labels.label_type}"; + + /** The key of the message: Create */ + public static final String LABELS_data_crawling_button_create = "{labels.data_crawling_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_data_crawling_button_back = "{labels.data_crawling_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_data_crawling_button_confirm = "{labels.data_crawling_button_confirm}"; + + /** The key of the message: Confirm Data Crawling Configuration */ + public static final String LABELS_data_crawling_title_confirm = "{labels.data_crawling_title_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_data_crawling_button_update = "{labels.data_crawling_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_data_crawling_button_delete = "{labels.data_crawling_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_data_crawling_button_edit = "{labels.data_crawling_button_edit}"; + + /** The key of the message: Create New */ + public static final String LABELS_data_crawling_link_create_new = "{labels.data_crawling_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_data_crawling_link_list = "{labels.data_crawling_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_data_crawling_link_create = "{labels.data_crawling_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_data_crawling_link_update = "{labels.data_crawling_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_data_crawling_link_confirm = "{labels.data_crawling_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_data_crawling_link_details = "{labels.data_crawling_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_data_crawling_link_edit = "{labels.data_crawling_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_data_crawling_link_delete = "{labels.data_crawling_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_data_crawling_link_prev_page = "{labels.data_crawling_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_data_crawling_link_next_page = "{labels.data_crawling_link_next_page}"; + + /** The key of the message: Configuration Wizard */ + public static final String LABELS_wizard_title_configuration = "{labels.wizard_title_configuration}"; + + /** The key of the message: Configuration Wizard */ + public static final String LABELS_wizard_start_title = "{labels.wizard_start_title}"; + + /** The key of the message: Using Configuration Wizard, you can create crawling settings easily. */ + public static final String LABELS_wizard_start_desc = "{labels.wizard_start_desc}"; + + /** The key of the message: Start */ + public static final String LABELS_wizard_start_button = "{labels.wizard_start_button}"; + + /** The key of the message: Crawling Schedule */ + public static final String LABELS_wizard_schedule_title = "{labels.wizard_schedule_title}"; + + /** The key of the message: Use Schedule */ + public static final String LABELS_wizard_schedule_enabled = "{labels.wizard_schedule_enabled}"; + + /** The key of the message: Schedule */ + public static final String LABELS_wizard_schedule = "{labels.wizard_schedule}"; + + /** The key of the message: MM: */ + public static final String LABELS_wizard_schedule_month_prefix = "{labels.wizard_schedule_month_prefix}"; + + /** The key of the message: */ + public static final String LABELS_wizard_schedule_month_suffix = "{labels.wizard_schedule_month_suffix}"; + + /** The key of the message: DD: */ + public static final String LABELS_wizard_schedule_date_prefix = "{labels.wizard_schedule_date_prefix}"; + + /** The key of the message: */ + public static final String LABELS_wizard_schedule_date_suffix = "{labels.wizard_schedule_date_suffix}"; + + /** The key of the message: hh: */ + public static final String LABELS_wizard_schedule_hour_prefix = "{labels.wizard_schedule_hour_prefix}"; + + /** The key of the message: */ + public static final String LABELS_wizard_schedule_hour_suffix = "{labels.wizard_schedule_hour_suffix}"; + + /** The key of the message: mm: */ + public static final String LABELS_wizard_schedule_min_prefix = "{labels.wizard_schedule_min_prefix}"; + + /** The key of the message: */ + public static final String LABELS_wizard_schedule_min_suffix = "{labels.wizard_schedule_min_suffix}"; + + /** The key of the message: Next */ + public static final String LABELS_wizard_button_next = "{labels.wizard_button_next}"; + + /** The key of the message: Skip */ + public static final String LABELS_wizard_button_skip = "{labels.wizard_button_skip}"; + + /** The key of the message: Cancel */ + public static final String LABELS_wizard_button_cancel = "{labels.wizard_button_cancel}"; + + /** The key of the message: Back */ + public static final String LABELS_wizard_button_back = "{labels.wizard_button_back}"; + + /** The key of the message: Crawling Configuration */ + public static final String LABELS_wizard_crawling_config_title = "{labels.wizard_crawling_config_title}"; + + /** The key of the message: Name */ + public static final String LABELS_wizard_crawling_config_name = "{labels.wizard_crawling_config_name}"; + + /** The key of the message: Crawling Path */ + public static final String LABELS_wizard_crawling_config_path = "{labels.wizard_crawling_config_path}"; + + /** The key of the message: Create again */ + public static final String LABELS_wizard_button_register_again = "{labels.wizard_button_register_again}"; + + /** The key of the message: Create/Next */ + public static final String LABELS_wizard_button_register_next = "{labels.wizard_button_register_next}"; + + /** The key of the message: Sun */ + public static final String LABELS_wizard_schedule_day_sun = "{labels.wizard_schedule_day_sun}"; + + /** The key of the message: Mon */ + public static final String LABELS_wizard_schedule_day_mon = "{labels.wizard_schedule_day_mon}"; + + /** The key of the message: Tue */ + public static final String LABELS_wizard_schedule_day_tue = "{labels.wizard_schedule_day_tue}"; + + /** The key of the message: Wed */ + public static final String LABELS_wizard_schedule_day_wed = "{labels.wizard_schedule_day_wed}"; + + /** The key of the message: Thu */ + public static final String LABELS_wizard_schedule_day_thu = "{labels.wizard_schedule_day_thu}"; + + /** The key of the message: Fri */ + public static final String LABELS_wizard_schedule_day_fri = "{labels.wizard_schedule_day_fri}"; + + /** The key of the message: Sat */ + public static final String LABELS_wizard_schedule_day_sat = "{labels.wizard_schedule_day_sat}"; + + /** The key of the message: Mon-Fri */ + public static final String LABELS_wizard_schedule_day_m_f = "{labels.wizard_schedule_day_m_f}"; + + /** The key of the message: Mon,Wed,Fri */ + public static final String LABELS_wizard_schedule_day_mwf = "{labels.wizard_schedule_day_mwf}"; + + /** The key of the message: Tue,Thu */ + public static final String LABELS_wizard_schedule_day_tt = "{labels.wizard_schedule_day_tt}"; + + /** The key of the message: Start Crawling */ + public static final String LABELS_wizard_start_crawling_title = "{labels.wizard_start_crawling_title}"; + + /** The key of the message: To click "Start Crawling" button, you can start a crawling now. */ + public static final String LABELS_wizard_start_crawling_desc = "{labels.wizard_start_crawling_desc}"; + + /** The key of the message: Start Crawling */ + public static final String LABELS_wizard_button_start_crawling = "{labels.wizard_button_start_crawling}"; + + /** The key of the message: Finish */ + public static final String LABELS_wizard_button_finish = "{labels.wizard_button_finish}"; + + /** The key of the message: Search Result */ + public static final String LABELS_search_list_configuration = "{labels.search_list_configuration}"; + + /** The key of the message: Type a search query. */ + public static final String LABELS_search_list_index_page = "{labels.search_list_index_page}"; + + /** The key of the message: Delete Confirmation */ + public static final String LABELS_search_list_title_confirm_delete = "{labels.search_list_title_confirm_delete}"; + + /** The key of the message: URL */ + public static final String LABELS_search_list_url = "{labels.search_list_url}"; + + /** The key of the message: Delete */ + public static final String LABELS_search_list_delete_link = "{labels.search_list_delete_link}"; + + /** The key of the message: Search Log */ + public static final String LABELS_search_log_configuration = "{labels.search_log_configuration}"; + + /** The key of the message: Search Word */ + public static final String LABELS_search_log_search_word_search = "{labels.search_log_search_word_search}"; + + /** The key of the message: User ID */ + public static final String LABELS_search_log_user_code_search = "{labels.search_log_user_code_search}"; + + /** The key of the message: Search */ + public static final String LABELS_search_log_button_search = "{labels.search_log_button_search}"; + + /** The key of the message: Reset */ + public static final String LABELS_search_log_button_reset = "{labels.search_log_button_reset}"; + + /** The key of the message: Requested Time */ + public static final String LABELS_search_log_requested_time = "{labels.search_log_requested_time}"; + + /** The key of the message: Search Word */ + public static final String LABELS_search_log_search_word = "{labels.search_log_search_word}"; + + /** The key of the message: Search Query */ + public static final String LABELS_search_log_search_query = "{labels.search_log_search_query}"; + + /** The key of the message: Response Time */ + public static final String LABELS_search_log_response_time = "{labels.search_log_response_time}"; + + /** The key of the message: Hits */ + public static final String LABELS_search_log_hit_count = "{labels.search_log_hit_count}"; + + /** The key of the message: Details */ + public static final String LABELS_search_log_link_details = "{labels.search_log_link_details}"; + + /** The key of the message: Delete */ + public static final String LABELS_search_log_link_delete = "{labels.search_log_link_delete}"; + + /** The key of the message: Delete All */ + public static final String LABELS_search_log_delete_all_link = "{labels.search_log_delete_all_link}"; + + /** The key of the message: Do you want to delete all? */ + public static final String LABELS_search_log_delete_all_confirmation = "{labels.search_log_delete_all_confirmation}"; + + /** The key of the message: (Up) */ + public static final String LABELS_search_log_sort_up = "{labels.search_log_sort_up}"; + + /** The key of the message: (Down) */ + public static final String LABELS_search_log_sort_down = "{labels.search_log_sort_down}"; + + /** The key of the message: Download(CSV) */ + public static final String LABELS_search_log_download_csv = "{labels.search_log_download_csv}"; + + /** The key of the message: First Query Only */ + public static final String LABELS_search_log_search_start_page = "{labels.search_log_search_start_page}"; + + /** The key of the message: Term */ + public static final String LABELS_search_log_search_term = "{labels.search_log_search_term}"; + + /** The key of the message: From: */ + public static final String LABELS_search_log_search_term_from = "{labels.search_log_search_term_from}"; + + /** The key of the message: To: */ + public static final String LABELS_search_log_search_term_to = "{labels.search_log_search_term_to}"; + + /** The key of the message: Search Log */ + public static final String LABELS_search_log_title = "{labels.search_log_title}"; + + /** The key of the message: Details */ + public static final String LABELS_search_log_title_confirm = "{labels.search_log_title_confirm}"; + + /** The key of the message: ID */ + public static final String LABELS_search_log_id = "{labels.search_log_id}"; + + /** The key of the message: Solr Query */ + public static final String LABELS_search_log_solr_query = "{labels.search_log_solr_query}"; + + /** The key of the message: Offset */ + public static final String LABELS_search_log_query_offset = "{labels.search_log_query_offset}"; + + /** The key of the message: Size */ + public static final String LABELS_search_log_query_page_size = "{labels.search_log_query_page_size}"; + + /** The key of the message: User Agent */ + public static final String LABELS_search_log_user_agent = "{labels.search_log_user_agent}"; + + /** The key of the message: Referer */ + public static final String LABELS_search_log_referer = "{labels.search_log_referer}"; + + /** The key of the message: IP */ + public static final String LABELS_search_log_client_ip = "{labels.search_log_client_ip}"; + + /** The key of the message: Session ID */ + public static final String LABELS_search_log_session_id = "{labels.search_log_session_id}"; + + /** The key of the message: Click Logs */ + public static final String LABELS_search_log_click_log_title = "{labels.search_log_click_log_title}"; + + /** The key of the message: URL */ + public static final String LABELS_search_log_click_log_url = "{labels.search_log_click_log_url}"; + + /** The key of the message: Requested Time */ + public static final String LABELS_search_log_click_log_requestedTime = "{labels.search_log_click_log_requestedTime}"; + + /** The key of the message: Access Type */ + public static final String LABELS_search_log_access_type = "{labels.search_log_access_type}"; + + /** The key of the message: Failure URL */ + public static final String LABELS_failure_url_configuration = "{labels.failure_url_configuration}"; + + /** The key of the message: URL */ + public static final String LABELS_failure_url_search_url = "{labels.failure_url_search_url}"; + + /** The key of the message: Error Count */ + public static final String LABELS_failure_url_search_error_count = "{labels.failure_url_search_error_count}"; + + /** The key of the message: Type */ + public static final String LABELS_failure_url_search_error_name = "{labels.failure_url_search_error_name}"; + + /** The key of the message: Last Access */ + public static final String LABELS_failure_url_last_access_time = "{labels.failure_url_last_access_time}"; + + /** The key of the message: Confirm */ + public static final String LABELS_failure_url_link_confirm = "{labels.failure_url_link_confirm}"; + + /** The key of the message: Do you want to delete all? */ + public static final String LABELS_failure_url_delete_all_confirmation = "{labels.failure_url_delete_all_confirmation}"; + + /** The key of the message: Error Count */ + public static final String LABELS_failure_url_error_count = "{labels.failure_url_error_count}"; + + /** The key of the message: Failure URL Details */ + public static final String LABELS_failure_url_title_confirm = "{labels.failure_url_title_confirm}"; + + /** The key of the message: ID */ + public static final String LABELS_failure_url_id = "{labels.failure_url_id}"; + + /** The key of the message: Thread Name */ + public static final String LABELS_failure_url_thread_name = "{labels.failure_url_thread_name}"; + + /** The key of the message: Type */ + public static final String LABELS_failure_url_error_name = "{labels.failure_url_error_name}"; + + /** The key of the message: Log */ + public static final String LABELS_failure_url_error_log = "{labels.failure_url_error_log}"; + + /** The key of the message: URL */ + public static final String LABELS_failure_url_url = "{labels.failure_url_url}"; + + /** The key of the message: Web Crawling Configuration */ + public static final String LABELS_failure_url_web_config_name = "{labels.failure_url_web_config_name}"; + + /** The key of the message: File Crawling Configuration */ + public static final String LABELS_failure_url_file_config_name = "{labels.failure_url_file_config_name}"; + + /** The key of the message: Statistics */ + public static final String LABELS_stats_configuration = "{labels.stats_configuration}"; + + /** The key of the message: Report Type */ + public static final String LABELS_stats_search_report_type = "{labels.stats_search_report_type}"; + + /** The key of the message: Term */ + public static final String LABELS_stats_search_term = "{labels.stats_search_term}"; + + /** The key of the message: From: */ + public static final String LABELS_stats_search_term_from = "{labels.stats_search_term_from}"; + + /** The key of the message: To: */ + public static final String LABELS_stats_search_term_to = "{labels.stats_search_term_to}"; + + /** The key of the message: Search */ + public static final String LABELS_stats_button_search = "{labels.stats_button_search}"; + + /** The key of the message: Reset */ + public static final String LABELS_stats_button_reset = "{labels.stats_button_reset}"; + + /** The key of the message: Search Word */ + public static final String LABELS_stats_search_word = "{labels.stats_search_word}"; + + /** The key of the message: Search Query */ + public static final String LABELS_stats_search_query = "{labels.stats_search_query}"; + + /** The key of the message: Solr Query */ + public static final String LABELS_stats_solr_query = "{labels.stats_solr_query}"; + + /** The key of the message: User Agent */ + public static final String LABELS_stats_user_agent = "{labels.stats_user_agent}"; + + /** The key of the message: Referer */ + public static final String LABELS_stats_referer = "{labels.stats_referer}"; + + /** The key of the message: Client IP */ + public static final String LABELS_stats_client_ip = "{labels.stats_client_ip}"; + + /** The key of the message: Count */ + public static final String LABELS_stats_count = "{labels.stats_count}"; + + /** The key of the message: Clicked URL */ + public static final String LABELS_stats_click_url = "{labels.stats_click_url}"; + + /** The key of the message: Voted URL */ + public static final String LABELS_stats_favorite_url = "{labels.stats_favorite_url}"; + + /** The key of the message: System Info */ + public static final String LABELS_system_info_configuration = "{labels.system_info_configuration}"; + + /** The key of the message: Env Properties */ + public static final String LABELS_system_info_env_title = "{labels.system_info_env_title}"; + + /** The key of the message: System Properties */ + public static final String LABELS_system_info_prop_title = "{labels.system_info_prop_title}"; + + /** The key of the message: Fess Properties */ + public static final String LABELS_system_info_fess_prop_title = "{labels.system_info_fess_prop_title}"; + + /** The key of the message: Properties for Bug Report */ + public static final String LABELS_system_info_bug_report_title = "{labels.system_info_bug_report_title}"; + + /** The key of the message: crawler.properties does not exist. Default values are applied. */ + public static final String LABELS_system_info_crawler_properties_does_not_exist = + "{labels.system_info_crawler_properties_does_not_exist}"; + + /** The key of the message: File Authentication */ + public static final String LABELS_file_authentication_configuration = "{labels.file_authentication_configuration}"; + + /** The key of the message: Create New */ + public static final String LABELS_file_authentication_link_create_new = "{labels.file_authentication_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_file_authentication_link_list = "{labels.file_authentication_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_file_authentication_link_create = "{labels.file_authentication_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_file_authentication_link_update = "{labels.file_authentication_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_file_authentication_link_confirm = "{labels.file_authentication_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_file_authentication_link_details = "{labels.file_authentication_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_file_authentication_link_edit = "{labels.file_authentication_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_file_authentication_link_delete = "{labels.file_authentication_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_file_authentication_link_prev_page = "{labels.file_authentication_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_file_authentication_link_next_page = "{labels.file_authentication_link_next_page}"; + + /** The key of the message: Hostname */ + public static final String LABELS_file_authentication_list_hostname = "{labels.file_authentication_list_hostname}"; + + /** The key of the message: Config Name */ + public static final String LABELS_file_authentication_list_file_crawling_config = + "{labels.file_authentication_list_file_crawling_config}"; + + /** The key of the message: Any */ + public static final String LABELS_file_authentication_any = "{labels.file_authentication_any}"; + + /** The key of the message: Create New File Config */ + public static final String LABELS_file_authentication_create_file_config = "{labels.file_authentication_create_file_config}"; + + /** The key of the message: File Authentication */ + public static final String LABELS_file_authentication_title_details = "{labels.file_authentication_title_details}"; + + /** The key of the message: Create */ + public static final String LABELS_file_authentication_button_create = "{labels.file_authentication_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_file_authentication_button_back = "{labels.file_authentication_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_file_authentication_button_confirm = "{labels.file_authentication_button_confirm}"; + + /** The key of the message: Hostname */ + public static final String LABELS_file_authentication_hostname = "{labels.file_authentication_hostname}"; + + /** The key of the message: Port */ + public static final String LABELS_file_authentication_port = "{labels.file_authentication_port}"; + + /** The key of the message: Scheme */ + public static final String LABELS_file_authentication_scheme = "{labels.file_authentication_scheme}"; + + /** The key of the message: Username */ + public static final String LABELS_file_authentication_username = "{labels.file_authentication_username}"; + + /** The key of the message: Password */ + public static final String LABELS_file_authentication_password = "{labels.file_authentication_password}"; + + /** The key of the message: Parameters */ + public static final String LABELS_file_authentication_parameters = "{labels.file_authentication_parameters}"; + + /** The key of the message: FS Config */ + public static final String LABELS_file_authentication_file_crawling_config = "{labels.file_authentication_file_crawling_config}"; + + /** The key of the message: Samba */ + public static final String LABELS_file_authentication_scheme_samba = "{labels.file_authentication_scheme_samba}"; + + /** The key of the message: File Authentication */ + public static final String LABELS_file_authentication_title_confirm = "{labels.file_authentication_title_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_file_authentication_button_update = "{labels.file_authentication_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_file_authentication_button_delete = "{labels.file_authentication_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_file_authentication_button_edit = "{labels.file_authentication_button_edit}"; + + /** The key of the message: {0}/{1} ({2} items) */ + public static final String LABELS_pagination_page_guide_msg = "{labels.pagination_page_guide_msg}"; + + /** The key of the message: No data. */ + public static final String LABELS_list_could_not_find_crud_table = "{labels.list_could_not_find_crud_table}"; + + /** The key of the message: User Info */ + public static final String LABELS_user_info_configuration = "{labels.user_info_configuration}"; + + /** The key of the message: User Info */ + public static final String LABELS_user_info_title = "{labels.user_info_title}"; + + /** The key of the message: Details */ + public static final String LABELS_user_info_title_confirm = "{labels.user_info_title_confirm}"; + + /** The key of the message: Search Log */ + public static final String LABELS_user_info_search_log_link = "{labels.user_info_search_log_link}"; + + /** The key of the message: Favorite Log */ + public static final String LABELS_user_info_favorite_log_link = "{labels.user_info_favorite_log_link}"; + + /** The key of the message: User ID */ + public static final String LABELS_user_info_search_code = "{labels.user_info_search_code}"; + + /** The key of the message: User ID */ + public static final String LABELS_user_info_list_code = "{labels.user_info_list_code}"; + + /** The key of the message: Last Accessed */ + public static final String LABELS_user_info_list_lastupdated = "{labels.user_info_list_lastupdated}"; + + /** The key of the message: User ID */ + public static final String LABELS_user_info_edit_code = "{labels.user_info_edit_code}"; + + /** The key of the message: Created */ + public static final String LABELS_user_info_edit_createddate = "{labels.user_info_edit_createddate}"; + + /** The key of the message: Last Accessed */ + public static final String LABELS_user_info_edit_lastupdated = "{labels.user_info_edit_lastupdated}"; + + /** The key of the message: Delete All */ + public static final String LABELS_user_info_delete_all_link = "{labels.user_info_delete_all_link}"; + + /** The key of the message: Do you want to delete all? */ + public static final String LABELS_user_info_delete_all_confirmation = "{labels.user_info_delete_all_confirmation}"; + + /** The key of the message: Popular URL */ + public static final String LABELS_favorite_log_title = "{labels.favorite_log_title}"; + + /** The key of the message: Popular URL */ + public static final String LABELS_favorite_log_configuration = "{labels.favorite_log_configuration}"; + + /** The key of the message: User ID */ + public static final String LABELS_favorite_log_user_code_search = "{labels.favorite_log_user_code_search}"; + + /** The key of the message: Search */ + public static final String LABELS_favorite_log_button_search = "{labels.favorite_log_button_search}"; + + /** The key of the message: Reset */ + public static final String LABELS_favorite_log_button_reset = "{labels.favorite_log_button_reset}"; + + /** The key of the message: URL */ + public static final String LABELS_favorite_log_url = "{labels.favorite_log_url}"; + + /** The key of the message: Submitted */ + public static final String LABELS_favorite_log_created_time = "{labels.favorite_log_created_time}"; + + /** The key of the message: Details */ + public static final String LABELS_favorite_log_link_details = "{labels.favorite_log_link_details}"; + + /** The key of the message: Delete */ + public static final String LABELS_favorite_log_link_delete = "{labels.favorite_log_link_delete}"; + + /** The key of the message: Delete All */ + public static final String LABELS_favorite_log_delete_all_link = "{labels.favorite_log_delete_all_link}"; + + /** The key of the message: Do you want to delete it? */ + public static final String LABELS_favorite_log_delete_all_confirmation = "{labels.favorite_log_delete_all_confirmation}"; + + /** The key of the message: Download (CSV) */ + public static final String LABELS_favorite_log_download_csv = "{labels.favorite_log_download_csv}"; + + /** The key of the message: Term */ + public static final String LABELS_favorite_log_search_term = "{labels.favorite_log_search_term}"; + + /** The key of the message: Details */ + public static final String LABELS_favorite_log_title_confirm = "{labels.favorite_log_title_confirm}"; + + /** The key of the message: ID */ + public static final String LABELS_favorite_log_id = "{labels.favorite_log_id}"; + + /** The key of the message: Managed Jobs */ + public static final String LABELS_scheduledjob_configuration = "{labels.scheduledjob_configuration}"; + + /** The key of the message: Jobs */ + public static final String LABELS_scheduledjob_title_details = "{labels.scheduledjob_title_details}"; + + /** The key of the message: Confirm */ + public static final String LABELS_scheduledjob_button_confirm = "{labels.scheduledjob_button_confirm}"; + + /** The key of the message: Name */ + public static final String LABELS_scheduledjob_name = "{labels.scheduledjob_name}"; + + /** The key of the message: Target */ + public static final String LABELS_scheduledjob_target = "{labels.scheduledjob_target}"; + + /** The key of the message: Status */ + public static final String LABELS_scheduledjob_status = "{labels.scheduledjob_status}"; + + /** The key of the message: Schedule */ + public static final String LABELS_scheduledjob_cronExpression = "{labels.scheduledjob_cronExpression}"; + + /** The key of the message: Executor */ + public static final String LABELS_scheduledjob_scriptType = "{labels.scheduledjob_scriptType}"; + + /** The key of the message: Script */ + public static final String LABELS_scheduledjob_scriptData = "{labels.scheduledjob_scriptData}"; + + /** The key of the message: Logging */ + public static final String LABELS_scheduledjob_jobLogging = "{labels.scheduledjob_jobLogging}"; + + /** The key of the message: Crawler Job */ + public static final String LABELS_scheduledjob_crawler = "{labels.scheduledjob_crawler}"; + + /** The key of the message: Running */ + public static final String LABELS_scheduledjob_running = "{labels.scheduledjob_running}"; + + /** The key of the message: Active */ + public static final String LABELS_scheduledjob_active = "{labels.scheduledjob_active}"; + + /** The key of the message: - */ + public static final String LABELS_scheduledjob_nojob = "{labels.scheduledjob_nojob}"; + + /** The key of the message: Confirm Job */ + public static final String LABELS_scheduledjob_title_confirm = "{labels.scheduledjob_title_confirm}"; + + /** The key of the message: Create */ + public static final String LABELS_scheduledjob_button_create = "{labels.scheduledjob_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_scheduledjob_button_back = "{labels.scheduledjob_button_back}"; + + /** The key of the message: Update */ + public static final String LABELS_scheduledjob_button_update = "{labels.scheduledjob_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_scheduledjob_button_delete = "{labels.scheduledjob_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_scheduledjob_button_edit = "{labels.scheduledjob_button_edit}"; + + /** The key of the message: Start */ + public static final String LABELS_scheduledjob_button_start = "{labels.scheduledjob_button_start}"; + + /** The key of the message: Stop */ + public static final String LABELS_scheduledjob_button_stop = "{labels.scheduledjob_button_stop}"; + + /** The key of the message: Create New */ + public static final String LABELS_scheduledjob_link_create_new = "{labels.scheduledjob_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_scheduledjob_link_list = "{labels.scheduledjob_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_scheduledjob_link_create = "{labels.scheduledjob_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_scheduledjob_link_update = "{labels.scheduledjob_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_scheduledjob_link_confirm = "{labels.scheduledjob_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_scheduledjob_link_details = "{labels.scheduledjob_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_scheduledjob_link_edit = "{labels.scheduledjob_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_scheduledjob_link_delete = "{labels.scheduledjob_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_scheduledjob_link_prev_page = "{labels.scheduledjob_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_scheduledjob_link_next_page = "{labels.scheduledjob_link_next_page}"; + + /** The key of the message: Back */ + public static final String LABELS_joblog_button_back = "{labels.joblog_button_back}"; + + /** The key of the message: Create */ + public static final String LABELS_joblog_button_create = "{labels.joblog_button_create}"; + + /** The key of the message: Delete */ + public static final String LABELS_joblog_button_delete = "{labels.joblog_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_joblog_button_edit = "{labels.joblog_button_edit}"; + + /** The key of the message: Update */ + public static final String LABELS_joblog_button_update = "{labels.joblog_button_update}"; + + /** The key of the message: Job Log */ + public static final String LABELS_joblog_configuration = "{labels.joblog_configuration}"; + + /** The key of the message: End Time */ + public static final String LABELS_joblog_endTime = "{labels.joblog_endTime}"; + + /** The key of the message: Job Log */ + public static final String LABELS_joblog_jobLogging = "{labels.joblog_jobLogging}"; + + /** The key of the message: Name */ + public static final String LABELS_joblog_jobName = "{labels.joblog_jobName}"; + + /** The key of the message: Status */ + public static final String LABELS_joblog_jobStatus = "{labels.joblog_jobStatus}"; + + /** The key of the message: Confirm */ + public static final String LABELS_joblog_link_confirm = "{labels.joblog_link_confirm}"; + + /** The key of the message: Create New */ + public static final String LABELS_joblog_link_create = "{labels.joblog_link_create}"; + + /** The key of the message: Create New */ + public static final String LABELS_joblog_link_create_new = "{labels.joblog_link_create_new}"; + + /** The key of the message: Delete */ + public static final String LABELS_joblog_link_delete = "{labels.joblog_link_delete}"; + + /** The key of the message: Details */ + public static final String LABELS_joblog_link_details = "{labels.joblog_link_details}"; + + /** The key of the message: List */ + public static final String LABELS_joblog_link_list = "{labels.joblog_link_list}"; + + /** The key of the message: Next */ + public static final String LABELS_joblog_link_next_page = "{labels.joblog_link_next_page}"; + + /** The key of the message: Prev */ + public static final String LABELS_joblog_link_prev_page = "{labels.joblog_link_prev_page}"; + + /** The key of the message: Edit */ + public static final String LABELS_joblog_link_update = "{labels.joblog_link_update}"; + + /** The key of the message: Script */ + public static final String LABELS_joblog_scriptData = "{labels.joblog_scriptData}"; + + /** The key of the message: Result */ + public static final String LABELS_joblog_scriptResult = "{labels.joblog_scriptResult}"; + + /** The key of the message: Executor */ + public static final String LABELS_joblog_scriptType = "{labels.joblog_scriptType}"; + + /** The key of the message: Start Time */ + public static final String LABELS_joblog_startTime = "{labels.joblog_startTime}"; + + /** The key of the message: Target */ + public static final String LABELS_joblog_target = "{labels.joblog_target}"; + + /** The key of the message: Confirm Job Log */ + public static final String LABELS_joblog_title_confirm = "{labels.joblog_title_confirm}"; + + /** The key of the message: Job Log Details */ + public static final String LABELS_joblog_title_details = "{labels.joblog_title_details}"; + + /** The key of the message: Job Log List */ + public static final String LABELS_joblog_title_list = "{labels.joblog_title_list}"; + + /** The key of the message: Delete All */ + public static final String LABELS_joblog_delete_all_link = "{labels.joblog_delete_all_link}"; + + /** The key of the message: Do you want to delete all? */ + public static final String LABELS_joblog_delete_all_confirmation = "{labels.joblog_delete_all_confirmation}"; + + /** The key of the message: Dictionary List */ + public static final String LABELS_dict_configuration = "{labels.dict_configuration}"; + + /** The key of the message: Dictionary List */ + public static final String LABELS_dict_list_title = "{labels.dict_list_title}"; + + /** The key of the message: Dictionaries */ + public static final String LABELS_dict_list_link = "{labels.dict_list_link}"; + + /** The key of the message: Name */ + public static final String LABELS_dictionary_name = "{labels.dictionary_name}"; + + /** The key of the message: Type */ + public static final String LABELS_dictionary_type = "{labels.dictionary_type}"; + + /** The key of the message: Details */ + public static final String LABELS_dict_link_details = "{labels.dict_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_dict_link_edit = "{labels.dict_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_dict_link_delete = "{labels.dict_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_dict_link_prev_page = "{labels.dict_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_dict_link_next_page = "{labels.dict_link_next_page}"; + + /** The key of the message: Back */ + public static final String LABELS_dict_button_back = "{labels.dict_button_back}"; + + /** The key of the message: Synonym List */ + public static final String LABELS_dict_synonym_configuration = "{labels.dict_synonym_configuration}"; + + /** The key of the message: Synonym List */ + public static final String LABELS_dict_synonym_title = "{labels.dict_synonym_title}"; + + /** The key of the message: List */ + public static final String LABELS_dict_synonym_list_link = "{labels.dict_synonym_list_link}"; + + /** The key of the message: Create New */ + public static final String LABELS_dict_synonym_link_create = "{labels.dict_synonym_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_dict_synonym_link_update = "{labels.dict_synonym_link_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_dict_synonym_link_delete = "{labels.dict_synonym_link_delete}"; + + /** The key of the message: Confirm */ + public static final String LABELS_dict_synonym_link_confirm = "{labels.dict_synonym_link_confirm}"; + + /** The key of the message: Download */ + public static final String LABELS_dict_synonym_link_download = "{labels.dict_synonym_link_download}"; + + /** The key of the message: Upload */ + public static final String LABELS_dict_synonym_link_upload = "{labels.dict_synonym_link_upload}"; + + /** The key of the message: Source */ + public static final String LABELS_dict_synonym_source = "{labels.dict_synonym_source}"; + + /** The key of the message: Target */ + public static final String LABELS_dict_synonym_target = "{labels.dict_synonym_target}"; + + /** The key of the message: Create */ + public static final String LABELS_dict_synonym_button_create = "{labels.dict_synonym_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_dict_synonym_button_back = "{labels.dict_synonym_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_dict_synonym_button_confirm = "{labels.dict_synonym_button_confirm}"; + + /** The key of the message: Edit */ + public static final String LABELS_dict_synonym_button_edit = "{labels.dict_synonym_button_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_dict_synonym_button_delete = "{labels.dict_synonym_button_delete}"; + + /** The key of the message: Update */ + public static final String LABELS_dict_synonym_button_update = "{labels.dict_synonym_button_update}"; + + /** The key of the message: Download */ + public static final String LABELS_dict_synonym_button_download = "{labels.dict_synonym_button_download}"; + + /** The key of the message: Upload */ + public static final String LABELS_dict_synonym_button_upload = "{labels.dict_synonym_button_upload}"; + + /** The key of the message: Synonym File */ + public static final String LABELS_dict_synonym_file = "{labels.dict_synonym_file}"; + + /** The key of the message: UserDict List */ + public static final String LABELS_dict_userdict_configuration = "{labels.dict_userdict_configuration}"; + + /** The key of the message: UserDict List */ + public static final String LABELS_dict_userdict_title = "{labels.dict_userdict_title}"; + + /** The key of the message: List */ + public static final String LABELS_dict_userdict_list_link = "{labels.dict_userdict_list_link}"; + + /** The key of the message: Create New */ + public static final String LABELS_dict_userdict_link_create = "{labels.dict_userdict_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_dict_userdict_link_update = "{labels.dict_userdict_link_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_dict_userdict_link_delete = "{labels.dict_userdict_link_delete}"; + + /** The key of the message: Confirm */ + public static final String LABELS_dict_userdict_link_confirm = "{labels.dict_userdict_link_confirm}"; + + /** The key of the message: Download */ + public static final String LABELS_dict_userdict_link_download = "{labels.dict_userdict_link_download}"; + + /** The key of the message: Upload */ + public static final String LABELS_dict_userdict_link_upload = "{labels.dict_userdict_link_upload}"; + + /** The key of the message: Token */ + public static final String LABELS_dict_userdict_token = "{labels.dict_userdict_token}"; + + /** The key of the message: Segmentation */ + public static final String LABELS_dict_userdict_segmentation = "{labels.dict_userdict_segmentation}"; + + /** The key of the message: Reading */ + public static final String LABELS_dict_userdict_reading = "{labels.dict_userdict_reading}"; + + /** The key of the message: POS */ + public static final String LABELS_dict_userdict_pos = "{labels.dict_userdict_pos}"; + + /** The key of the message: Create */ + public static final String LABELS_dict_userdict_button_create = "{labels.dict_userdict_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_dict_userdict_button_back = "{labels.dict_userdict_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_dict_userdict_button_confirm = "{labels.dict_userdict_button_confirm}"; + + /** The key of the message: Edit */ + public static final String LABELS_dict_userdict_button_edit = "{labels.dict_userdict_button_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_dict_userdict_button_delete = "{labels.dict_userdict_button_delete}"; + + /** The key of the message: Update */ + public static final String LABELS_dict_userdict_button_update = "{labels.dict_userdict_button_update}"; + + /** The key of the message: Download */ + public static final String LABELS_dict_userdict_button_download = "{labels.dict_userdict_button_download}"; + + /** The key of the message: Upload */ + public static final String LABELS_dict_userdict_button_upload = "{labels.dict_userdict_button_upload}"; + + /** The key of the message: UserDict File */ + public static final String LABELS_dict_userdict_file = "{labels.dict_userdict_file}"; + + /** The key of the message: Doc Boost */ + public static final String LABELS_boost_document_rule_configuration = "{labels.boost_document_rule_configuration}"; + + /** The key of the message: Doc Boost */ + public static final String LABELS_boost_document_rule_title_list = "{labels.boost_document_rule_title_list}"; + + /** The key of the message: Confirm Doc Boost */ + public static final String LABELS_boost_document_rule_title_confirm = "{labels.boost_document_rule_title_confirm}"; + + /** The key of the message: Doc Boost */ + public static final String LABELS_boost_document_rule_title_details = "{labels.boost_document_rule_title_details}"; + + /** The key of the message: List */ + public static final String LABELS_boost_document_rule_link_list = "{labels.boost_document_rule_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_boost_document_rule_link_create_new = "{labels.boost_document_rule_link_create_new}"; + + /** The key of the message: Details */ + public static final String LABELS_boost_document_rule_link_details = "{labels.boost_document_rule_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_boost_document_rule_link_edit = "{labels.boost_document_rule_link_edit}"; + + /** The key of the message: Prev */ + public static final String LABELS_boost_document_rule_link_prev_page = "{labels.boost_document_rule_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_boost_document_rule_link_next_page = "{labels.boost_document_rule_link_next_page}"; + + /** The key of the message: Create */ + public static final String LABELS_boost_document_rule_link_create = "{labels.boost_document_rule_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_boost_document_rule_link_update = "{labels.boost_document_rule_link_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_boost_document_rule_link_delete = "{labels.boost_document_rule_link_delete}"; + + /** The key of the message: Details */ + public static final String LABELS_boost_document_rule_link_confirm = "{labels.boost_document_rule_link_confirm}"; + + /** The key of the message: Create */ + public static final String LABELS_boost_document_rule_button_create = "{labels.boost_document_rule_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_boost_document_rule_button_back = "{labels.boost_document_rule_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_boost_document_rule_button_confirm = "{labels.boost_document_rule_button_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_boost_document_rule_button_update = "{labels.boost_document_rule_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_boost_document_rule_button_delete = "{labels.boost_document_rule_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_boost_document_rule_button_edit = "{labels.boost_document_rule_button_edit}"; + + /** The key of the message: Condition */ + public static final String LABELS_boost_document_rule_list_url_expr = "{labels.boost_document_rule_list_url_expr}"; + + /** The key of the message: Condition */ + public static final String LABELS_boost_document_rule_url_expr = "{labels.boost_document_rule_url_expr}"; + + /** The key of the message: Boost Expr */ + public static final String LABELS_boost_document_rule_boost_expr = "{labels.boost_document_rule_boost_expr}"; + + /** The key of the message: Sort Order */ + public static final String LABELS_boost_document_rule_sort_order = "{labels.boost_document_rule_sort_order}"; + + /** The key of the message: Additional Word */ + public static final String LABELS_suggest_elevate_word_configuration = "{labels.suggest_elevate_word_configuration}"; + + /** The key of the message: Additional Word */ + public static final String LABELS_suggest_elevate_word_title_list = "{labels.suggest_elevate_word_title_list}"; + + /** The key of the message: Confirm Additional Word */ + public static final String LABELS_suggest_elevate_word_title_confirm = "{labels.suggest_elevate_word_title_confirm}"; + + /** The key of the message: Additional Word */ + public static final String LABELS_suggest_elevate_word_title_details = "{labels.suggest_elevate_word_title_details}"; + + /** The key of the message: List */ + public static final String LABELS_suggest_elevate_word_link_list = "{labels.suggest_elevate_word_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_suggest_elevate_word_link_create_new = "{labels.suggest_elevate_word_link_create_new}"; + + /** The key of the message: Details */ + public static final String LABELS_suggest_elevate_word_link_details = "{labels.suggest_elevate_word_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_suggest_elevate_word_link_edit = "{labels.suggest_elevate_word_link_edit}"; + + /** The key of the message: Prev */ + public static final String LABELS_suggest_elevate_word_link_prev_page = "{labels.suggest_elevate_word_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_suggest_elevate_word_link_next_page = "{labels.suggest_elevate_word_link_next_page}"; + + /** The key of the message: Create */ + public static final String LABELS_suggest_elevate_word_link_create = "{labels.suggest_elevate_word_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_suggest_elevate_word_link_update = "{labels.suggest_elevate_word_link_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_suggest_elevate_word_link_delete = "{labels.suggest_elevate_word_link_delete}"; + + /** The key of the message: Details */ + public static final String LABELS_suggest_elevate_word_link_confirm = "{labels.suggest_elevate_word_link_confirm}"; + + /** The key of the message: Download */ + public static final String LABELS_suggest_elevate_word_link_download = "{labels.suggest_elevate_word_link_download}"; + + /** The key of the message: Upload */ + public static final String LABELS_suggest_elevate_word_link_upload = "{labels.suggest_elevate_word_link_upload}"; + + /** The key of the message: Create */ + public static final String LABELS_suggest_elevate_word_button_create = "{labels.suggest_elevate_word_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_suggest_elevate_word_button_back = "{labels.suggest_elevate_word_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_suggest_elevate_word_button_confirm = "{labels.suggest_elevate_word_button_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_suggest_elevate_word_button_update = "{labels.suggest_elevate_word_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_suggest_elevate_word_button_delete = "{labels.suggest_elevate_word_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_suggest_elevate_word_button_edit = "{labels.suggest_elevate_word_button_edit}"; + + /** The key of the message: Download */ + public static final String LABELS_suggest_elevate_word_button_download = "{labels.suggest_elevate_word_button_download}"; + + /** The key of the message: Upload */ + public static final String LABELS_suggest_elevate_word_button_upload = "{labels.suggest_elevate_word_button_upload}"; + + /** The key of the message: Word */ + public static final String LABELS_suggest_elevate_word_list_suggest_word = "{labels.suggest_elevate_word_list_suggest_word}"; + + /** The key of the message: Word */ + public static final String LABELS_suggest_elevate_word_suggest_word = "{labels.suggest_elevate_word_suggest_word}"; + + /** The key of the message: Reading */ + public static final String LABELS_suggest_elevate_word_reading = "{labels.suggest_elevate_word_reading}"; + + /** The key of the message: Role */ + public static final String LABELS_suggest_elevate_word_target_role = "{labels.suggest_elevate_word_target_role}"; + + /** The key of the message: Label */ + public static final String LABELS_suggest_elevate_word_target_label = "{labels.suggest_elevate_word_target_label}"; + + /** The key of the message: Boost */ + public static final String LABELS_suggest_elevate_word_boost = "{labels.suggest_elevate_word_boost}"; + + /** The key of the message: Additional Word File */ + public static final String LABELS_suggest_elevate_word_file = "{labels.suggest_elevate_word_file}"; + + /** The key of the message: Bad Word */ + public static final String LABELS_suggest_bad_word_configuration = "{labels.suggest_bad_word_configuration}"; + + /** The key of the message: Bad Word */ + public static final String LABELS_suggest_bad_word_title_list = "{labels.suggest_bad_word_title_list}"; + + /** The key of the message: Confirm Bad Word */ + public static final String LABELS_suggest_bad_word_title_confirm = "{labels.suggest_bad_word_title_confirm}"; + + /** The key of the message: Bad Word */ + public static final String LABELS_suggest_bad_word_title_details = "{labels.suggest_bad_word_title_details}"; + + /** The key of the message: List */ + public static final String LABELS_suggest_bad_word_link_list = "{labels.suggest_bad_word_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_suggest_bad_word_link_create_new = "{labels.suggest_bad_word_link_create_new}"; + + /** The key of the message: Details */ + public static final String LABELS_suggest_bad_word_link_details = "{labels.suggest_bad_word_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_suggest_bad_word_link_edit = "{labels.suggest_bad_word_link_edit}"; + + /** The key of the message: Prev */ + public static final String LABELS_suggest_bad_word_link_prev_page = "{labels.suggest_bad_word_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_suggest_bad_word_link_next_page = "{labels.suggest_bad_word_link_next_page}"; + + /** The key of the message: Create */ + public static final String LABELS_suggest_bad_word_link_create = "{labels.suggest_bad_word_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_suggest_bad_word_link_update = "{labels.suggest_bad_word_link_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_suggest_bad_word_link_delete = "{labels.suggest_bad_word_link_delete}"; + + /** The key of the message: Details */ + public static final String LABELS_suggest_bad_word_link_confirm = "{labels.suggest_bad_word_link_confirm}"; + + /** The key of the message: Download */ + public static final String LABELS_suggest_bad_word_link_download = "{labels.suggest_bad_word_link_download}"; + + /** The key of the message: Upload */ + public static final String LABELS_suggest_bad_word_link_upload = "{labels.suggest_bad_word_link_upload}"; + + /** The key of the message: Create */ + public static final String LABELS_suggest_bad_word_button_create = "{labels.suggest_bad_word_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_suggest_bad_word_button_back = "{labels.suggest_bad_word_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_suggest_bad_word_button_confirm = "{labels.suggest_bad_word_button_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_suggest_bad_word_button_update = "{labels.suggest_bad_word_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_suggest_bad_word_button_delete = "{labels.suggest_bad_word_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_suggest_bad_word_button_edit = "{labels.suggest_bad_word_button_edit}"; + + /** The key of the message: Download */ + public static final String LABELS_suggest_bad_word_button_download = "{labels.suggest_bad_word_button_download}"; + + /** The key of the message: Upload */ + public static final String LABELS_suggest_bad_word_button_upload = "{labels.suggest_bad_word_button_upload}"; + + /** The key of the message: Bad Word */ + public static final String LABELS_suggest_bad_word_list_suggest_word = "{labels.suggest_bad_word_list_suggest_word}"; + + /** The key of the message: Bad Word */ + public static final String LABELS_suggest_bad_word_suggest_word = "{labels.suggest_bad_word_suggest_word}"; + + /** The key of the message: Role */ + public static final String LABELS_suggest_bad_word_target_role = "{labels.suggest_bad_word_target_role}"; + + /** The key of the message: Label */ + public static final String LABELS_suggest_bad_word_target_label = "{labels.suggest_bad_word_target_label}"; + + /** The key of the message: Bad Word File */ + public static final String LABELS_suggest_bad_word_file = "{labels.suggest_bad_word_file}"; + + /** The key of the message: User */ + public static final String LABELS_user_configuration = "{labels.user_configuration}"; + + /** The key of the message: Create New */ + public static final String LABELS_user_link_create_new = "{labels.user_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_user_link_list = "{labels.user_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_user_link_create = "{labels.user_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_user_link_update = "{labels.user_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_user_link_confirm = "{labels.user_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_user_link_details = "{labels.user_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_user_link_edit = "{labels.user_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_user_link_delete = "{labels.user_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_user_link_prev_page = "{labels.user_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_user_link_next_page = "{labels.user_link_next_page}"; + + /** The key of the message: Name */ + public static final String LABELS_user_list_name = "{labels.user_list_name}"; + + /** The key of the message: Name */ + public static final String LABELS_user_name = "{labels.user_name}"; + + /** The key of the message: Password */ + public static final String LABELS_user_password = "{labels.user_password}"; + + /** The key of the message: Confirm */ + public static final String LABELS_user_confirm_password = "{labels.user_confirm_password}"; + + /** The key of the message: Role */ + public static final String LABELS_user_role = "{labels.user_role}"; + + /** The key of the message: Group */ + public static final String LABELS_user_group = "{labels.user_group}"; + + /** The key of the message: User */ + public static final String LABELS_user_title_details = "{labels.user_title_details}"; + + /** The key of the message: Create */ + public static final String LABELS_user_button_create = "{labels.user_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_user_button_back = "{labels.user_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_user_button_confirm = "{labels.user_button_confirm}"; + + /** The key of the message: Confirm User */ + public static final String LABELS_user_title_confirm = "{labels.user_title_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_user_button_update = "{labels.user_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_user_button_delete = "{labels.user_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_user_button_edit = "{labels.user_button_edit}"; + + /** The key of the message: Role */ + public static final String LABELS_role_configuration = "{labels.role_configuration}"; + + /** The key of the message: Create New */ + public static final String LABELS_role_link_create_new = "{labels.role_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_role_link_list = "{labels.role_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_role_link_create = "{labels.role_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_role_link_update = "{labels.role_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_role_link_confirm = "{labels.role_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_role_link_details = "{labels.role_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_role_link_edit = "{labels.role_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_role_link_delete = "{labels.role_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_role_link_prev_page = "{labels.role_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_role_link_next_page = "{labels.role_link_next_page}"; + + /** The key of the message: Name */ + public static final String LABELS_role_list_name = "{labels.role_list_name}"; + + /** The key of the message: Name */ + public static final String LABELS_role_name = "{labels.role_name}"; + + /** The key of the message: Role */ + public static final String LABELS_role_title_details = "{labels.role_title_details}"; + + /** The key of the message: Create */ + public static final String LABELS_role_button_create = "{labels.role_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_role_button_back = "{labels.role_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_role_button_confirm = "{labels.role_button_confirm}"; + + /** The key of the message: Confirm Role */ + public static final String LABELS_role_title_confirm = "{labels.role_title_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_role_button_update = "{labels.role_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_role_button_delete = "{labels.role_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_role_button_edit = "{labels.role_button_edit}"; + + /** The key of the message: group */ + public static final String LABELS_group_configuration = "{labels.group_configuration}"; + + /** The key of the message: Create New */ + public static final String LABELS_group_link_create_new = "{labels.group_link_create_new}"; + + /** The key of the message: List */ + public static final String LABELS_group_link_list = "{labels.group_link_list}"; + + /** The key of the message: Create New */ + public static final String LABELS_group_link_create = "{labels.group_link_create}"; + + /** The key of the message: Edit */ + public static final String LABELS_group_link_update = "{labels.group_link_update}"; + + /** The key of the message: Details */ + public static final String LABELS_group_link_confirm = "{labels.group_link_confirm}"; + + /** The key of the message: Details */ + public static final String LABELS_group_link_details = "{labels.group_link_details}"; + + /** The key of the message: Edit */ + public static final String LABELS_group_link_edit = "{labels.group_link_edit}"; + + /** The key of the message: Delete */ + public static final String LABELS_group_link_delete = "{labels.group_link_delete}"; + + /** The key of the message: Prev */ + public static final String LABELS_group_link_prev_page = "{labels.group_link_prev_page}"; + + /** The key of the message: Next */ + public static final String LABELS_group_link_next_page = "{labels.group_link_next_page}"; + + /** The key of the message: Name */ + public static final String LABELS_group_list_name = "{labels.group_list_name}"; + + /** The key of the message: Name */ + public static final String LABELS_group_name = "{labels.group_name}"; + + /** The key of the message: Group */ + public static final String LABELS_group_title_details = "{labels.group_title_details}"; + + /** The key of the message: Create */ + public static final String LABELS_group_button_create = "{labels.group_button_create}"; + + /** The key of the message: Back */ + public static final String LABELS_group_button_back = "{labels.group_button_back}"; + + /** The key of the message: Confirm */ + public static final String LABELS_group_button_confirm = "{labels.group_button_confirm}"; + + /** The key of the message: Confirm Group */ + public static final String LABELS_group_title_confirm = "{labels.group_title_confirm}"; + + /** The key of the message: Update */ + public static final String LABELS_group_button_update = "{labels.group_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_group_button_delete = "{labels.group_button_delete}"; + + /** The key of the message: Edit */ + public static final String LABELS_group_button_edit = "{labels.group_button_edit}"; + + /** The key of the message: Roles */ + public static final String LABELS_ROLES = "{labels.roles}"; + + /** The key of the message: Groups */ + public static final String LABELS_GROUPS = "{labels.groups}"; + + /** The key of the message: Create */ + public static final String LABELS_crud_button_create = "{labels.crud_button_create}"; + + /** The key of the message: Update */ + public static final String LABELS_crud_button_update = "{labels.crud_button_update}"; + + /** The key of the message: Delete */ + public static final String LABELS_crud_button_delete = "{labels.crud_button_delete}"; + + /** The key of the message: Back */ + public static final String LABELS_crud_button_back = "{labels.crud_button_back}"; + + /** The key of the message: Edit */ + public static final String LABELS_crud_button_edit = "{labels.crud_button_edit}"; + + /** The key of the message: Confirm */ + public static final String LABELS_crud_button_confirm = "{labels.crud_button_confirm}"; + + /** The key of the message: Search */ + public static final String LABELS_crud_button_search = "{labels.crud_button_search}"; + + /** The key of the message: Reset */ + public static final String LABELS_crud_button_reset = "{labels.crud_button_reset}"; + + /** The key of the message: Create New */ + public static final String LABELS_crud_link_create_new = "{labels.crud_link_create_new}"; + + /** The key of the message: Delete */ + public static final String LABELS_crud_link_delete = "{labels.crud_link_delete}"; + + /** The key of the message: Back */ + public static final String LABELS_crud_link_back = "{labels.crud_link_back}"; + + /** The key of the message: Edit */ + public static final String LABELS_crud_link_edit = "{labels.crud_link_edit}"; + + /** The key of the message: Next */ + public static final String LABELS_crud_link_next_page = "{labels.crud_link_next_page}"; + + /** The key of the message: Back */ + public static final String LABELS_crud_link_prev_page = "{labels.crud_link_prev_page}"; + + /** The key of the message: Details */ + public static final String LABELS_crud_title_details = "{labels.crud_title_details}"; + + /** The key of the message: Confirmation */ + public static final String LABELS_crud_title_confirm = "{labels.crud_title_confirm}"; + + /** The key of the message: */ + public static final String LABELS_LABEL_TYPE_IDS = "{labels.labelTypeIds}"; + + /** + * Assert the property is not null. + * @param property The value of the property. (NotNull) + */ + protected void assertPropertyNotNull(String property) { + if (property == null) { + String msg = "The argument 'property' for message should not be null."; + throw new IllegalArgumentException(msg); + } + } +} diff --git a/src/main/java/org/codelibs/fess/mylasta/action/FessMessages.java b/src/main/java/org/codelibs/fess/mylasta/action/FessMessages.java new file mode 100644 index 000000000..8574df778 --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/action/FessMessages.java @@ -0,0 +1,3165 @@ +package org.codelibs.fess.mylasta.action; + +import org.lastaflute.web.ruts.message.ActionMessage; + +/** + * The keys for message. + * @author FreeGen + */ +public class FessMessages extends FessLabels { + + /** The serial version UID for object serialization. (Default) */ + private static final long serialVersionUID = 1L; + + /** The key of the message: must be false */ + public static final String CONSTRAINTS_AssertFalse_MESSAGE = "{constraints.AssertFalse.message}"; + + /** The key of the message: must be true */ + public static final String CONSTRAINTS_AssertTrue_MESSAGE = "{constraints.AssertTrue.message}"; + + /** The key of the message: must be less than ${inclusive == true ? 'or equal to ' : ''}{value} */ + public static final String CONSTRAINTS_DecimalMax_MESSAGE = "{constraints.DecimalMax.message}"; + + /** The key of the message: must be greater than ${inclusive == true ? 'or equal to ' : ''}{value} */ + public static final String CONSTRAINTS_DecimalMin_MESSAGE = "{constraints.DecimalMin.message}"; + + /** The key of the message: numeric value out of bounds (<{integer} digits>.<{fraction} digits> expected) */ + public static final String CONSTRAINTS_Digits_MESSAGE = "{constraints.Digits.message}"; + + /** The key of the message: must be in the future */ + public static final String CONSTRAINTS_Future_MESSAGE = "{constraints.Future.message}"; + + /** The key of the message: must be less than or equal to {value} */ + public static final String CONSTRAINTS_Max_MESSAGE = "{constraints.Max.message}"; + + /** The key of the message: must be greater than or equal to {value} */ + public static final String CONSTRAINTS_Min_MESSAGE = "{constraints.Min.message}"; + + /** The key of the message: may not be null */ + public static final String CONSTRAINTS_NotNull_MESSAGE = "{constraints.NotNull.message}"; + + /** The key of the message: must be null */ + public static final String CONSTRAINTS_Null_MESSAGE = "{constraints.Null.message}"; + + /** The key of the message: must be in the past */ + public static final String CONSTRAINTS_Past_MESSAGE = "{constraints.Past.message}"; + + /** The key of the message: must match "{regexp}" */ + public static final String CONSTRAINTS_Pattern_MESSAGE = "{constraints.Pattern.message}"; + + /** The key of the message: size must be between {min} and {max} */ + public static final String CONSTRAINTS_Size_MESSAGE = "{constraints.Size.message}"; + + /** The key of the message: invalid credit card number */ + public static final String CONSTRAINTS_CreditCardNumber_MESSAGE = "{constraints.CreditCardNumber.message}"; + + /** The key of the message: invalid {type} barcode */ + public static final String CONSTRAINTS_EAN_MESSAGE = "{constraints.EAN.message}"; + + /** The key of the message: not a well-formed email address */ + public static final String CONSTRAINTS_Email_MESSAGE = "{constraints.Email.message}"; + + /** The key of the message: length must be between {min} and {max} */ + public static final String CONSTRAINTS_Length_MESSAGE = "{constraints.Length.message}"; + + /** The key of the message: The check digit for ${value} is invalid, Luhn Modulo 10 checksum failed */ + public static final String CONSTRAINTS_LuhnCheck_MESSAGE = "{constraints.LuhnCheck.message}"; + + /** The key of the message: The check digit for ${value} is invalid, Modulo 10 checksum failed */ + public static final String CONSTRAINTS_Mod10Check_MESSAGE = "{constraints.Mod10Check.message}"; + + /** The key of the message: The check digit for ${value} is invalid, Modulo 11 checksum failed */ + public static final String CONSTRAINTS_Mod11Check_MESSAGE = "{constraints.Mod11Check.message}"; + + /** The key of the message: The check digit for ${value} is invalid, ${modType} checksum failed */ + public static final String CONSTRAINTS_ModCheck_MESSAGE = "{constraints.ModCheck.message}"; + + /** The key of the message: may not be empty */ + public static final String CONSTRAINTS_NotBlank_MESSAGE = "{constraints.NotBlank.message}"; + + /** The key of the message: may not be empty */ + public static final String CONSTRAINTS_NotEmpty_MESSAGE = "{constraints.NotEmpty.message}"; + + /** The key of the message: script expression "{script}" didn't evaluate to true */ + public static final String CONSTRAINTS_ParametersScriptAssert_MESSAGE = "{constraints.ParametersScriptAssert.message}"; + + /** The key of the message: must be between {min} and {max} */ + public static final String CONSTRAINTS_Range_MESSAGE = "{constraints.Range.message}"; + + /** The key of the message: may have unsafe html content */ + public static final String CONSTRAINTS_SafeHtml_MESSAGE = "{constraints.SafeHtml.message}"; + + /** The key of the message: script expression "{script}" didn't evaluate to true */ + public static final String CONSTRAINTS_ScriptAssert_MESSAGE = "{constraints.ScriptAssert.message}"; + + /** The key of the message: must be a valid URL */ + public static final String CONSTRAINTS_URL_MESSAGE = "{constraints.URL.message}"; + + /** The key of the message: is required */ + public static final String CONSTRAINTS_Required_MESSAGE = "{constraints.Required.message}"; + + /** The key of the message: could not login */ + public static final String ERRORS_LOGIN_FAILURE = "{errors.login.failure}"; + + /** The key of the message: retry because of illegal transition */ + public static final String ERRORS_APP_ILLEGAL_TRANSITION = "{errors.app.illegal.transition}"; + + /** The key of the message: others might be updated, so retry */ + public static final String ERRORS_APP_DB_ALREADY_DELETED = "{errors.app.db.already.deleted}"; + + /** The key of the message: others might be updated, so retry */ + public static final String ERRORS_APP_DB_ALREADY_UPDATED = "{errors.app.db.already.updated}"; + + /** The key of the message: already existing data, so retry */ + public static final String ERRORS_APP_DB_ALREADY_EXISTS = "{errors.app.db.already.exists}"; + + /** The key of the message:
    */ + public static final String ERRORS_front_header = "{errors.front_header}"; + + /** The key of the message:
    */ + public static final String ERRORS_front_footer = "{errors.front_footer}"; + + /** The key of the message:
    */ + public static final String ERRORS_front_prefix = "{errors.front_prefix}"; + + /** The key of the message:
    */ + public static final String ERRORS_front_suffix = "{errors.front_suffix}"; + + /** The key of the message:
    */ + public static final String ERRORS_HEADER = "{errors.header}"; + + /** The key of the message:
    */ + public static final String ERRORS_FOOTER = "{errors.footer}"; + + /** The key of the message:

    */ + public static final String ERRORS_PREFIX = "{errors.prefix}"; + + /** The key of the message:

    */ + public static final String ERRORS_SUFFIX = "{errors.suffix}"; + + /** The key of the message: {0} is invalid. */ + public static final String ERRORS_INVALID = "{errors.invalid}"; + + /** The key of the message: {0} can not be greater than {1} characters. */ + public static final String ERRORS_MAXLENGTH = "{errors.maxlength}"; + + /** The key of the message: {0} can not be less than {1} characters. */ + public static final String ERRORS_MINLENGTH = "{errors.minlength}"; + + /** The key of the message: {0} can not be greater than {1} bytes. */ + public static final String ERRORS_MAXBYTELENGTH = "{errors.maxbytelength}"; + + /** The key of the message: {0} can not be less than {1} bytes. */ + public static final String ERRORS_MINBYTELENGTH = "{errors.minbytelength}"; + + /** The key of the message: {0} is not in the range {1} through {2}. */ + public static final String ERRORS_RANGE = "{errors.range}"; + + /** The key of the message: {0} is required. */ + public static final String ERRORS_REQUIRED = "{errors.required}"; + + /** The key of the message: {0} must be an byte. */ + public static final String ERRORS_BYTE = "{errors.byte}"; + + /** The key of the message: {0} is not a date. */ + public static final String ERRORS_DATE = "{errors.date}"; + + /** The key of the message: {0} must be an double. */ + public static final String ERRORS_DOUBLE = "{errors.double}"; + + /** The key of the message: {0} must be an float. */ + public static final String ERRORS_FLOAT = "{errors.float}"; + + /** The key of the message: {0} must be an integer. */ + public static final String ERRORS_INTEGER = "{errors.integer}"; + + /** The key of the message: {0} must be an long. */ + public static final String ERRORS_LONG = "{errors.long}"; + + /** The key of the message: {0} must be an short. */ + public static final String ERRORS_SHORT = "{errors.short}"; + + /** The key of the message: {0} is not a valid credit card number. */ + public static final String ERRORS_CREDITCARD = "{errors.creditcard}"; + + /** The key of the message: {0} is an invalid e-mail address. */ + public static final String ERRORS_EMAIL = "{errors.email}"; + + /** The key of the message: {0} is an invalid url (web address). */ + public static final String ERRORS_URL = "{errors.url}"; + + /** The key of the message: {0} is a invalid format. */ + public static final String ERRORS_CRONEXPRESSION = "{errors.cronexpression}"; + + /** The key of the message: {0} is a invalid uri. */ + public static final String ERRORS_URITYPE = "{errors.uritype}"; + + /** The key of the message: {0} must be alphabet or digit only. */ + public static final String ERRORS_ALPHA_DIGIT_ONLY = "{errors.alphaDigitOnly}"; + + /** The key of the message: {0} must be alphabet, digit, or space only. */ + public static final String ERRORS_ALPHA_DIGIT_SPACE_ONLY = "{errors.alphaDigitSpaceOnly}"; + + /** The key of the message: Invalid request. */ + public static final String ERRORS_TOKEN = "{errors.token}"; + + /** The key of the message: Failed to update parameters. Please contact to a site administrator. */ + public static final String ERRORS_failed_to_update_crawler_params = "{errors.failed_to_update_crawler_params}"; + + /** The key of the message: Failed to update parameters. Please contact to a site administrator. */ + public static final String ERRORS_failed_to_update_web_crawler_params = "{errors.failed_to_update_web_crawler_params}"; + + /** The key of the message: Failed to update parameters. Please contact to a site administrator. */ + public static final String ERRORS_failed_to_update_solr_params = "{errors.failed_to_update_solr_params}"; + + /** The key of the message: Username or Password is not correct. */ + public static final String ERROR_login_error = "{error.login_error}"; + + /** The key of the message: Failed to commit index. */ + public static final String ERRORS_failed_to_commit_solr_index = "{errors.failed_to_commit_solr_index}"; + + /** The key of the message: Failed to optimize index. */ + public static final String ERRORS_failed_to_optimize_solr_index = "{errors.failed_to_optimize_solr_index}"; + + /** The key of the message: Failed to delete index. */ + public static final String ERRORS_failed_to_delete_solr_index = "{errors.failed_to_delete_solr_index}"; + + /** The key of the message: Failed to start a process because of running solr process. */ + public static final String ERRORS_failed_to_start_solr_process_because_of_running = + "{errors.failed_to_start_solr_process_because_of_running}"; + + /** The key of the message: Failed to restore data. */ + public static final String ERRORS_failed_to_import_data = "{errors.failed_to_import_data}"; + + /** The key of the message: Unknown file type. */ + public static final String ERRORS_unknown_import_file = "{errors.unknown_import_file}"; + + /** The key of the message: Failed to backup data. */ + public static final String ERRORS_failed_to_export_data = "{errors.failed_to_export_data}"; + + /** The key of the message: Could not find {0}. */ + public static final String ERRORS_could_not_find_log_file = "{errors.could_not_find_log_file}"; + + /** The key of the message: No running crawl process. */ + public static final String ERRORS_no_running_crawl_process = "{errors.no_running_crawl_process}"; + + /** The key of the message: Failed to start a crawl process. */ + public static final String ERRORS_failed_to_start_crawl_process = "{errors.failed_to_start_crawl_process}"; + + /** The key of the message: Invalid JSP file. */ + public static final String ERRORS_invalid_design_jsp_file_name = "{errors.invalid_design_jsp_file_name}"; + + /** The key of the message: JSP file does not exist. */ + public static final String ERRORS_design_jsp_file_does_not_exist = "{errors.design_jsp_file_does_not_exist}"; + + /** The key of the message: The file name is not specified. */ + public static final String ERRORS_design_file_name_is_not_found = "{errors.design_file_name_is_not_found}"; + + /** The key of the message: Failed to upload an image file. */ + public static final String ERRORS_failed_to_write_design_image_file = "{errors.failed_to_write_design_image_file}"; + + /** The key of the message: Failed to update a jsp file. */ + public static final String ERRORS_failed_to_update_jsp_file = "{errors.failed_to_update_jsp_file}"; + + /** The key of the message: The file name is invalid. */ + public static final String ERRORS_design_file_name_is_invalid = "{errors.design_file_name_is_invalid}"; + + /** The key of the message: The kind of file is unsupported. */ + public static final String ERRORS_design_file_is_unsupported_type = "{errors.design_file_is_unsupported_type}"; + + /** The key of the message: Failed to start a solr instance. */ + public static final String ERRORS_failed_to_start_solr_instance = "{errors.failed_to_start_solr_instance}"; + + /** The key of the message: Failed to stop a solr instance. */ + public static final String ERRORS_failed_to_stop_solr_instance = "{errors.failed_to_stop_solr_instance}"; + + /** The key of the message: Failed to reload a solr instance. */ + public static final String ERRORS_failed_to_reload_solr_instance = "{errors.failed_to_reload_solr_instance}"; + + /** The key of the message: Failed to update a crawling schedule. */ + public static final String ERRORS_failed_to_update_crawler_schedule = "{errors.failed_to_update_crawler_schedule}"; + + /** The key of the message: Failed to create a crawling config. */ + public static final String ERRORS_failed_to_create_crawling_config_at_wizard = "{errors.failed_to_create_crawling_config_at_wizard}"; + + /** The key of the message: This feature is disabled. */ + public static final String ERRORS_design_editor_disabled = "{errors.design_editor_disabled}"; + + /** The key of the message: Could not create a search log csv file. */ + public static final String ERRORS_could_not_create_search_log_csv = "{errors.could_not_create_search_log_csv}"; + + /** The key of the message: Not Found: {0} */ + public static final String ERRORS_not_found_on_file_system = "{errors.not_found_on_file_system}"; + + /** The key of the message: Could not open {0}.
    Please check if the file is associated with an application. */ + public static final String ERRORS_could_not_open_on_system = "{errors.could_not_open_on_system}"; + + /** The key of the message: The limit of a search time was exceeded. The partial result was displayed. */ + public static final String ERRORS_process_time_is_exceeded = "{errors.process_time_is_exceeded}"; + + /** The key of the message: No more results could be displayed. */ + public static final String ERRORS_result_size_exceeded = "{errors.result_size_exceeded}"; + + /** The key of the message: {0} file does not exist. */ + public static final String ERRORS_target_file_does_not_exist = "{errors.target_file_does_not_exist}"; + + /** The key of the message: Failed to download {0} file. */ + public static final String ERRORS_failed_to_download_file = "{errors.failed_to_download_file}"; + + /** The key of the message: Failed to delete {0} file. */ + public static final String ERRORS_failed_to_delete_file = "{errors.failed_to_delete_file}"; + + /** The key of the message: Failed to redirect {0}. */ + public static final String ERRORS_failed_to_redirect = "{errors.failed_to_redirect}"; + + /** The key of the message: {0} is not supported as encoding. */ + public static final String ERRORS_unsupported_encoding = "{errors.unsupported_encoding}"; + + /** The key of the message: Not found Doc ID:{0} */ + public static final String ERRORS_docid_not_found = "{errors.docid_not_found}"; + + /** The key of the message: Not found URL of Doc ID:{0} */ + public static final String ERRORS_document_not_found = "{errors.document_not_found}"; + + /** The key of the message: Could not load from this server: {0} */ + public static final String ERRORS_not_load_from_server = "{errors.not_load_from_server}"; + + /** The key of the message: Failed to start job {0}. */ + public static final String ERRORS_failed_to_start_job = "{errors.failed_to_start_job}"; + + /** The key of the message: Failed to stop job {0}. */ + public static final String ERRORS_failed_to_stop_job = "{errors.failed_to_stop_job}"; + + /** The key of the message: Expired dictionary information. Please reload it. */ + public static final String ERRORS_expired_dict_id = "{errors.expired_dict_id}"; + + /** The key of the message: Failed to create a cache reponse for ID:{0}. */ + public static final String ERRORS_failed_to_create_cache = "{errors.failed_to_create_cache}"; + + /** The key of the message: Synonym file is not found */ + public static final String ERRORS_synonym_file_is_not_found = "{errors.synonym_file_is_not_found}"; + + /** The key of the message: Failed to download the Synonym file. */ + public static final String ERRORS_failed_to_download_synonym_file = "{errors.failed_to_download_synonym_file}"; + + /** The key of the message: Failed to upload the Synonym file. */ + public static final String ERRORS_failed_to_upload_synonym_file = "{errors.failed_to_upload_synonym_file}"; + + /** The key of the message: Synonym file is not found */ + public static final String ERRORS_userdict_file_is_not_found = "{errors.userdict_file_is_not_found}"; + + /** The key of the message: Failed to download the UserDict file. */ + public static final String ERRORS_failed_to_download_userdict_file = "{errors.failed_to_download_userdict_file}"; + + /** The key of the message: Failed to upload the UserDict file. */ + public static final String ERRORS_failed_to_upload_userdict_file = "{errors.failed_to_upload_userdict_file}"; + + /** The key of the message: Password is required. */ + public static final String ERRORS_blank_password = "{errors.blank_password}"; + + /** The key of the message: Confirm Password does not match. */ + public static final String ERRORS_invalid_confirm_password = "{errors.invalid_confirm_password}"; + + /** The key of the message: Invalid password. */ + public static final String ERRORS_password_does_not_exist_in_session = "{errors.password_does_not_exist_in_session}"; + + /** The key of the message: The given query is invalid. */ + public static final String ERRORS_invalid_query_unknown = "{errors.invalid_query_unknown}"; + + /** The key of the message: An invalid quote character is used. */ + public static final String ERRORS_invalid_query_quoted = "{errors.invalid_query_quoted}"; + + /** The key of the message: An invalid curly bracket character is used. */ + public static final String ERRORS_invalid_query_curly_bracket = "{errors.invalid_query_curly_bracket}"; + + /** The key of the message: An invalid square bracket character is used. */ + public static final String ERRORS_invalid_query_square_bracket = "{errors.invalid_query_square_bracket}"; + + /** The key of the message: An invalid parenthesis character is used. */ + public static final String ERRORS_invalid_query_parenthesis = "{errors.invalid_query_parenthesis}"; + + /** The key of the message: An invalid range is used. The example of the range format is "field:[20020101 TO 20030101]". */ + public static final String ERRORS_invalid_query_num_range = "{errors.invalid_query_num_range}"; + + /** The key of the message: An invalid range is used. The example of the range format is "field:'{'Aida TO Carmen'}'". */ + public static final String ERRORS_invalid_query_str_range = "{errors.invalid_query_str_range}"; + + /** The key of the message: Updated parameters. */ + public static final String SUCCESS_update_crawler_params = "{success.update_crawler_params}"; + + /** The key of the message: Updated parameters. */ + public static final String SUCCESS_update_web_crawler_params = "{success.update_web_crawler_params}"; + + /** The key of the message: Updated parameters. */ + public static final String SUCCESS_update_solr_params = "{success.update_solr_params}"; + + /** The key of the message: Started a process to commit index. */ + public static final String SUCCESS_commit_solr_index = "{success.commit_solr_index}"; + + /** The key of the message: Started a process to optimize index. */ + public static final String SUCCESS_optimize_solr_index = "{success.optimize_solr_index}"; + + /** The key of the message: Started a process to optimize index. */ + public static final String SUCCESS_delete_solr_index = "{success.delete_solr_index}"; + + /** The key of the message: Started to restore data from the uploaded file. */ + public static final String SUCCESS_importing_data = "{success.importing_data}"; + + /** The key of the message: Deleted session data. */ + public static final String SUCCESS_crawling_session_delete_all = "{success.crawling_session_delete_all}"; + + /** The key of the message: Started a crawl process. */ + public static final String SUCCESS_start_crawl_process = "{success.start_crawl_process}"; + + /** The key of the message: Stopping a crawl process. */ + public static final String SUCCESS_stopping_crawl_process = "{success.stopping_crawl_process}"; + + /** The key of the message: Uploaded {0}. */ + public static final String SUCCESS_upload_design_file = "{success.upload_design_file}"; + + /** The key of the message: Updated {0}. */ + public static final String SUCCESS_update_design_jsp_file = "{success.update_design_jsp_file}"; + + /** The key of the message: Starting a solr instance. */ + public static final String SUCCESS_starting_solr_instance = "{success.starting_solr_instance}"; + + /** The key of the message: Stopping a solr instance. */ + public static final String SUCCESS_stopping_solr_instance = "{success.stopping_solr_instance}"; + + /** The key of the message: Reloading a solr instance. */ + public static final String SUCCESS_reloading_solr_instance = "{success.reloading_solr_instance}"; + + /** The key of the message: Updated a crawling schedule. */ + public static final String SUCCESS_update_crawler_schedule = "{success.update_crawler_schedule}"; + + /** The key of the message: Created a crawling config ({0}). */ + public static final String SUCCESS_create_crawling_config_at_wizard = "{success.create_crawling_config_at_wizard}"; + + /** The key of the message: Deleted search logs. */ + public static final String SUCCESS_search_log_delete_all = "{success.search_log_delete_all}"; + + /** The key of the message: Deleted failure urls. */ + public static final String SUCCESS_failure_url_delete_all = "{success.failure_url_delete_all}"; + + /** The key of the message: Deleted {0} file. */ + public static final String SUCCESS_delete_file = "{success.delete_file}"; + + /** The key of the message: Deleted user information. */ + public static final String SUCCESS_user_info_delete_all = "{success.user_info_delete_all}"; + + /** The key of the message: Deleted popular urls */ + public static final String SUCCESS_favorite_log_delete_all = "{success.favorite_log_delete_all}"; + + /** The key of the message: Started job {0}. */ + public static final String SUCCESS_job_started = "{success.job_started}"; + + /** The key of the message: Stopped job {0}. */ + public static final String SUCCESS_job_stopped = "{success.job_stopped}"; + + /** The key of the message: Deleted job logs. */ + public static final String SUCCESS_joblog_delete_all = "{success.joblog_delete_all}"; + + /** The key of the message: Uploaded Synonym file. */ + public static final String SUCCESS_upload_synonym_file = "{success.upload_synonym_file}"; + + /** The key of the message: Uploaded UserDict file. */ + public static final String SUCCESS_upload_userdict_file = "{success.upload_userdict_file}"; + + /** The key of the message: Uploaded Additional Word file. */ + public static final String SUCCESS_upload_suggest_elevate_word = "{success.upload_suggest_elevate_word}"; + + /** The key of the message: Uploaded Bad Word file. */ + public static final String SUCCESS_upload_suggest_bad_word = "{success.upload_suggest_bad_word}"; + + /** The key of the message: Label */ + public static final String LABEL_facet_label_title = "{label.facet_label_title}"; + + /** The key of the message: Term */ + public static final String LABEL_facet_lastModified_title = "{label.facet_lastModified_title}"; + + /** The key of the message: Past 24 Hours */ + public static final String LABEL_facet_lastModified_1day = "{label.facet_lastModified_1day}"; + + /** The key of the message: Past Week */ + public static final String LABEL_facet_lastModified_1week = "{label.facet_lastModified_1week}"; + + /** The key of the message: Past Month */ + public static final String LABEL_facet_lastModified_1month = "{label.facet_lastModified_1month}"; + + /** The key of the message: Past Year */ + public static final String LABEL_facet_lastModified_1year = "{label.facet_lastModified_1year}"; + + /** The key of the message: Size */ + public static final String LABEL_facet_contentLength_title = "{label.facet_contentLength_title}"; + + /** The key of the message:   - 10kb */ + public static final String LABEL_facet_contentLength_10k = "{label.facet_contentLength_10k}"; + + /** The key of the message: 10kb - 100kb */ + public static final String LABEL_facet_contentLength_10kto100k = "{label.facet_contentLength_10kto100k}"; + + /** The key of the message: 100kb - 500kb */ + public static final String LABEL_facet_contentLength_100kto500k = "{label.facet_contentLength_100kto500k}"; + + /** The key of the message: 500kb - 1mb */ + public static final String LABEL_facet_contentLength_500kto1m = "{label.facet_contentLength_500kto1m}"; + + /** The key of the message: 1mb -   */ + public static final String LABEL_facet_contentLength_1m = "{label.facet_contentLength_1m}"; + + /** The key of the message: File Type */ + public static final String LABEL_facet_filetype_title = "{label.facet_filetype_title}"; + + /** The key of the message: HTML */ + public static final String LABEL_facet_filetype_html = "{label.facet_filetype_html}"; + + /** The key of the message: Word */ + public static final String LABEL_facet_filetype_word = "{label.facet_filetype_word}"; + + /** The key of the message: Excel */ + public static final String LABEL_facet_filetype_excel = "{label.facet_filetype_excel}"; + + /** The key of the message: PowerPoint */ + public static final String LABEL_facet_filetype_powerpoint = "{label.facet_filetype_powerpoint}"; + + /** The key of the message: PDF */ + public static final String LABEL_facet_filetype_pdf = "{label.facet_filetype_pdf}"; + + /** The key of the message: PDF */ + public static final String LABEL_facet_filetype_others = "{label.facet_filetype_others}"; + + /** The key of the message: Reset */ + public static final String LABEL_facet_label_reset = "{label.facet_label_reset}"; + + /** The key of the message: Invalid mode(expected value is {0}, but it's {1}). */ + public static final String ERRORS_crud_invalid_mode = "{errors.crud_invalid_mode}"; + + /** The key of the message: Failed to create a new data. */ + public static final String ERRORS_crud_failed_to_create_crud_table = "{errors.crud_failed_to_create_crud_table}"; + + /** The key of the message: Failed to update the data. */ + public static final String ERRORS_crud_failed_to_update_crud_table = "{errors.crud_failed_to_update_crud_table}"; + + /** The key of the message: Failed to delete the data. */ + public static final String ERRORS_crud_failed_to_delete_crud_table = "{errors.crud_failed_to_delete_crud_table}"; + + /** The key of the message: Could not find the data({0}). */ + public static final String ERRORS_crud_could_not_find_crud_table = "{errors.crud_could_not_find_crud_table}"; + + /** The key of the message: Created data. */ + public static final String SUCCESS_crud_create_crud_table = "{success.crud_create_crud_table}"; + + /** The key of the message: Updated data. */ + public static final String SUCCESS_crud_update_crud_table = "{success.crud_update_crud_table}"; + + /** The key of the message: Deleted data. */ + public static final String SUCCESS_crud_delete_crud_table = "{success.crud_delete_crud_table}"; + + /** + * Add the created action message for the key 'constraints.AssertFalse.message' with parameters. + *
    +     * message: must be false
    +     * comment: ---------------
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsAssertFalseMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_AssertFalse_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.AssertTrue.message' with parameters. + *
    +     * message: must be true
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsAssertTrueMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_AssertTrue_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.DecimalMax.message' with parameters. + *
    +     * message: must be less than ${inclusive == true ? 'or equal to ' : ''}{value}
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param value The parameter value for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsDecimalMaxMessage(String property, String value) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_DecimalMax_MESSAGE, value)); + return this; + } + + /** + * Add the created action message for the key 'constraints.DecimalMin.message' with parameters. + *
    +     * message: must be greater than ${inclusive == true ? 'or equal to ' : ''}{value}
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param value The parameter value for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsDecimalMinMessage(String property, String value) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_DecimalMin_MESSAGE, value)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Digits.message' with parameters. + *
    +     * message: numeric value out of bounds (<{integer} digits>.<{fraction} digits> expected)
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param integer The parameter integer for message. (NotNull) + * @param fraction The parameter fraction for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsDigitsMessage(String property, String integer, String fraction) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Digits_MESSAGE, integer, fraction)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Future.message' with parameters. + *
    +     * message: must be in the future
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsFutureMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Future_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Max.message' with parameters. + *
    +     * message: must be less than or equal to {value}
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param value The parameter value for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsMaxMessage(String property, String value) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Max_MESSAGE, value)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Min.message' with parameters. + *
    +     * message: must be greater than or equal to {value}
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param value The parameter value for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsMinMessage(String property, String value) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Min_MESSAGE, value)); + return this; + } + + /** + * Add the created action message for the key 'constraints.NotNull.message' with parameters. + *
    +     * message: may not be null
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsNotNullMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_NotNull_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Null.message' with parameters. + *
    +     * message: must be null
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsNullMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Null_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Past.message' with parameters. + *
    +     * message: must be in the past
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsPastMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Past_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Pattern.message' with parameters. + *
    +     * message: must match "{regexp}"
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param regexp The parameter regexp for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsPatternMessage(String property, String regexp) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Pattern_MESSAGE, regexp)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Size.message' with parameters. + *
    +     * message: size must be between {min} and {max}
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param min The parameter min for message. (NotNull) + * @param max The parameter max for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsSizeMessage(String property, String min, String max) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Size_MESSAGE, min, max)); + return this; + } + + /** + * Add the created action message for the key 'constraints.CreditCardNumber.message' with parameters. + *
    +     * message: invalid credit card number
    +     * comment: -------------------
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsCreditCardNumberMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_CreditCardNumber_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.EAN.message' with parameters. + *
    +     * message: invalid {type} barcode
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param type The parameter type for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsEanMessage(String property, String type) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_EAN_MESSAGE, type)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Email.message' with parameters. + *
    +     * message: not a well-formed email address
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsEmailMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Email_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Length.message' with parameters. + *
    +     * message: length must be between {min} and {max}
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param min The parameter min for message. (NotNull) + * @param max The parameter max for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsLengthMessage(String property, String min, String max) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Length_MESSAGE, min, max)); + return this; + } + + /** + * Add the created action message for the key 'constraints.LuhnCheck.message' with parameters. + *
    +     * message: The check digit for ${value} is invalid, Luhn Modulo 10 checksum failed
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param value The parameter value for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsLuhnCheckMessage(String property, String value) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_LuhnCheck_MESSAGE, value)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Mod10Check.message' with parameters. + *
    +     * message: The check digit for ${value} is invalid, Modulo 10 checksum failed
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param value The parameter value for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsMod10CheckMessage(String property, String value) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Mod10Check_MESSAGE, value)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Mod11Check.message' with parameters. + *
    +     * message: The check digit for ${value} is invalid, Modulo 11 checksum failed
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param value The parameter value for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsMod11CheckMessage(String property, String value) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Mod11Check_MESSAGE, value)); + return this; + } + + /** + * Add the created action message for the key 'constraints.ModCheck.message' with parameters. + *
    +     * message: The check digit for ${value} is invalid, ${modType} checksum failed
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param value The parameter value for message. (NotNull) + * @param modType The parameter modType for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsModCheckMessage(String property, String value, String modType) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_ModCheck_MESSAGE, value, modType)); + return this; + } + + /** + * Add the created action message for the key 'constraints.NotBlank.message' with parameters. + *
    +     * message: may not be empty
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsNotBlankMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_NotBlank_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.NotEmpty.message' with parameters. + *
    +     * message: may not be empty
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsNotEmptyMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_NotEmpty_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.ParametersScriptAssert.message' with parameters. + *
    +     * message: script expression "{script}" didn't evaluate to true
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param script The parameter script for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsParametersScriptAssertMessage(String property, String script) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_ParametersScriptAssert_MESSAGE, script)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Range.message' with parameters. + *
    +     * message: must be between {min} and {max}
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param min The parameter min for message. (NotNull) + * @param max The parameter max for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsRangeMessage(String property, String min, String max) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Range_MESSAGE, min, max)); + return this; + } + + /** + * Add the created action message for the key 'constraints.SafeHtml.message' with parameters. + *
    +     * message: may have unsafe html content
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsSafeHtmlMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_SafeHtml_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.ScriptAssert.message' with parameters. + *
    +     * message: script expression "{script}" didn't evaluate to true
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param script The parameter script for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsScriptAssertMessage(String property, String script) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_ScriptAssert_MESSAGE, script)); + return this; + } + + /** + * Add the created action message for the key 'constraints.URL.message' with parameters. + *
    +     * message: must be a valid URL
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsUrlMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_URL_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'constraints.Required.message' with parameters. + *
    +     * message: is required
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addConstraintsRequiredMessage(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(CONSTRAINTS_Required_MESSAGE)); + return this; + } + + /** + * Add the created action message for the key 'errors.login.failure' with parameters. + *
    +     * message: could not login
    +     * comment: - - - - - - - - - -/
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsLoginFailure(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_LOGIN_FAILURE)); + return this; + } + + /** + * Add the created action message for the key 'errors.app.illegal.transition' with parameters. + *
    +     * message: retry because of illegal transition
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsAppIllegalTransition(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_APP_ILLEGAL_TRANSITION)); + return this; + } + + /** + * Add the created action message for the key 'errors.app.db.already.deleted' with parameters. + *
    +     * message: others might be updated, so retry
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsAppDbAlreadyDeleted(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_APP_DB_ALREADY_DELETED)); + return this; + } + + /** + * Add the created action message for the key 'errors.app.db.already.updated' with parameters. + *
    +     * message: others might be updated, so retry
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsAppDbAlreadyUpdated(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_APP_DB_ALREADY_UPDATED)); + return this; + } + + /** + * Add the created action message for the key 'errors.app.db.already.exists' with parameters. + *
    +     * message: already existing data, so retry
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsAppDbAlreadyExists(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_APP_DB_ALREADY_EXISTS)); + return this; + } + + /** + * Add the created action message for the key 'errors.front_header' with parameters. + *
    +     * message: 
    + *
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFrontHeader(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_front_header)); + return this; + } + + /** + * Add the created action message for the key 'errors.front_footer' with parameters. + *
    +     * message: 
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFrontFooter(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_front_footer)); + return this; + } + + /** + * Add the created action message for the key 'errors.front_prefix' with parameters. + *
    +     * message: 
    + *
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFrontPrefix(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_front_prefix)); + return this; + } + + /** + * Add the created action message for the key 'errors.front_suffix' with parameters. + *
    +     * message: 
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFrontSuffix(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_front_suffix)); + return this; + } + + /** + * Add the created action message for the key 'errors.header' with parameters. + *
    +     * message: 
    + *
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsHeader(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_HEADER)); + return this; + } + + /** + * Add the created action message for the key 'errors.footer' with parameters. + *
    +     * message: 
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFooter(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_FOOTER)); + return this; + } + + /** + * Add the created action message for the key 'errors.prefix' with parameters. + *
    +     * message: 

    + *

    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsPrefix(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_PREFIX)); + return this; + } + + /** + * Add the created action message for the key 'errors.suffix' with parameters. + *
    +     * message: 

    + *
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsSuffix(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_SUFFIX)); + return this; + } + + /** + * Add the created action message for the key 'errors.invalid' with parameters. + *
    +     * message: {0} is invalid.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsInvalid(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_INVALID, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.maxlength' with parameters. + *
    +     * message: {0} can not be greater than {1} characters.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @param arg1 The parameter arg1 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsMaxlength(String property, String arg0, String arg1) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_MAXLENGTH, arg0, arg1)); + return this; + } + + /** + * Add the created action message for the key 'errors.minlength' with parameters. + *
    +     * message: {0} can not be less than {1} characters.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @param arg1 The parameter arg1 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsMinlength(String property, String arg0, String arg1) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_MINLENGTH, arg0, arg1)); + return this; + } + + /** + * Add the created action message for the key 'errors.maxbytelength' with parameters. + *
    +     * message: {0} can not be greater than {1} bytes.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @param arg1 The parameter arg1 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsMaxbytelength(String property, String arg0, String arg1) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_MAXBYTELENGTH, arg0, arg1)); + return this; + } + + /** + * Add the created action message for the key 'errors.minbytelength' with parameters. + *
    +     * message: {0} can not be less than {1} bytes.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @param arg1 The parameter arg1 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsMinbytelength(String property, String arg0, String arg1) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_MINBYTELENGTH, arg0, arg1)); + return this; + } + + /** + * Add the created action message for the key 'errors.range' with parameters. + *
    +     * message: {0} is not in the range {1} through {2}.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @param arg1 The parameter arg1 for message. (NotNull) + * @param arg2 The parameter arg2 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsRange(String property, String arg0, String arg1, String arg2) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_RANGE, arg0, arg1, arg2)); + return this; + } + + /** + * Add the created action message for the key 'errors.required' with parameters. + *
    +     * message: {0} is required.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsRequired(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_REQUIRED, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.byte' with parameters. + *
    +     * message: {0} must be an byte.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsByte(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_BYTE, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.date' with parameters. + *
    +     * message: {0} is not a date.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsDate(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_DATE, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.double' with parameters. + *
    +     * message: {0} must be an double.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsDouble(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_DOUBLE, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.float' with parameters. + *
    +     * message: {0} must be an float.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFloat(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_FLOAT, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.integer' with parameters. + *
    +     * message: {0} must be an integer.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsInteger(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_INTEGER, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.long' with parameters. + *
    +     * message: {0} must be an long.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsLong(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_LONG, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.short' with parameters. + *
    +     * message: {0} must be an short.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsShort(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_SHORT, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.creditcard' with parameters. + *
    +     * message: {0} is not a valid credit card number.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsCreditcard(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_CREDITCARD, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.email' with parameters. + *
    +     * message: {0} is an invalid e-mail address.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsEmail(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_EMAIL, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.url' with parameters. + *
    +     * message: {0} is an invalid url (web address).
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsUrl(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_URL, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.cronexpression' with parameters. + *
    +     * message: {0} is a invalid format.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsCronexpression(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_CRONEXPRESSION, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.uritype' with parameters. + *
    +     * message: {0} is a invalid uri.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsUritype(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_URITYPE, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.alphaDigitOnly' with parameters. + *
    +     * message: {0} must be alphabet or digit only.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsAlphaDigitOnly(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_ALPHA_DIGIT_ONLY, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.alphaDigitSpaceOnly' with parameters. + *
    +     * message: {0} must be alphabet, digit, or space only.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsAlphaDigitSpaceOnly(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_ALPHA_DIGIT_SPACE_ONLY, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.token' with parameters. + *
    +     * message: Invalid request.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsToken(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_TOKEN)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_update_crawler_params' with parameters. + *
    +     * message: Failed to update parameters. Please contact to a site administrator.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToUpdateCrawlerParams(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_update_crawler_params)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_update_web_crawler_params' with parameters. + *
    +     * message: Failed to update parameters. Please contact to a site administrator.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToUpdateWebCrawlerParams(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_update_web_crawler_params)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_update_solr_params' with parameters. + *
    +     * message: Failed to update parameters. Please contact to a site administrator.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToUpdateSolrParams(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_update_solr_params)); + return this; + } + + /** + * Add the created action message for the key 'error.login_error' with parameters. + *
    +     * message: Username or Password is not correct.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorLoginError(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERROR_login_error)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_commit_solr_index' with parameters. + *
    +     * message: Failed to commit index.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToCommitSolrIndex(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_commit_solr_index)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_optimize_solr_index' with parameters. + *
    +     * message: Failed to optimize index.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToOptimizeSolrIndex(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_optimize_solr_index)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_delete_solr_index' with parameters. + *
    +     * message: Failed to delete index.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToDeleteSolrIndex(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_delete_solr_index)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_start_solr_process_because_of_running' with parameters. + *
    +     * message: Failed to start a process because of running solr process.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToStartSolrProcessBecauseOfRunning(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_start_solr_process_because_of_running)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_import_data' with parameters. + *
    +     * message: Failed to restore data.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToImportData(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_import_data)); + return this; + } + + /** + * Add the created action message for the key 'errors.unknown_import_file' with parameters. + *
    +     * message: Unknown file type.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsUnknownImportFile(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_unknown_import_file)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_export_data' with parameters. + *
    +     * message: Failed to backup data.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToExportData(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_export_data)); + return this; + } + + /** + * Add the created action message for the key 'errors.could_not_find_log_file' with parameters. + *
    +     * message: Could not find {0}.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsCouldNotFindLogFile(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_could_not_find_log_file, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.no_running_crawl_process' with parameters. + *
    +     * message: No running crawl process.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsNoRunningCrawlProcess(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_no_running_crawl_process)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_start_crawl_process' with parameters. + *
    +     * message: Failed to start a crawl process.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToStartCrawlProcess(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_start_crawl_process)); + return this; + } + + /** + * Add the created action message for the key 'errors.invalid_design_jsp_file_name' with parameters. + *
    +     * message: Invalid JSP file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsInvalidDesignJspFileName(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_invalid_design_jsp_file_name)); + return this; + } + + /** + * Add the created action message for the key 'errors.design_jsp_file_does_not_exist' with parameters. + *
    +     * message: JSP file does not exist.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsDesignJspFileDoesNotExist(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_design_jsp_file_does_not_exist)); + return this; + } + + /** + * Add the created action message for the key 'errors.design_file_name_is_not_found' with parameters. + *
    +     * message: The file name is not specified.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsDesignFileNameIsNotFound(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_design_file_name_is_not_found)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_write_design_image_file' with parameters. + *
    +     * message: Failed to upload an image file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToWriteDesignImageFile(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_write_design_image_file)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_update_jsp_file' with parameters. + *
    +     * message: Failed to update a jsp file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToUpdateJspFile(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_update_jsp_file)); + return this; + } + + /** + * Add the created action message for the key 'errors.design_file_name_is_invalid' with parameters. + *
    +     * message: The file name is invalid.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsDesignFileNameIsInvalid(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_design_file_name_is_invalid)); + return this; + } + + /** + * Add the created action message for the key 'errors.design_file_is_unsupported_type' with parameters. + *
    +     * message: The kind of file is unsupported.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsDesignFileIsUnsupportedType(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_design_file_is_unsupported_type)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_start_solr_instance' with parameters. + *
    +     * message: Failed to start a solr instance.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToStartSolrInstance(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_start_solr_instance)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_stop_solr_instance' with parameters. + *
    +     * message: Failed to stop a solr instance.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToStopSolrInstance(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_stop_solr_instance)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_reload_solr_instance' with parameters. + *
    +     * message: Failed to reload a solr instance.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToReloadSolrInstance(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_reload_solr_instance)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_update_crawler_schedule' with parameters. + *
    +     * message: Failed to update a crawling schedule.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToUpdateCrawlerSchedule(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_update_crawler_schedule)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_create_crawling_config_at_wizard' with parameters. + *
    +     * message: Failed to create a crawling config.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToCreateCrawlingConfigAtWizard(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_create_crawling_config_at_wizard)); + return this; + } + + /** + * Add the created action message for the key 'errors.design_editor_disabled' with parameters. + *
    +     * message: This feature is disabled.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsDesignEditorDisabled(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_design_editor_disabled)); + return this; + } + + /** + * Add the created action message for the key 'errors.could_not_create_search_log_csv' with parameters. + *
    +     * message: Could not create a search log csv file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsCouldNotCreateSearchLogCsv(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_could_not_create_search_log_csv)); + return this; + } + + /** + * Add the created action message for the key 'errors.not_found_on_file_system' with parameters. + *
    +     * message: Not Found: {0}
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsNotFoundOnFileSystem(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_not_found_on_file_system, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.could_not_open_on_system' with parameters. + *
    +     * message: Could not open {0}. 
    Please check if the file is associated with an application. + *
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsCouldNotOpenOnSystem(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_could_not_open_on_system, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.process_time_is_exceeded' with parameters. + *
    +     * message: The limit of a search time was exceeded. The partial result was displayed.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsProcessTimeIsExceeded(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_process_time_is_exceeded)); + return this; + } + + /** + * Add the created action message for the key 'errors.result_size_exceeded' with parameters. + *
    +     * message: No more results could be displayed.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsResultSizeExceeded(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_result_size_exceeded)); + return this; + } + + /** + * Add the created action message for the key 'errors.target_file_does_not_exist' with parameters. + *
    +     * message: {0} file does not exist.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsTargetFileDoesNotExist(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_target_file_does_not_exist, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_download_file' with parameters. + *
    +     * message: Failed to download {0} file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToDownloadFile(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_download_file, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_delete_file' with parameters. + *
    +     * message: Failed to delete {0} file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToDeleteFile(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_delete_file, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_redirect' with parameters. + *
    +     * message: Failed to redirect {0}.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToRedirect(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_redirect, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.unsupported_encoding' with parameters. + *
    +     * message: {0} is not supported as encoding.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsUnsupportedEncoding(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_unsupported_encoding, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.docid_not_found' with parameters. + *
    +     * message: Not found Doc ID:{0}
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsDocidNotFound(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_docid_not_found, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.document_not_found' with parameters. + *
    +     * message: Not found URL of Doc ID:{0}
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsDocumentNotFound(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_document_not_found, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.not_load_from_server' with parameters. + *
    +     * message: Could not load from this server: {0}
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsNotLoadFromServer(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_not_load_from_server, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_start_job' with parameters. + *
    +     * message: Failed to start job {0}.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToStartJob(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_start_job, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_stop_job' with parameters. + *
    +     * message: Failed to stop job {0}.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToStopJob(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_stop_job, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.expired_dict_id' with parameters. + *
    +     * message: Expired dictionary information. Please reload it.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsExpiredDictId(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_expired_dict_id)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_create_cache' with parameters. + *
    +     * message: Failed to create a cache reponse for ID:{0}.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToCreateCache(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_create_cache, arg0)); + return this; + } + + /** + * Add the created action message for the key 'errors.synonym_file_is_not_found' with parameters. + *
    +     * message: Synonym file is not found
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsSynonymFileIsNotFound(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_synonym_file_is_not_found)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_download_synonym_file' with parameters. + *
    +     * message: Failed to download the Synonym file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToDownloadSynonymFile(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_download_synonym_file)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_upload_synonym_file' with parameters. + *
    +     * message: Failed to upload the Synonym file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToUploadSynonymFile(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_upload_synonym_file)); + return this; + } + + /** + * Add the created action message for the key 'errors.userdict_file_is_not_found' with parameters. + *
    +     * message: Synonym file is not found
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsUserdictFileIsNotFound(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_userdict_file_is_not_found)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_download_userdict_file' with parameters. + *
    +     * message: Failed to download the UserDict file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToDownloadUserdictFile(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_download_userdict_file)); + return this; + } + + /** + * Add the created action message for the key 'errors.failed_to_upload_userdict_file' with parameters. + *
    +     * message: Failed to upload the UserDict file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsFailedToUploadUserdictFile(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_failed_to_upload_userdict_file)); + return this; + } + + /** + * Add the created action message for the key 'errors.blank_password' with parameters. + *
    +     * message: Password is required.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsBlankPassword(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_blank_password)); + return this; + } + + /** + * Add the created action message for the key 'errors.invalid_confirm_password' with parameters. + *
    +     * message: Confirm Password does not match.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsInvalidConfirmPassword(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_invalid_confirm_password)); + return this; + } + + /** + * Add the created action message for the key 'errors.password_does_not_exist_in_session' with parameters. + *
    +     * message: Invalid password.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsPasswordDoesNotExistInSession(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_password_does_not_exist_in_session)); + return this; + } + + /** + * Add the created action message for the key 'errors.invalid_query_unknown' with parameters. + *
    +     * message: The given query is invalid.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsInvalidQueryUnknown(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_invalid_query_unknown)); + return this; + } + + /** + * Add the created action message for the key 'errors.invalid_query_quoted' with parameters. + *
    +     * message: An invalid quote character is used.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsInvalidQueryQuoted(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_invalid_query_quoted)); + return this; + } + + /** + * Add the created action message for the key 'errors.invalid_query_curly_bracket' with parameters. + *
    +     * message: An invalid curly bracket character is used.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsInvalidQueryCurlyBracket(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_invalid_query_curly_bracket)); + return this; + } + + /** + * Add the created action message for the key 'errors.invalid_query_square_bracket' with parameters. + *
    +     * message: An invalid square bracket character is used.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsInvalidQuerySquareBracket(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_invalid_query_square_bracket)); + return this; + } + + /** + * Add the created action message for the key 'errors.invalid_query_parenthesis' with parameters. + *
    +     * message: An invalid parenthesis character is used.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsInvalidQueryParenthesis(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_invalid_query_parenthesis)); + return this; + } + + /** + * Add the created action message for the key 'errors.invalid_query_num_range' with parameters. + *
    +     * message: An invalid range is used. The example of the range format is "field:[20020101 TO 20030101]".
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsInvalidQueryNumRange(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_invalid_query_num_range)); + return this; + } + + /** + * Add the created action message for the key 'errors.invalid_query_str_range' with parameters. + *
    +     * message: An invalid range is used. The example of the range format is "field:'{'Aida TO Carmen'}'".
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsInvalidQueryStrRange(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_invalid_query_str_range)); + return this; + } + + /** + * Add the created action message for the key 'success.update_crawler_params' with parameters. + *
    +     * message: Updated parameters.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessUpdateCrawlerParams(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_update_crawler_params)); + return this; + } + + /** + * Add the created action message for the key 'success.update_web_crawler_params' with parameters. + *
    +     * message: Updated parameters.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessUpdateWebCrawlerParams(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_update_web_crawler_params)); + return this; + } + + /** + * Add the created action message for the key 'success.update_solr_params' with parameters. + *
    +     * message: Updated parameters.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessUpdateSolrParams(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_update_solr_params)); + return this; + } + + /** + * Add the created action message for the key 'success.commit_solr_index' with parameters. + *
    +     * message: Started a process to commit index.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessCommitSolrIndex(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_commit_solr_index)); + return this; + } + + /** + * Add the created action message for the key 'success.optimize_solr_index' with parameters. + *
    +     * message: Started a process to optimize index.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessOptimizeSolrIndex(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_optimize_solr_index)); + return this; + } + + /** + * Add the created action message for the key 'success.delete_solr_index' with parameters. + *
    +     * message: Started a process to optimize index.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessDeleteSolrIndex(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_delete_solr_index)); + return this; + } + + /** + * Add the created action message for the key 'success.importing_data' with parameters. + *
    +     * message: Started to restore data from the uploaded file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessImportingData(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_importing_data)); + return this; + } + + /** + * Add the created action message for the key 'success.crawling_session_delete_all' with parameters. + *
    +     * message: Deleted session data.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessCrawlingSessionDeleteAll(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_crawling_session_delete_all)); + return this; + } + + /** + * Add the created action message for the key 'success.start_crawl_process' with parameters. + *
    +     * message: Started a crawl process.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessStartCrawlProcess(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_start_crawl_process)); + return this; + } + + /** + * Add the created action message for the key 'success.stopping_crawl_process' with parameters. + *
    +     * message: Stopping a crawl process.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessStoppingCrawlProcess(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_stopping_crawl_process)); + return this; + } + + /** + * Add the created action message for the key 'success.upload_design_file' with parameters. + *
    +     * message: Uploaded {0}.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessUploadDesignFile(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_upload_design_file, arg0)); + return this; + } + + /** + * Add the created action message for the key 'success.update_design_jsp_file' with parameters. + *
    +     * message: Updated {0}.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessUpdateDesignJspFile(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_update_design_jsp_file, arg0)); + return this; + } + + /** + * Add the created action message for the key 'success.starting_solr_instance' with parameters. + *
    +     * message: Starting a solr instance.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessStartingSolrInstance(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_starting_solr_instance)); + return this; + } + + /** + * Add the created action message for the key 'success.stopping_solr_instance' with parameters. + *
    +     * message: Stopping a solr instance.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessStoppingSolrInstance(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_stopping_solr_instance)); + return this; + } + + /** + * Add the created action message for the key 'success.reloading_solr_instance' with parameters. + *
    +     * message: Reloading a solr instance.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessReloadingSolrInstance(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_reloading_solr_instance)); + return this; + } + + /** + * Add the created action message for the key 'success.update_crawler_schedule' with parameters. + *
    +     * message: Updated a crawling schedule.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessUpdateCrawlerSchedule(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_update_crawler_schedule)); + return this; + } + + /** + * Add the created action message for the key 'success.create_crawling_config_at_wizard' with parameters. + *
    +     * message: Created a crawling config ({0}).
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessCreateCrawlingConfigAtWizard(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_create_crawling_config_at_wizard, arg0)); + return this; + } + + /** + * Add the created action message for the key 'success.search_log_delete_all' with parameters. + *
    +     * message: Deleted search logs.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessSearchLogDeleteAll(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_search_log_delete_all)); + return this; + } + + /** + * Add the created action message for the key 'success.failure_url_delete_all' with parameters. + *
    +     * message: Deleted failure urls.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessFailureUrlDeleteAll(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_failure_url_delete_all)); + return this; + } + + /** + * Add the created action message for the key 'success.delete_file' with parameters. + *
    +     * message: Deleted {0} file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessDeleteFile(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_delete_file, arg0)); + return this; + } + + /** + * Add the created action message for the key 'success.user_info_delete_all' with parameters. + *
    +     * message: Deleted user information.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessUserInfoDeleteAll(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_user_info_delete_all)); + return this; + } + + /** + * Add the created action message for the key 'success.favorite_log_delete_all' with parameters. + *
    +     * message: Deleted popular urls
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessFavoriteLogDeleteAll(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_favorite_log_delete_all)); + return this; + } + + /** + * Add the created action message for the key 'success.job_started' with parameters. + *
    +     * message: Started job {0}.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessJobStarted(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_job_started, arg0)); + return this; + } + + /** + * Add the created action message for the key 'success.job_stopped' with parameters. + *
    +     * message: Stopped job {0}.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessJobStopped(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_job_stopped, arg0)); + return this; + } + + /** + * Add the created action message for the key 'success.joblog_delete_all' with parameters. + *
    +     * message: Deleted job logs.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessJoblogDeleteAll(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_joblog_delete_all)); + return this; + } + + /** + * Add the created action message for the key 'success.upload_synonym_file' with parameters. + *
    +     * message: Uploaded Synonym file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessUploadSynonymFile(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_upload_synonym_file)); + return this; + } + + /** + * Add the created action message for the key 'success.upload_userdict_file' with parameters. + *
    +     * message: Uploaded UserDict file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessUploadUserdictFile(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_upload_userdict_file)); + return this; + } + + /** + * Add the created action message for the key 'success.upload_suggest_elevate_word' with parameters. + *
    +     * message: Uploaded Additional Word file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessUploadSuggestElevateWord(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_upload_suggest_elevate_word)); + return this; + } + + /** + * Add the created action message for the key 'success.upload_suggest_bad_word' with parameters. + *
    +     * message: Uploaded Bad Word file.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessUploadSuggestBadWord(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_upload_suggest_bad_word)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_label_title' with parameters. + *
    +     * message: Label
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetLabelTitle(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_label_title)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_lastModified_title' with parameters. + *
    +     * message: Term
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetLastModifiedTitle(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_lastModified_title)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_lastModified_1day' with parameters. + *
    +     * message: Past 24 Hours
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetLastModified1day(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_lastModified_1day)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_lastModified_1week' with parameters. + *
    +     * message: Past Week
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetLastModified1week(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_lastModified_1week)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_lastModified_1month' with parameters. + *
    +     * message: Past Month
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetLastModified1month(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_lastModified_1month)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_lastModified_1year' with parameters. + *
    +     * message: Past Year
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetLastModified1year(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_lastModified_1year)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_contentLength_title' with parameters. + *
    +     * message: Size
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetContentLengthTitle(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_contentLength_title)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_contentLength_10k' with parameters. + *
    +     * message:   - 10kb
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetContentLength10k(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_contentLength_10k)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_contentLength_10kto100k' with parameters. + *
    +     * message: 10kb - 100kb
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetContentLength10kto100k(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_contentLength_10kto100k)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_contentLength_100kto500k' with parameters. + *
    +     * message: 100kb - 500kb
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetContentLength100kto500k(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_contentLength_100kto500k)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_contentLength_500kto1m' with parameters. + *
    +     * message: 500kb - 1mb
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetContentLength500kto1m(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_contentLength_500kto1m)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_contentLength_1m' with parameters. + *
    +     * message: 1mb -  
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetContentLength1m(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_contentLength_1m)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_filetype_title' with parameters. + *
    +     * message: File Type
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetFiletypeTitle(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_filetype_title)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_filetype_html' with parameters. + *
    +     * message: HTML
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetFiletypeHtml(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_filetype_html)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_filetype_word' with parameters. + *
    +     * message: Word
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetFiletypeWord(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_filetype_word)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_filetype_excel' with parameters. + *
    +     * message: Excel
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetFiletypeExcel(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_filetype_excel)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_filetype_powerpoint' with parameters. + *
    +     * message: PowerPoint
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetFiletypePowerpoint(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_filetype_powerpoint)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_filetype_pdf' with parameters. + *
    +     * message: PDF
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetFiletypePdf(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_filetype_pdf)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_filetype_others' with parameters. + *
    +     * message: PDF
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetFiletypeOthers(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_filetype_others)); + return this; + } + + /** + * Add the created action message for the key 'label.facet_label_reset' with parameters. + *
    +     * message: Reset
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addLabelFacetLabelReset(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(LABEL_facet_label_reset)); + return this; + } + + /** + * Add the created action message for the key 'errors.crud_invalid_mode' with parameters. + *
    +     * message: Invalid mode(expected value is {0}, but it's {1}).
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @param arg1 The parameter arg1 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsCrudInvalidMode(String property, String arg0, String arg1) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_crud_invalid_mode, arg0, arg1)); + return this; + } + + /** + * Add the created action message for the key 'errors.crud_failed_to_create_crud_table' with parameters. + *
    +     * message: Failed to create a new data.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsCrudFailedToCreateCrudTable(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_crud_failed_to_create_crud_table)); + return this; + } + + /** + * Add the created action message for the key 'errors.crud_failed_to_update_crud_table' with parameters. + *
    +     * message: Failed to update the data.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsCrudFailedToUpdateCrudTable(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_crud_failed_to_update_crud_table)); + return this; + } + + /** + * Add the created action message for the key 'errors.crud_failed_to_delete_crud_table' with parameters. + *
    +     * message: Failed to delete the data.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsCrudFailedToDeleteCrudTable(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_crud_failed_to_delete_crud_table)); + return this; + } + + /** + * Add the created action message for the key 'errors.crud_could_not_find_crud_table' with parameters. + *
    +     * message: Could not find the data({0}).
    +     * 
    + * @param property The property name for the message. (NotNull) + * @param arg0 The parameter arg0 for message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addErrorsCrudCouldNotFindCrudTable(String property, String arg0) { + assertPropertyNotNull(property); + add(property, new ActionMessage(ERRORS_crud_could_not_find_crud_table, arg0)); + return this; + } + + /** + * Add the created action message for the key 'success.crud_create_crud_table' with parameters. + *
    +     * message: Created data.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessCrudCreateCrudTable(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_crud_create_crud_table)); + return this; + } + + /** + * Add the created action message for the key 'success.crud_update_crud_table' with parameters. + *
    +     * message: Updated data.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessCrudUpdateCrudTable(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_crud_update_crud_table)); + return this; + } + + /** + * Add the created action message for the key 'success.crud_delete_crud_table' with parameters. + *
    +     * message: Deleted data.
    +     * 
    + * @param property The property name for the message. (NotNull) + * @return this. (NotNull) + */ + public FessMessages addSuccessCrudDeleteCrudTable(String property) { + assertPropertyNotNull(property); + add(property, new ActionMessage(SUCCESS_crud_delete_crud_table)); + return this; + } +} diff --git a/src/main/java/org/codelibs/fess/lasta/web/action/FessUserBean.java b/src/main/java/org/codelibs/fess/mylasta/action/FessUserBean.java similarity index 69% rename from src/main/java/org/codelibs/fess/lasta/web/action/FessUserBean.java rename to src/main/java/org/codelibs/fess/mylasta/action/FessUserBean.java index fcf64b36b..8d146b839 100644 --- a/src/main/java/org/codelibs/fess/lasta/web/action/FessUserBean.java +++ b/src/main/java/org/codelibs/fess/mylasta/action/FessUserBean.java @@ -1,5 +1,5 @@ /* - * Copyright 2009-2015 the CodeLibs Project and the Others. + * Copyright 2012 the CodeLibs Project and the Others. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,67 +13,47 @@ * either express or implied. See the License for the specific language * governing permissions and limitations under the License. */ -package org.codelibs.fess.lasta.web.action; +package org.codelibs.fess.mylasta.action; -import org.dbflute.saflute.web.action.login.TypicalUserBaseBean; +import org.codelibs.fess.es.exentity.User; +import org.lastaflute.web.login.TypicalUserBean; /** * @author jflute */ -public class FessUserBean extends TypicalUserBaseBean { +public class FessUserBean extends TypicalUserBean { // #change_it also LoginAssist // =================================================================================== // Definition // ========== /** The serial version UID for object serialization. (Default) */ private static final long serialVersionUID = 1L; - - /** The user type for Member, e.g. used by access context. */ - public static final String USER_TYPE = "M"; - - /** The application type for Dockside, e.g. used by access context. */ - public static final String DOMAIN_TYPE = "DCK"; + private User user; // =================================================================================== // Attribute // ========= - protected final Long memberId; - protected final String memberName; // =================================================================================== // Constructor // =========== public FessUserBean() { - memberId = null; - memberName = null; + // TODO needed? + } + + public FessUserBean(final User user) { + this.user = user; } // =================================================================================== // Implementation // ============== @Override - public Long getUserId() { - return memberId; - } - - @Override - public String getUserType() { - return USER_TYPE; - } - - @Override - public String getDomainType() { - return DOMAIN_TYPE; + public String getUserId() { + return user.getName(); } // =================================================================================== // Accessor // ======== - public Long getMemberId() { - return memberId; - } - - public String getMemberName() { - return memberName; - } } diff --git a/src/main/java/org/codelibs/fess/crud/creator/PagerCreator.java b/src/main/java/org/codelibs/fess/mylasta/creator/PagerCreator.java similarity index 77% rename from src/main/java/org/codelibs/fess/crud/creator/PagerCreator.java rename to src/main/java/org/codelibs/fess/mylasta/creator/PagerCreator.java index c4fc5e1d8..ac2d6ddd1 100644 --- a/src/main/java/org/codelibs/fess/crud/creator/PagerCreator.java +++ b/src/main/java/org/codelibs/fess/mylasta/creator/PagerCreator.java @@ -14,13 +14,13 @@ * governing permissions and limitations under the License. */ -package org.codelibs.fess.crud.creator; +package org.codelibs.fess.mylasta.creator; -import org.seasar.framework.container.ComponentCustomizer; -import org.seasar.framework.container.assembler.AutoBindingDefFactory; -import org.seasar.framework.container.creator.ComponentCreatorImpl; -import org.seasar.framework.container.deployer.InstanceDefFactory; -import org.seasar.framework.convention.NamingConvention; +import org.lastaflute.di.core.assembler.AutoBindingDefFactory; +import org.lastaflute.di.core.creator.ComponentCreatorImpl; +import org.lastaflute.di.core.customizer.ComponentCustomizer; +import org.lastaflute.di.core.meta.impl.InstanceDefFactory; +import org.lastaflute.di.naming.NamingConvention; /** * @author shinsuke diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/FessConfig.java b/src/main/java/org/codelibs/fess/mylasta/direction/FessConfig.java new file mode 100644 index 000000000..fe4526280 --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/FessConfig.java @@ -0,0 +1,219 @@ +package org.codelibs.fess.mylasta.direction; + +import org.lastaflute.core.direction.exception.ConfigPropertyNotFoundException; + +/** + * @author FreeGen + */ +public interface FessConfig extends FessEnv { + + /** The key of the configuration. e.g. Fess */ + String DOMAIN_TITLE = "domain.title"; + + /** The key of the configuration. e.g. / */ + String COOKIE_DEFAULT_PATH = "cookie.default.path"; + + /** The key of the configuration. e.g. 31556926 */ + String COOKIE_DEFAULT_EXPIRE = "cookie.default.expire"; + + /** The key of the configuration. e.g. 315360000 */ + String COOKIE_ETERNAL_EXPIRE = "cookie.eternal.expire"; + + /** The key of the configuration. e.g. FES */ + String COOKIE_REMEMBER_ME_HARBOR_KEY = "cookie.remember.me.harbor.key"; + + /** The key of the configuration. e.g. 4 */ + String PAGING_PAGE_SIZE = "paging.page.size"; + + /** The key of the configuration. e.g. 3 */ + String PAGING_PAGE_RANGE_SIZE = "paging.page.range.size"; + + /** The key of the configuration. e.g. true */ + String PAGING_PAGE_RANGE_FILL_LIMIT = "paging.page.range.fill.limit"; + + /** + * Get the value of property as {@link String}. + * @param propertyKey The key of the property. (NotNull) + * @return The value of found property. (NotNull: if not found, exception) + * @throws ConfigPropertyNotFoundException When the property is not found. + */ + String get(String propertyKey); + + /** + * Is the property true? + * @param propertyKey The key of the property which is boolean type. (NotNull) + * @return The determination, true or false. (if not found, exception) + * @throws ConfigPropertyNotFoundException When the property is not found. + */ + boolean is(String propertyKey); + + /** + * Get the value for the key 'domain.title'.
    + * The value is, e.g. Fess
    + * comment: The title of domain the application for logging + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getDomainTitle(); + + /** + * Get the value for the key 'cookie.default.path'.
    + * The value is, e.g. /
    + * comment: The default path of cookie (basically '/' if no context path) + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getCookieDefaultPath(); + + /** + * Get the value for the key 'cookie.default.expire'.
    + * The value is, e.g. 31556926
    + * comment: The default expire of cookie in seconds e.g. 31556926: one year, 86400: one day + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getCookieDefaultExpire(); + + /** + * Get the value for the key 'cookie.default.expire' as {@link Integer}.
    + * The value is, e.g. 31556926
    + * comment: The default expire of cookie in seconds e.g. 31556926: one year, 86400: one day + * @return The value of found property. (NotNull: if not found, exception but basically no way) + * @throws NumberFormatException When the property is not integer. + */ + Integer getCookieDefaultExpireAsInteger(); + + /** + * Get the value for the key 'cookie.eternal.expire'.
    + * The value is, e.g. 315360000
    + * comment: The eternal expire of cookie in seconds e.g. 315360000: ten year, 86400: one day + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getCookieEternalExpire(); + + /** + * Get the value for the key 'cookie.eternal.expire' as {@link Integer}.
    + * The value is, e.g. 315360000
    + * comment: The eternal expire of cookie in seconds e.g. 315360000: ten year, 86400: one day + * @return The value of found property. (NotNull: if not found, exception but basically no way) + * @throws NumberFormatException When the property is not integer. + */ + Integer getCookieEternalExpireAsInteger(); + + /** + * Get the value for the key 'cookie.remember.me.harbor.key'.
    + * The value is, e.g. FES
    + * comment: The cookie key of remember-me for Fess + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getCookieRememberMeHarborKey(); + + /** + * Get the value for the key 'paging.page.size'.
    + * The value is, e.g. 4
    + * comment: The size of one page for paging + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getPagingPageSize(); + + /** + * Get the value for the key 'paging.page.size' as {@link Integer}.
    + * The value is, e.g. 4
    + * comment: The size of one page for paging + * @return The value of found property. (NotNull: if not found, exception but basically no way) + * @throws NumberFormatException When the property is not integer. + */ + Integer getPagingPageSizeAsInteger(); + + /** + * Get the value for the key 'paging.page.range.size'.
    + * The value is, e.g. 3
    + * comment: The size of page range for paging + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getPagingPageRangeSize(); + + /** + * Get the value for the key 'paging.page.range.size' as {@link Integer}.
    + * The value is, e.g. 3
    + * comment: The size of page range for paging + * @return The value of found property. (NotNull: if not found, exception but basically no way) + * @throws NumberFormatException When the property is not integer. + */ + Integer getPagingPageRangeSizeAsInteger(); + + /** + * Get the value for the key 'paging.page.range.fill.limit'.
    + * The value is, e.g. true
    + * comment: The option 'fillLimit' of page range for paging + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getPagingPageRangeFillLimit(); + + /** + * Is the property for the key 'paging.page.range.fill.limit' true?
    + * The value is, e.g. true
    + * comment: The option 'fillLimit' of page range for paging + * @return The determination, true or false. (if not found, exception but basically no way) + */ + boolean isPagingPageRangeFillLimit(); + + /** + * The simple implementation for configuration. + * @author FreeGen + */ + public static class SimpleImpl extends FessEnv.SimpleImpl implements FessConfig { + + /** The serial version UID for object serialization. (Default) */ + private static final long serialVersionUID = 1L; + + public String getDomainTitle() { + return get(FessConfig.DOMAIN_TITLE); + } + + public String getCookieDefaultPath() { + return get(FessConfig.COOKIE_DEFAULT_PATH); + } + + public String getCookieDefaultExpire() { + return get(FessConfig.COOKIE_DEFAULT_EXPIRE); + } + + public Integer getCookieDefaultExpireAsInteger() { + return getAsInteger(FessConfig.COOKIE_DEFAULT_EXPIRE); + } + + public String getCookieEternalExpire() { + return get(FessConfig.COOKIE_ETERNAL_EXPIRE); + } + + public Integer getCookieEternalExpireAsInteger() { + return getAsInteger(FessConfig.COOKIE_ETERNAL_EXPIRE); + } + + public String getCookieRememberMeHarborKey() { + return get(FessConfig.COOKIE_REMEMBER_ME_HARBOR_KEY); + } + + public String getPagingPageSize() { + return get(FessConfig.PAGING_PAGE_SIZE); + } + + public Integer getPagingPageSizeAsInteger() { + return getAsInteger(FessConfig.PAGING_PAGE_SIZE); + } + + public String getPagingPageRangeSize() { + return get(FessConfig.PAGING_PAGE_RANGE_SIZE); + } + + public Integer getPagingPageRangeSizeAsInteger() { + return getAsInteger(FessConfig.PAGING_PAGE_RANGE_SIZE); + } + + public String getPagingPageRangeFillLimit() { + return get(FessConfig.PAGING_PAGE_RANGE_FILL_LIMIT); + } + + public boolean isPagingPageRangeFillLimit() { + return is(FessConfig.PAGING_PAGE_RANGE_FILL_LIMIT); + } + } +} diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/FessEnv.java b/src/main/java/org/codelibs/fess/mylasta/direction/FessEnv.java new file mode 100644 index 000000000..66fe1116c --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/FessEnv.java @@ -0,0 +1,220 @@ +package org.codelibs.fess.mylasta.direction; + +import org.lastaflute.core.direction.ObjectiveConfig; +import org.lastaflute.core.direction.exception.ConfigPropertyNotFoundException; + +/** + * @author FreeGen + */ +public interface FessEnv { + + /** The key of the configuration. e.g. hot */ + String lasta_di_SMART_DEPLOY_MODE = "lasta_di.smart.deploy.mode"; + + /** The key of the configuration. e.g. true */ + String DEVELOPMENT_HERE = "development.here"; + + /** The key of the configuration. e.g. Local Development */ + String ENVIRONMENT_TITLE = "environment.title"; + + /** The key of the configuration. e.g. false */ + String FRAMEWORK_DEBUG = "framework.debug"; + + /** The key of the configuration. e.g. 0 */ + String TIME_ADJUST_TIME_MILLIS = "time.adjust.time.millis"; + + /** The key of the configuration. e.g. true */ + String MAIL_SEND_MOCK = "mail.send.mock"; + + /** The key of the configuration. e.g. localhost:25 */ + String MAIL_SMTP_SERVER_MAIN_HOST_AND_PORT = "mail.smtp.server.main.host.and.port"; + + /** The key of the configuration. e.g. [Test] */ + String MAIL_SUBJECT_TEST_PREFIX = "mail.subject.test.prefix"; + + /** The key of the configuration. e.g. root@localhost */ + String MAIL_RETURN_PATH = "mail.return.path"; + + /** + * Get the value of property as {@link String}. + * @param propertyKey The key of the property. (NotNull) + * @return The value of found property. (NotNull: if not found, exception) + * @throws ConfigPropertyNotFoundException When the property is not found. + */ + String get(String propertyKey); + + /** + * Is the property true? + * @param propertyKey The key of the property which is boolean type. (NotNull) + * @return The determination, true or false. (if not found, exception) + * @throws ConfigPropertyNotFoundException When the property is not found. + */ + boolean is(String propertyKey); + + /** + * Get the value for the key 'lasta_di.smart.deploy.mode'.
    + * The value is, e.g. hot
    + * comment: The mode of Lasta Di's smart-deploy, should be cool in production (e.g. hot, cool, warm) + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getLastaDiSmartDeployMode(); + + /** + * Get the value for the key 'development.here'.
    + * The value is, e.g. true
    + * comment: Is development environment here? (used for various purpose, you should set false if unknown) + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getDevelopmentHere(); + + /** + * Is the property for the key 'development.here' true?
    + * The value is, e.g. true
    + * comment: Is development environment here? (used for various purpose, you should set false if unknown) + * @return The determination, true or false. (if not found, exception but basically no way) + */ + boolean isDevelopmentHere(); + + /** + * Get the value for the key 'environment.title'.
    + * The value is, e.g. Local Development
    + * comment: The title of environment (e.g. local or integartion or production) + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getEnvironmentTitle(); + + /** + * Get the value for the key 'framework.debug'.
    + * The value is, e.g. false
    + * comment: Does it enable the Framework internal debug? (true only when emergency) + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getFrameworkDebug(); + + /** + * Is the property for the key 'framework.debug' true?
    + * The value is, e.g. false
    + * comment: Does it enable the Framework internal debug? (true only when emergency) + * @return The determination, true or false. (if not found, exception but basically no way) + */ + boolean isFrameworkDebug(); + + /** + * Get the value for the key 'time.adjust.time.millis'.
    + * The value is, e.g. 0
    + * comment: The milliseconds for (relative or absolute) adjust time (set only when test) @LongType *dynamic in development + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getTimeAdjustTimeMillis(); + + /** + * Get the value for the key 'time.adjust.time.millis' as {@link Long}.
    + * The value is, e.g. 0
    + * comment: The milliseconds for (relative or absolute) adjust time (set only when test) @LongType *dynamic in development + * @return The value of found property. (NotNull: if not found, exception but basically no way) + * @throws NumberFormatException When the property is not long. + */ + Long getTimeAdjustTimeMillisAsLong(); + + /** + * Get the value for the key 'mail.send.mock'.
    + * The value is, e.g. true
    + * comment: Does it send mock mail? (true: no send actually, logging only) + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getMailSendMock(); + + /** + * Is the property for the key 'mail.send.mock' true?
    + * The value is, e.g. true
    + * comment: Does it send mock mail? (true: no send actually, logging only) + * @return The determination, true or false. (if not found, exception but basically no way) + */ + boolean isMailSendMock(); + + /** + * Get the value for the key 'mail.smtp.server.main.host.and.port'.
    + * The value is, e.g. localhost:25
    + * comment: SMTP server settings for main: host:port + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getMailSmtpServerMainHostAndPort(); + + /** + * Get the value for the key 'mail.subject.test.prefix'.
    + * The value is, e.g. [Test]
    + * comment: The prefix of subject to show test environment or not + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getMailSubjectTestPrefix(); + + /** + * Get the value for the key 'mail.return.path'.
    + * The value is, e.g. root@localhost
    + * comment: The common return path of all mail + * @return The value of found property. (NotNull: if not found, exception but basically no way) + */ + String getMailReturnPath(); + + /** + * The simple implementation for configuration. + * @author FreeGen + */ + public static class SimpleImpl extends ObjectiveConfig implements FessEnv { + + /** The serial version UID for object serialization. (Default) */ + private static final long serialVersionUID = 1L; + + public String getLastaDiSmartDeployMode() { + return get(FessEnv.lasta_di_SMART_DEPLOY_MODE); + } + + public String getDevelopmentHere() { + return get(FessEnv.DEVELOPMENT_HERE); + } + + public boolean isDevelopmentHere() { + return is(FessEnv.DEVELOPMENT_HERE); + } + + public String getEnvironmentTitle() { + return get(FessEnv.ENVIRONMENT_TITLE); + } + + public String getFrameworkDebug() { + return get(FessEnv.FRAMEWORK_DEBUG); + } + + public boolean isFrameworkDebug() { + return is(FessEnv.FRAMEWORK_DEBUG); + } + + public String getTimeAdjustTimeMillis() { + return get(FessEnv.TIME_ADJUST_TIME_MILLIS); + } + + public Long getTimeAdjustTimeMillisAsLong() { + return getAsLong(FessEnv.TIME_ADJUST_TIME_MILLIS); + } + + public String getMailSendMock() { + return get(FessEnv.MAIL_SEND_MOCK); + } + + public boolean isMailSendMock() { + return is(FessEnv.MAIL_SEND_MOCK); + } + + public String getMailSmtpServerMainHostAndPort() { + return get(FessEnv.MAIL_SMTP_SERVER_MAIN_HOST_AND_PORT); + } + + public String getMailSubjectTestPrefix() { + return get(FessEnv.MAIL_SUBJECT_TEST_PREFIX); + } + + public String getMailReturnPath() { + return get(FessEnv.MAIL_RETURN_PATH); + } + } +} diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/FessFwAssistantDirector.java b/src/main/java/org/codelibs/fess/mylasta/direction/FessFwAssistantDirector.java new file mode 100644 index 000000000..cef0e6e16 --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/FessFwAssistantDirector.java @@ -0,0 +1,151 @@ +/* + * Copyright 2009-2015 the CodeLibs Project and the Others. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.mylasta.direction; + +import javax.annotation.Resource; + +import org.codelibs.fess.mylasta.direction.sponsor.FessActionAdjustmentProvider; +import org.codelibs.fess.mylasta.direction.sponsor.FessApiFailureHook; +import org.codelibs.fess.mylasta.direction.sponsor.FessCookieResourceProvider; +import org.codelibs.fess.mylasta.direction.sponsor.FessCurtainBeforeHook; +import org.codelibs.fess.mylasta.direction.sponsor.FessCurtainFinallyHook; +import org.codelibs.fess.mylasta.direction.sponsor.FessListedClassificationProvider; +import org.codelibs.fess.mylasta.direction.sponsor.FessMailDeliveryDepartmentCreator; +import org.codelibs.fess.mylasta.direction.sponsor.FessMultipartRequestHandler; +import org.codelibs.fess.mylasta.direction.sponsor.FessSecurityResourceProvider; +import org.codelibs.fess.mylasta.direction.sponsor.FessTimeResourceProvider; +import org.codelibs.fess.mylasta.direction.sponsor.FessUserLocaleProcessProvider; +import org.codelibs.fess.mylasta.direction.sponsor.FessUserTimeZoneProcessProvider; +import org.lastaflute.core.direction.CachedFwAssistantDirector; +import org.lastaflute.core.direction.FwAssistDirection; +import org.lastaflute.core.direction.FwCoreDirection; +import org.lastaflute.core.security.InvertibleCryptographer; +import org.lastaflute.core.security.OneWayCryptographer; +import org.lastaflute.db.dbflute.classification.ListedClassificationProvider; +import org.lastaflute.db.direction.FwDbDirection; +import org.lastaflute.web.direction.FwWebDirection; + +/** + * @author jflute + */ +public class FessFwAssistantDirector extends CachedFwAssistantDirector { + + // =================================================================================== + // Attribute + // ========= + @Resource + protected FessConfig fessConfig; + + // =================================================================================== + // Assist + // ====== + @Override + protected void prepareAssistDirection(final FwAssistDirection direction) { + direction.directConfig(nameList -> nameList.add("fess_config.properties"), "fess_env.properties"); + } + + // =================================================================================== + // Core + // ====== + @Override + protected void prepareCoreDirection(final FwCoreDirection direction) { + // this configuration is on fess_env.properties because this is true only when development + direction.directDevelopmentHere(fessConfig.isDevelopmentHere()); + + // titles of the application for logging are from configurations + direction.directLoggingTitle(fessConfig.getDomainTitle(), fessConfig.getEnvironmentTitle()); + + // this configuration is on sea_env.properties because it has no influence to production + // even if you set true manually and forget to set false back + direction.directFrameworkDebug(fessConfig.isFrameworkDebug()); // basically false + + // you can add your own process when your application is booting or closing + direction.directCurtainBefore(createCurtainBeforeHook()); + direction.directCurtainFinally(createCurtainFinallyHook()); // when destroy + + direction.directSecurity(createSecurityResourceProvider()); + direction.directTime(createTimeResourceProvider()); + direction.directMail(createFessMailDeliveryDepartmentCreator().create()); + } + + protected FessCurtainBeforeHook createCurtainBeforeHook() { + return new FessCurtainBeforeHook(); + } + + protected FessCurtainFinallyHook createCurtainFinallyHook() { + return new FessCurtainFinallyHook(); + } + + protected FessSecurityResourceProvider createSecurityResourceProvider() { // #change_it_first + final InvertibleCryptographer inver = InvertibleCryptographer.createAesCipher("*unused@"); + final OneWayCryptographer oneWay = OneWayCryptographer.createSha256Cryptographer(); + return new FessSecurityResourceProvider(inver, oneWay); + } + + protected FessTimeResourceProvider createTimeResourceProvider() { + return new FessTimeResourceProvider(fessConfig); + } + + protected FessMailDeliveryDepartmentCreator createFessMailDeliveryDepartmentCreator() { + return new FessMailDeliveryDepartmentCreator(fessConfig); + } + + // =================================================================================== + // DB + // ==== + @Override + protected void prepareDbDirection(final FwDbDirection direction) { + direction.directClassification(createListedClassificationProvider()); + } + + protected ListedClassificationProvider createListedClassificationProvider() { + return new FessListedClassificationProvider(); + } + + // =================================================================================== + // Web + // ===== + @Override + protected void prepareWebDirection(final FwWebDirection direction) { + direction.directRequest(createUserLocaleProcessProvider(), createUserTimeZoneProcessProvider()); + direction.directCookie(createCookieResourceProvider()); + direction.directAdjustment(createActionAdjustmentProvider()); + direction.directMessage(nameList -> nameList.add("fess_message"), "fess_label"); + direction.directApiCall(createApiFailureHook()); + direction.directMultipart(() -> new FessMultipartRequestHandler()); + } + + protected FessUserLocaleProcessProvider createUserLocaleProcessProvider() { + return new FessUserLocaleProcessProvider(); + } + + protected FessUserTimeZoneProcessProvider createUserTimeZoneProcessProvider() { + return new FessUserTimeZoneProcessProvider(); + } + + protected FessCookieResourceProvider createCookieResourceProvider() { // #change_it_first + final InvertibleCryptographer cr = InvertibleCryptographer.createAesCipher("*unused@"); + return new FessCookieResourceProvider(fessConfig, cr); + } + + protected FessActionAdjustmentProvider createActionAdjustmentProvider() { + return new FessActionAdjustmentProvider(); + } + + protected FessApiFailureHook createApiFailureHook() { + return new FessApiFailureHook(); + } +} diff --git a/src/test/java/org/codelibs/fess/lasta/LastaEnvTest.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessActionAdjustmentProvider.java similarity index 51% rename from src/test/java/org/codelibs/fess/lasta/LastaEnvTest.java rename to src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessActionAdjustmentProvider.java index 3a3a5db3f..dfc1bd927 100644 --- a/src/test/java/org/codelibs/fess/lasta/LastaEnvTest.java +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessActionAdjustmentProvider.java @@ -1,5 +1,5 @@ /* - * Copyright 2009-2015 the CodeLibs Project and the Others. + * Copyright 2014-2015 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,23 +13,23 @@ * either express or implied. See the License for the specific language * governing permissions and limitations under the License. */ +package org.codelibs.fess.mylasta.direction.sponsor; -package org.codelibs.fess.lasta; - -import javax.annotation.Resource; - -import org.codelibs.fess.lasta.core.direction.FessConfig; -import org.codelibs.fess.unit.UnitFessContainerTestCase; +import org.dbflute.util.DfTypeUtil; +import org.lastaflute.web.path.ActionAdjustmentProvider; /** * @author jflute */ -public class LastaEnvTest extends UnitFessContainerTestCase { +public class FessActionAdjustmentProvider implements ActionAdjustmentProvider { - @Resource - protected FessConfig fessConfig; + // _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ + // you can adjust your actions by overriding + // default methods defined at the interface + // _/_/_/_/_/_/_/_/_/_/ - public void test_boot() throws Exception { - assertNotNull(fessConfig); + @Override + public String toString() { + return DfTypeUtil.toClassTitle(this) + ":{}"; } } diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessApiFailureHook.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessApiFailureHook.java new file mode 100644 index 000000000..f2382e001 --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessApiFailureHook.java @@ -0,0 +1,91 @@ +/* + * Copyright 2014-2015 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.mylasta.direction.sponsor; + +import java.util.List; + +import org.dbflute.optional.OptionalThing; +import org.lastaflute.web.api.ApiFailureHook; +import org.lastaflute.web.api.ApiFailureResource; +import org.lastaflute.web.login.exception.LoginUnauthorizedException; +import org.lastaflute.web.response.ApiResponse; +import org.lastaflute.web.response.JsonResponse; + +/** + * @author jflute + */ +public class FessApiFailureHook implements ApiFailureHook { // #change_it for handling API failure + + // =================================================================================== + // Definition + // ========== + protected static final int HTTP_BAD_REQUEST = 400; + protected static final int HTTP_UNAUTHORIZED = 401; + + // =================================================================================== + // Business Failure + // ================ + @Override + public ApiResponse handleValidationError(final ApiFailureResource resource) { + return asJson(createFailureBean(resource)).httpStatus(HTTP_BAD_REQUEST); + } + + @Override + public ApiResponse handleApplicationException(final ApiFailureResource resource, final RuntimeException cause) { + final int status; + if (cause instanceof LoginUnauthorizedException) { + status = HTTP_UNAUTHORIZED; // unauthorized + } else { + status = HTTP_BAD_REQUEST; // bad request + } + return asJson(createFailureBean(resource)).httpStatus(status); + } + + // =================================================================================== + // System Failure + // ============== + @Override + public OptionalThing handleClientException(final ApiFailureResource resource, final RuntimeException cause) { + return OptionalThing.empty(); // means empty body (HTTP status will be automatically sent) + } + + @Override + public OptionalThing handleServerException(final ApiFailureResource resource, final Throwable cause) { + return OptionalThing.empty(); // means empty body (HTTP status will be automatically sent) + } + + // =================================================================================== + // Assist Logic + // ============ + protected JsonResponse asJson(final TooSimpleFailureBean bean) { + return new JsonResponse(bean); + } + + protected TooSimpleFailureBean createFailureBean(final ApiFailureResource resource) { + return new TooSimpleFailureBean(resource.getMessageList()); + } + + public static class TooSimpleFailureBean { + + public final String notice = "[Attension] tentative JSON so you should change it: " + FessApiFailureHook.class; + + public final List messageList; + + public TooSimpleFailureBean(final List messageList) { + this.messageList = messageList; + } + } +} diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessCookieResourceProvider.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessCookieResourceProvider.java new file mode 100644 index 000000000..a9e46a37e --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessCookieResourceProvider.java @@ -0,0 +1,49 @@ +/* + * Copyright 2014-2015 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.mylasta.direction.sponsor; + +import org.codelibs.fess.mylasta.direction.FessConfig; +import org.lastaflute.core.security.InvertibleCryptographer; +import org.lastaflute.web.servlet.cookie.CookieResourceProvider; + +/** + * @author jflute + */ +public class FessCookieResourceProvider implements CookieResourceProvider { + + protected final FessConfig harborConfig; + protected final InvertibleCryptographer cookieCipher; + + public FessCookieResourceProvider(final FessConfig harborConfig, final InvertibleCryptographer cookieCipher) { + this.harborConfig = harborConfig; + this.cookieCipher = cookieCipher; + } + + @Override + public String provideDefaultPath() { + return harborConfig.getCookieDefaultPath(); + } + + @Override + public Integer provideDefaultExpire() { + return harborConfig.getCookieDefaultExpireAsInteger(); + } + + @Override + public InvertibleCryptographer provideCipher() { + return cookieCipher; + } +} diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessCurtainBeforeHook.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessCurtainBeforeHook.java new file mode 100644 index 000000000..281a3c5e1 --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessCurtainBeforeHook.java @@ -0,0 +1,57 @@ +/* + * Copyright 2014-2015 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.mylasta.direction.sponsor; + +import java.util.TimeZone; + +import org.dbflute.system.DBFluteSystem; +import org.dbflute.system.provider.DfFinalTimeZoneProvider; +import org.dbflute.util.DfTypeUtil; +import org.lastaflute.core.direction.CurtainBeforeHook; +import org.lastaflute.core.direction.FwAssistantDirector; + +/** + * @author jflute + */ +public class FessCurtainBeforeHook implements CurtainBeforeHook { + + @Override + public void hook(final FwAssistantDirector assistantDirector) { + processDBFluteSystem(); + } + + protected void processDBFluteSystem() { + DBFluteSystem.unlock(); + DBFluteSystem.setFinalTimeZoneProvider(createFinalTimeZoneProvider()); + DBFluteSystem.lock(); + } + + protected DfFinalTimeZoneProvider createFinalTimeZoneProvider() { + return new DfFinalTimeZoneProvider() { + protected final TimeZone provided = FessUserTimeZoneProcessProvider.centralTimeZone; + + @Override + public TimeZone provide() { + return provided; + } + + @Override + public String toString() { + return DfTypeUtil.toClassTitle(this) + ":{" + provided.getID() + "}"; + } + }; + } +} diff --git a/src/main/java/org/codelibs/fess/servlet/Tomcat7ConfigServlet.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessCurtainFinallyHook.java similarity index 67% rename from src/main/java/org/codelibs/fess/servlet/Tomcat7ConfigServlet.java rename to src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessCurtainFinallyHook.java index 1cf4472ca..588f01e84 100644 --- a/src/main/java/org/codelibs/fess/servlet/Tomcat7ConfigServlet.java +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessCurtainFinallyHook.java @@ -1,5 +1,5 @@ /* - * Copyright 2009-2015 the CodeLibs Project and the Others. + * Copyright 2014-2015 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,39 +13,36 @@ * either express or implied. See the License for the specific language * governing permissions and limitations under the License. */ - -package org.codelibs.fess.servlet; +package org.codelibs.fess.mylasta.direction.sponsor; import java.lang.reflect.Method; -import javax.servlet.http.HttpServlet; - +import org.lastaflute.core.direction.CurtainFinallyHook; +import org.lastaflute.core.direction.FwAssistantDirector; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -public class Tomcat7ConfigServlet extends HttpServlet { - private static final Logger logger = LoggerFactory.getLogger(Tomcat7ConfigServlet.class); +/** + * @author jflute + */ +public class FessCurtainFinallyHook implements CurtainFinallyHook { - private static final long serialVersionUID = 1L; + private static final Logger logger = LoggerFactory.getLogger(FessCurtainFinallyHook.class); @Override - public void destroy() { - if (logger.isInfoEnabled()) { - logger.info("Removing HTTP connection manager..."); - } + public void hook(final FwAssistantDirector assistantDirector) { shutdownCommonsHttpClient(); } - private void shutdownCommonsHttpClient() { + private void shutdownCommonsHttpClient() { // from Tomcat7ConfigServlet (old class) try { final Class clazz = Class.forName("org.apache.commons.httpclient.MultiThreadedHttpConnectionManager"); - final Method method = clazz.getMethod("shutdownAll", null); - method.invoke(null, null); + final Method method = clazz.getMethod("shutdownAll", (Class[]) null); + method.invoke(null, (Object[]) null); } catch (final ClassNotFoundException e) { // ignore } catch (final Exception e) { logger.warn("Could not shutdown Commons HttpClient.", e); } } - } diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessListedClassificationProvider.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessListedClassificationProvider.java new file mode 100644 index 000000000..b13e74ac1 --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessListedClassificationProvider.java @@ -0,0 +1,64 @@ +/* + * Copyright 2014-2015 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.mylasta.direction.sponsor; + +import java.util.Locale; + +import org.dbflute.jdbc.ClassificationMeta; +import org.dbflute.optional.OptionalObject; +import org.dbflute.optional.OptionalThing; +import org.lastaflute.db.dbflute.classification.ListedClassificationProvider; +import org.lastaflute.db.dbflute.exception.ProvidedClassificationNotFoundException; + +/** + * @author jflute + */ +public class FessListedClassificationProvider implements ListedClassificationProvider { + + @Override + public ClassificationMeta provide(final String classificationName) throws ProvidedClassificationNotFoundException { + final ClassificationMeta onMainSchema = findOnMainSchema(classificationName); + if (onMainSchema == null) { + final String msg = "Not found the classification: " + classificationName; + throw new ProvidedClassificationNotFoundException(msg); + } + return onMainSchema; + } + + protected ClassificationMeta findOnMainSchema(final String classificationName) throws ProvidedClassificationNotFoundException { + // *no use DBFlute classification + return null; + //String searchName = classificationName; + //if (classificationName.contains(".")) { + // final String dbName = Srl.substringFirstFront(classificationName, "."); + // if (dbName.equals(DBCurrent.getInstance().projectName())) { + // searchName = Srl.substringFirstRear(classificationName, "."); + // } else { + // return null; + // } + //} + //try { + // return CDef.DefMeta.valueOf(searchName); + //} catch (IllegalArgumentException ignored) { // not found + // return null; // handled later + //} + } + + @Override + public OptionalThing determineAlias(final Locale locale) { + return OptionalObject.empty(); + } +} diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessMailDeliveryDepartmentCreator.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessMailDeliveryDepartmentCreator.java new file mode 100644 index 000000000..268ee68a3 --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessMailDeliveryDepartmentCreator.java @@ -0,0 +1,150 @@ +/* + * Copyright 2014-2015 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.mylasta.direction.sponsor; + +import java.util.List; +import java.util.Locale; + +import org.codelibs.fess.mylasta.direction.FessConfig; +import org.dbflute.mail.send.SMailDeliveryDepartment; +import org.dbflute.mail.send.SMailPostalMotorbike; +import org.dbflute.mail.send.SMailPostalParkingLot; +import org.dbflute.mail.send.SMailPostalPersonnel; +import org.dbflute.mail.send.embedded.personnel.SMailDogmaticPostalPersonnel; +import org.dbflute.mail.send.embedded.receptionist.SMailConventionReceptionist; +import org.dbflute.mail.send.supplement.async.SMailAsyncStrategy; +import org.dbflute.mail.send.supplement.filter.SMailSubjectFilter; +import org.dbflute.mail.send.supplement.label.SMailLabelStrategy; +import org.dbflute.optional.OptionalThing; +import org.dbflute.util.DfStringUtil; +import org.lastaflute.core.magic.async.AsyncManager; +import org.lastaflute.core.magic.async.ConcurrentAsyncCall; +import org.lastaflute.core.message.MessageManager; +import org.lastaflute.core.util.ContainerUtil; + +/** + * @author jflute + */ +public class FessMailDeliveryDepartmentCreator { + + // =================================================================================== + // Attribute + // ========= + protected final FessConfig fessConfig; + + // =================================================================================== + // Constructor + // =========== + public FessMailDeliveryDepartmentCreator(final FessConfig fessConfig) { + this.fessConfig = fessConfig; + } + + // =================================================================================== + // Create + // ====== + public SMailDeliveryDepartment create() { + return new SMailDeliveryDepartment(createPostalParkingLot(), createPostalPersonnel()); + } + + // ----------------------------------------------------- + // Postal Parking Lot + // ------------------ + protected SMailPostalParkingLot createPostalParkingLot() { + final SMailPostalParkingLot parkingLot = new SMailPostalParkingLot(); + final SMailPostalMotorbike motorbike = new SMailPostalMotorbike(); + final String hostAndPort = fessConfig.getMailSmtpServerMainHostAndPort(); + final List hostPortList = DfStringUtil.splitListTrimmed(hostAndPort, ":"); + motorbike.registerConnectionInfo(hostPortList.get(0), Integer.parseInt(hostPortList.get(1))); + motorbike.registerReturnPath(fessConfig.getMailReturnPath()); + parkingLot.registerMotorbikeAsMain(motorbike); + return parkingLot; + } + + // ----------------------------------------------------- + // Postal Personnel + // ---------------- + protected SMailPostalPersonnel createPostalPersonnel() { + final SMailDogmaticPostalPersonnel personnel = createDogmaticPostalPersonnel(); + return fessConfig.isMailSendMock() ? personnel.asTraining() : personnel; + } + + protected SMailDogmaticPostalPersonnel createDogmaticPostalPersonnel() { // #ext_point e.g. locale, database + final String testPrefix = fessConfig.getMailSubjectTestPrefix(); + final AsyncManager asyncManager = getAsyncManager(); + final MessageManager messageManager = getMessageManager(); + return new SMailDogmaticPostalPersonnel() { + + // *if you need user locale switching or templates from database, + // override createConventionReceptionist() (see the method for the details) + @Override + protected SMailConventionReceptionist createConventionReceptionist() { + return super.createConventionReceptionist().asReceiverLocale(postcard -> { + return OptionalThing.empty(); + }); + } + + @Override + protected OptionalThing createSubjectFilter() { + return OptionalThing.of((view, subject) -> testPrefix + subject); + } + + @Override + protected OptionalThing createAsyncStrategy() { + return OptionalThing.of((view, runnable) -> async(asyncManager, runnable)); + } + + @Override + protected OptionalThing createLabelStrategy() { + return OptionalThing.of((view, locale, label) -> resolveLabelIfNeeds(messageManager, locale, label)); + } + }; + } + + // =================================================================================== + // Asynchronous + // ============ + protected void async(final AsyncManager asyncManager, final Runnable runnable) { + asyncManager.async(new ConcurrentAsyncCall() { + @Override + public void callback() { + runnable.run(); + } + + @Override + public boolean asPrimary() { + return true; // mail is primary business + } + }); + } + + // =================================================================================== + // Resolve Label + // ============= + protected String resolveLabelIfNeeds(final MessageManager messageManager, final Locale locale, final String label) { + return label.startsWith("labels.") ? messageManager.getMessage(locale, label) : label; + } + + // =================================================================================== + // Component + // ========= + protected MessageManager getMessageManager() { + return ContainerUtil.getComponent(MessageManager.class); + } + + protected AsyncManager getAsyncManager() { + return ContainerUtil.getComponent(AsyncManager.class); + } +} diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessMultipartRequestHandler.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessMultipartRequestHandler.java new file mode 100644 index 000000000..e6e5920aa --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessMultipartRequestHandler.java @@ -0,0 +1,402 @@ +/* + * Copyright 2014-2015 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.mylasta.direction.sponsor; + +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.io.Serializable; +import java.util.Hashtable; +import java.util.Iterator; +import java.util.List; +import java.util.Map; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServletRequest; + +import org.apache.commons.fileupload.FileItem; +import org.apache.commons.fileupload.FileUploadBase.SizeLimitExceededException; +import org.apache.commons.fileupload.FileUploadException; +import org.apache.commons.fileupload.disk.DiskFileItemFactory; +import org.apache.commons.fileupload.servlet.ServletFileUpload; +import org.dbflute.helper.message.ExceptionMessageBuilder; +import org.lastaflute.web.LastaWebKey; +import org.lastaflute.web.exception.ForcedRequest404NotFoundException; +import org.lastaflute.web.ruts.config.ModuleConfig; +import org.lastaflute.web.ruts.multipart.MultipartFormFile; +import org.lastaflute.web.ruts.multipart.MultipartRequestHandler; +import org.lastaflute.web.ruts.multipart.MultipartRequestWrapper; +import org.lastaflute.web.ruts.multipart.exception.MultipartExceededException; +import org.lastaflute.web.util.LaServletContextUtil; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +/** + * @author modified by jflute (originated in Seasar) + */ +public class FessMultipartRequestHandler implements MultipartRequestHandler { + + // =================================================================================== + // Definition + // ========== + private static final Logger logger = LoggerFactory.getLogger(FessMultipartRequestHandler.class); + public static final long DEFAULT_SIZE_MAX = 250 * 1024 * 1024; // 250MB + public static final int DEFAULT_SIZE_THRESHOLD = 256 * 1024; // 250KB + protected static final String CONTEXT_TEMPDIR_KEY = "javax.servlet.context.tempdir"; + protected static final String JAVA_IO_TMPDIR_KEY = "java.io.tmpdir"; + + // =================================================================================== + // Attribute + // ========= + protected Map elementsAll; + protected Map elementsFile; + protected Map elementsText; + + // =================================================================================== + // Handle Request + // ============== + @Override + public void handleRequest(final HttpServletRequest request) throws ServletException { + // /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + // copied from super's method and extends it + // basically for JVN#14876762 + // thought not all problems are resolved however the main case is safety + // - - - - - - - - - -/ + final ServletFileUpload upload = createServletFileUpload(request); + prepareElementsHash(); + try { + final List items = parseRequest(request, upload); + mappingParameter(request, items); + } catch (final SizeLimitExceededException e) { + handleSizeLimitExceededException(request, e); + } catch (final FileUploadException e) { + handleFileUploadException(e); + } + } + + protected ModuleConfig getModuleConfig(final HttpServletRequest request) { + return (ModuleConfig) request.getAttribute(LastaWebKey.MODULE_CONFIG_KEY); + } + + // =================================================================================== + // Create ServletFileUpload + // ======================== + protected ServletFileUpload createServletFileUpload(final HttpServletRequest request) { + final DiskFileItemFactory fileItemFactory = createDiskFileItemFactory(); + final ServletFileUpload upload = newServletFileUpload(fileItemFactory); + upload.setHeaderEncoding(request.getCharacterEncoding()); + upload.setSizeMax(getSizeMax()); + return upload; + } + + protected ServletFileUpload newServletFileUpload(final DiskFileItemFactory fileItemFactory) { + return new ServletFileUpload(fileItemFactory) { + @Override + protected byte[] getBoundary(final String contentType) { // for security + final byte[] boundary = super.getBoundary(contentType); + checkBoundarySize(contentType, boundary); + return boundary; + } + }; + } + + protected void checkBoundarySize(final String contentType, final byte[] boundary) { + final int boundarySize = boundary.length; + final int limitSize = getBoundaryLimitSize(); + if (boundarySize > getBoundaryLimitSize()) { + throwTooLongBoundarySizeException(contentType, boundarySize, limitSize); + } + } + + protected int getBoundaryLimitSize() { + // one HTTP proxy tool already limits the size (e.g. 3450 bytes) + // so specify this size for test + return 2000; // you can override as you like it + } + + protected void throwTooLongBoundarySizeException(final String contentType, final int boundarySize, final int limitSize) { + final ExceptionMessageBuilder br = new ExceptionMessageBuilder(); + br.addNotice("Too long boundary size so treats it as 404."); + br.addItem("Advice"); + br.addElement("Against for JVN14876762."); + br.addElement("Boundary size is limited by Framework."); + br.addElement("Too long boundary is treated as 404 because it's thought of as attack."); + br.addElement(""); + br.addElement("While, you can override the boundary limit size"); + br.addElement(" in " + FessMultipartRequestHandler.class.getSimpleName() + "."); + br.addItem("Content Type"); + br.addElement(contentType); + br.addItem("Boundary Size"); + br.addElement(boundarySize); + br.addItem("Limit Size"); + br.addElement(limitSize); + final String msg = br.buildExceptionMessage(); + throw new ForcedRequest404NotFoundException(msg); // heavy attack!? so give no page to tell wasted action + } + + protected DiskFileItemFactory createDiskFileItemFactory() { + final File repository = createRepositoryFile(); + return new DiskFileItemFactory((int) getSizeThreshold(), repository); + } + + protected File createRepositoryFile() { + return new File(getRepositoryPath()); + } + + // =================================================================================== + // Handling Parts + // ============== + protected void prepareElementsHash() { + elementsText = new Hashtable(); + elementsFile = new Hashtable(); + elementsAll = new Hashtable(); + } + + protected List parseRequest(final HttpServletRequest request, final ServletFileUpload upload) throws FileUploadException { + return upload.parseRequest(request); + } + + protected void mappingParameter(final HttpServletRequest request, final List items) { + showFieldLoggingTitle(); + final Iterator iter = items.iterator(); + while (iter.hasNext()) { + final FileItem item = iter.next(); + if (item.isFormField()) { + showFormFieldParameter(item); + addTextParameter(request, item); + } else { + showFileFieldParameter(item); + addFileParameter(item); + } + } + } + + protected void showFieldLoggingTitle() { + // logging filter cannot show the parameters when multi-part so logging here + if (logger.isDebugEnabled()) { + logger.debug("[Multipart Request Parameter]"); + } + } + + protected void showFormFieldParameter(final FileItem item) { + if (logger.isDebugEnabled()) { + logger.debug("[param] {}={}", item.getFieldName(), item.getString()); + } + } + + protected void showFileFieldParameter(final FileItem item) { + if (logger.isDebugEnabled()) { + logger.debug("[param] {}:{name={}, size={}}", item.getFieldName(), item.getName(), item.getSize()); + } + } + + protected void handleSizeLimitExceededException(final HttpServletRequest request, final SizeLimitExceededException e) { + final long actual = e.getActualSize(); + final long permitted = e.getPermittedSize(); + final String msg = "Exceeded size of the multipart request: actual=" + actual + " permitted=" + permitted; + request.setAttribute(MAX_LENGTH_EXCEEDED_KEY, new MultipartExceededException(msg, actual, permitted, e)); + try { + final InputStream is = request.getInputStream(); + try { + final byte[] buf = new byte[1024]; + while ((is.read(buf)) != -1) {} + } catch (final Exception ignored) {} finally { + try { + is.close(); + } catch (final Exception ignored) {} + } + } catch (final Exception ignored) {} + } + + protected void handleFileUploadException(final FileUploadException e) throws ServletException { + // suppress logging because it can be caught by logging filter + //log.error("Failed to parse multipart request", e); + throw new ServletException("Failed to upload the file.", e); + } + + // =================================================================================== + // Roll-back + // ========= + @Override + public void rollback() { + final Iterator iter = elementsFile.values().iterator(); + while (iter.hasNext()) { + final MultipartFormFile formFile = iter.next(); + formFile.destroy(); + } + } + + // =================================================================================== + // Add Text + // ======== + protected void addTextParameter(final HttpServletRequest request, final FileItem item) { + final String name = item.getFieldName(); + final String encoding = request.getCharacterEncoding(); + String value = null; + boolean haveValue = false; + if (encoding != null) { + try { + value = item.getString(encoding); + haveValue = true; + } catch (final Exception e) {} + } + if (!haveValue) { + try { + value = item.getString("ISO-8859-1"); + } catch (final java.io.UnsupportedEncodingException uee) { + value = item.getString(); + } + haveValue = true; + } + if (request instanceof MultipartRequestWrapper) { + final MultipartRequestWrapper wrapper = (MultipartRequestWrapper) request; + wrapper.setParameter(name, value); + } + final String[] oldArray = elementsText.get(name); + final String[] newArray; + if (oldArray != null) { + newArray = new String[oldArray.length + 1]; + System.arraycopy(oldArray, 0, newArray, 0, oldArray.length); + newArray[oldArray.length] = value; + } else { + newArray = new String[] { value }; + } + elementsText.put(name, newArray); + elementsAll.put(name, newArray); + } + + protected void addFileParameter(final FileItem item) { + final MultipartFormFile formFile = newActionMultipartFormFile(item); + elementsFile.put(item.getFieldName(), formFile); + elementsAll.put(item.getFieldName(), formFile); + } + + protected ActionMultipartFormFile newActionMultipartFormFile(final FileItem item) { + return new ActionMultipartFormFile(item); + } + + // =================================================================================== + // Finish + // ====== + @Override + public void finish() { + rollback(); + } + + // =================================================================================== + // Small Helper + // ============ + protected long getSizeMax() { + return DEFAULT_SIZE_MAX; + } + + protected long getSizeThreshold() { + return DEFAULT_SIZE_THRESHOLD; + } + + protected String getRepositoryPath() { + String tempDir = null; + if (tempDir == null || tempDir.length() == 0) { + final File tempDirFile = (File) LaServletContextUtil.getServletContext().getAttribute(CONTEXT_TEMPDIR_KEY); + tempDir = tempDirFile.getAbsolutePath(); + if (tempDir == null || tempDir.length() == 0) { + tempDir = System.getProperty(JAVA_IO_TMPDIR_KEY); + } + } + return tempDir; + } + + // =================================================================================== + // Form File + // ========= + protected static class ActionMultipartFormFile implements MultipartFormFile, Serializable { + + private static final long serialVersionUID = 1L; + + protected final FileItem fileItem; + + public ActionMultipartFormFile(final FileItem fileItem) { + this.fileItem = fileItem; + } + + @Override + public byte[] getFileData() throws IOException { + return fileItem.get(); + } + + @Override + public InputStream getInputStream() throws IOException { + return fileItem.getInputStream(); + } + + @Override + public String getContentType() { + return fileItem.getContentType(); + } + + @Override + public int getFileSize() { + return (int) fileItem.getSize(); + } + + @Override + public String getFileName() { + return getBaseFileName(fileItem.getName()); + } + + protected String getBaseFileName(final String filePath) { + final String fileName = new File(filePath).getName(); + int colonIndex = fileName.indexOf(":"); + if (colonIndex == -1) { + colonIndex = fileName.indexOf("\\\\"); // Windows SMB + } + final int backslashIndex = fileName.lastIndexOf("\\"); + if (colonIndex > -1 && backslashIndex > -1) { + return fileName.substring(backslashIndex + 1); + } else { + return fileName; + } + } + + @Override + public void destroy() { + fileItem.delete(); + } + + @Override + public String toString() { + return "formFile:{" + getFileName() + "}"; + } + } + + // =================================================================================== + // Accessor + // ======== + @Override + public Map getAllElements() { + return elementsAll; + } + + @Override + public Map getTextElements() { + return elementsText; + } + + @Override + public Map getFileElements() { + return elementsFile; + } +} diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessSecurityResourceProvider.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessSecurityResourceProvider.java new file mode 100644 index 000000000..c723c2f04 --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessSecurityResourceProvider.java @@ -0,0 +1,45 @@ +/* + * Copyright 2014-2015 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.mylasta.direction.sponsor; + +import org.lastaflute.core.security.InvertibleCryptographer; +import org.lastaflute.core.security.OneWayCryptographer; +import org.lastaflute.core.security.SecurityResourceProvider; + +/** + * @author jflute + */ +public class FessSecurityResourceProvider implements SecurityResourceProvider { + + protected final InvertibleCryptographer primaryInvertibleCryptographer; + protected final OneWayCryptographer primaryOneWayCryptographer; + + public FessSecurityResourceProvider(final InvertibleCryptographer primaryInvertibleCryptographer, + final OneWayCryptographer primaryOneWayCryptographer) { + this.primaryInvertibleCryptographer = primaryInvertibleCryptographer; + this.primaryOneWayCryptographer = primaryOneWayCryptographer; + } + + @Override + public InvertibleCryptographer providePrimaryInvertibleCryptographer() { + return primaryInvertibleCryptographer; + } + + @Override + public OneWayCryptographer providePrimaryOneWayCryptographer() { + return primaryOneWayCryptographer; + } +} diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessTimeResourceProvider.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessTimeResourceProvider.java new file mode 100644 index 000000000..b7a4f4df0 --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessTimeResourceProvider.java @@ -0,0 +1,60 @@ +/* + * Copyright 2014-2015 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.mylasta.direction.sponsor; + +import java.util.TimeZone; + +import org.codelibs.fess.mylasta.direction.FessConfig; +import org.lastaflute.core.time.TypicalTimeResourceProvider; + +/** + * @author jflute + */ +public class FessTimeResourceProvider extends TypicalTimeResourceProvider { + + // =================================================================================== + // Attribute + // ========= + protected final FessConfig fessConfig; + + // =================================================================================== + // Constructor + // =========== + public FessTimeResourceProvider(final FessConfig fessConfig) { + this.fessConfig = fessConfig; + } + + // =================================================================================== + // Basic Handling + // ============== + @Override + protected TimeZone getCentralTimeZone() { + return FessUserTimeZoneProcessProvider.centralTimeZone; + } + + // =================================================================================== + // Time Adjustment + // =============== + @Override + protected String getTimeAdjustTimeMillis() { + return fessConfig.getTimeAdjustTimeMillis(); + } + + @Override + protected Long getTimeAdjustTimeMillisAsLong() { + return fessConfig.getTimeAdjustTimeMillisAsLong(); + } +} diff --git a/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessUserLocaleProcessProvider.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessUserLocaleProcessProvider.java new file mode 100644 index 000000000..87408de1a --- /dev/null +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessUserLocaleProcessProvider.java @@ -0,0 +1,55 @@ +/* + * Copyright 2014-2015 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific language + * governing permissions and limitations under the License. + */ +package org.codelibs.fess.mylasta.direction.sponsor; + +import java.util.Locale; + +import org.dbflute.optional.OptionalObject; +import org.dbflute.optional.OptionalThing; +import org.dbflute.util.DfTypeUtil; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.servlet.request.RequestManager; +import org.lastaflute.web.servlet.request.UserLocaleProcessProvider; + +/** + * @author jflute + */ +public class FessUserLocaleProcessProvider implements UserLocaleProcessProvider { + + @Override + public boolean isAcceptCookieLocale() { + return false; + } + + @Override + public OptionalThing findBusinessLocale(final ActionRuntime runtimeMeta, final RequestManager requestManager) { + return OptionalObject.empty(); // to next determination + } + + @Override + public OptionalThing getRequestedLocale(final RequestManager requestManager) { + return OptionalObject.empty(); // means browser default + } + + // =================================================================================== + // Basic Override + // ============== + @Override + public String toString() { + final String hash = Integer.toHexString(hashCode()); + return DfTypeUtil.toClassTitle(this) + ":{acceptCookieLocale=" + isAcceptCookieLocale() + "}@" + hash; + } +} diff --git a/src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessUserTimeZoneProcessProvider.java b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessUserTimeZoneProcessProvider.java similarity index 53% rename from src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessUserTimeZoneProcessProvider.java rename to src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessUserTimeZoneProcessProvider.java index 7f0f9283c..56e754d44 100644 --- a/src/main/java/org/codelibs/fess/lasta/core/direction/sponsor/FessUserTimeZoneProcessProvider.java +++ b/src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessUserTimeZoneProcessProvider.java @@ -1,5 +1,5 @@ /* - * Copyright 2009-2015 the CodeLibs Project and the Others. + * Copyright 2014-2015 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,68 +13,51 @@ * either express or implied. See the License for the specific language * governing permissions and limitations under the License. */ -package org.codelibs.fess.lasta.core.direction.sponsor; +package org.codelibs.fess.mylasta.direction.sponsor; import java.util.TimeZone; -import org.dbflute.saflute.web.action.callback.ActionExecuteMeta; -import org.dbflute.saflute.web.servlet.request.RequestManager; -import org.dbflute.saflute.web.servlet.request.UserTimeZoneProcessProvider; +import org.dbflute.optional.OptionalObject; +import org.dbflute.optional.OptionalThing; +import org.dbflute.util.DfTypeUtil; +import org.lastaflute.web.callback.ActionRuntime; +import org.lastaflute.web.servlet.request.RequestManager; +import org.lastaflute.web.servlet.request.UserTimeZoneProcessProvider; /** * @author jflute */ public class FessUserTimeZoneProcessProvider implements UserTimeZoneProcessProvider { - public static final TimeZone centralTimeZone = TimeZone.getDefault(); // you can change it if you like + public static final TimeZone centralTimeZone = TimeZone.getDefault(); - /** - * {@inheritDoc} - */ @Override public boolean isUseTimeZoneHandling() { return false; } - /** - * {@inheritDoc} - */ @Override public boolean isAcceptCookieTimeZone() { return false; } - /** - * {@inheritDoc} - */ @Override - public TimeZone findBusinessTimeZone(ActionExecuteMeta executeMeta, RequestManager requestManager) { - return null; + public OptionalThing findBusinessTimeZone(final ActionRuntime runtimeMeta, final RequestManager requestManager) { + return OptionalObject.empty(); } - /** - * {@inheritDoc} - */ @Override - public TimeZone getRequestedTimeZone(RequestManager requestManager) { - return centralTimeZone; // same as fall-back - } - - /** - * {@inheritDoc} - */ - @Override - public TimeZone getFallbackTimeZone() { - return centralTimeZone; + public TimeZone getRequestedTimeZone(final RequestManager requestManager) { // not null + return centralTimeZone; // you can change it if you like } @Override public String toString() { final StringBuilder sb = new StringBuilder(); - sb.append("{useTimeZoneHandling=").append(isUseTimeZoneHandling()); + sb.append(DfTypeUtil.toClassTitle(this)); + sb.append(":{useTimeZoneHandling=").append(isUseTimeZoneHandling()); sb.append(", acceptCookieTimeZone=").append(isAcceptCookieTimeZone()); - sb.append(", fallbackTimeZone=").append(getFallbackTimeZone()); - sb.append("}"); + sb.append("}@").append(Integer.toHexString(hashCode())); return sb.toString(); } } diff --git a/src/main/java/org/codelibs/fess/screenshot/ScreenShotManager.java b/src/main/java/org/codelibs/fess/screenshot/ScreenShotManager.java index 49358b62a..c4d61ed31 100644 --- a/src/main/java/org/codelibs/fess/screenshot/ScreenShotManager.java +++ b/src/main/java/org/codelibs/fess/screenshot/ScreenShotManager.java @@ -24,19 +24,20 @@ import java.util.Map; import java.util.concurrent.BlockingQueue; import java.util.concurrent.LinkedBlockingQueue; +import javax.annotation.PostConstruct; +import javax.annotation.PreDestroy; import javax.annotation.Resource; import javax.servlet.ServletContext; import javax.servlet.http.HttpSession; +import org.codelibs.core.collection.LruHashMap; import org.codelibs.core.lang.StringUtil; import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; import org.codelibs.fess.helper.FieldHelper; import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.robot.util.LruHashMap; -import org.seasar.framework.container.annotation.tiger.DestroyMethod; -import org.seasar.framework.container.annotation.tiger.InitMethod; -import org.seasar.struts.util.RequestUtil; +import org.codelibs.fess.util.DocumentUtil; +import org.lastaflute.web.util.LaRequestUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -66,7 +67,7 @@ public class ScreenShotManager { private Thread screenshotGeneratorThread; - @InitMethod + @PostConstruct public void init() { if (baseDir == null) { final String path = application.getRealPath(DEFAULT_SCREENSHOT_DIR); @@ -102,7 +103,7 @@ public class ScreenShotManager { screenshotGeneratorThread.start(); } - @DestroyMethod + @PreDestroy public void destroy() { generating = false; screenshotGeneratorThread.interrupt(); @@ -112,7 +113,7 @@ public class ScreenShotManager { final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); for (final ScreenShotGenerator generator : generatorList) { if (generator.isTarget(docMap)) { - final String url = (String) docMap.get(fieldHelper.urlField); + final String url = DocumentUtil.getValue(docMap, fieldHelper.urlField, String.class); final String path = getImageFilename(docMap); if (!screenShotTaskQueue.offer(new ScreenShotTask(url, new File(baseDir, path), generator))) { logger.warn("Failed to offer a screenshot task: " + url + " -> " + path); @@ -125,7 +126,7 @@ public class ScreenShotManager { protected String getImageFilename(final Map docMap) { final StringBuilder buf = new StringBuilder(50); final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - final String docid = (String) docMap.get(fieldHelper.docIdField); + final String docid = DocumentUtil.getValue(docMap, fieldHelper.docIdField, String.class); for (int i = 0; i < docid.length(); i++) { if (i > 0 && i % splitSize == 0) { buf.append('/'); @@ -146,12 +147,12 @@ public class ScreenShotManager { dataMap.put(docid, screenShotPath); } } - final Map> screenShotPathCache = getScreenShotPathCache(RequestUtil.getRequest().getSession()); + final Map> screenShotPathCache = getScreenShotPathCache(LaRequestUtil.getRequest().getSession()); screenShotPathCache.put(queryId, dataMap); } public File getScreenShotFile(final String queryId, final String docId) { - final HttpSession session = RequestUtil.getRequest().getSession(false); + final HttpSession session = LaRequestUtil.getRequest().getSession(false); if (session != null) { final Map> screenShotPathCache = getScreenShotPathCache(session); final Map dataMap = screenShotPathCache.get(queryId); diff --git a/src/main/java/org/codelibs/fess/screenshot/impl/CommandGenerator.java b/src/main/java/org/codelibs/fess/screenshot/impl/CommandGenerator.java index 7bbb46ceb..15a5eb31d 100644 --- a/src/main/java/org/codelibs/fess/screenshot/impl/CommandGenerator.java +++ b/src/main/java/org/codelibs/fess/screenshot/impl/CommandGenerator.java @@ -25,18 +25,16 @@ import java.util.List; import java.util.Timer; import java.util.TimerTask; +import javax.annotation.PostConstruct; +import javax.annotation.PreDestroy; + import org.apache.commons.io.IOUtils; -import org.seasar.framework.container.annotation.tiger.Binding; -import org.seasar.framework.container.annotation.tiger.BindingType; -import org.seasar.framework.container.annotation.tiger.DestroyMethod; -import org.seasar.framework.container.annotation.tiger.InitMethod; import org.slf4j.Logger; import org.slf4j.LoggerFactory; public class CommandGenerator extends BaseScreenShotGenerator { private static final Logger logger = LoggerFactory.getLogger(CommandGenerator.class); - @Binding(bindingType = BindingType.MUST) public List commandList; public long commandTimeout = 10 * 1000;// 10sec @@ -45,7 +43,7 @@ public class CommandGenerator extends BaseScreenShotGenerator { private volatile Timer destoryTimer; - @InitMethod + @PostConstruct public void init() { if (baseDir == null) { baseDir = new File(application.getRealPath("/")); @@ -53,7 +51,7 @@ public class CommandGenerator extends BaseScreenShotGenerator { destoryTimer = new Timer("CommandGeneratorDestoryTimer-" + System.currentTimeMillis(), true); } - @DestroyMethod + @PreDestroy public void destroy() { destoryTimer.cancel(); destoryTimer = null; diff --git a/src/main/java/org/codelibs/fess/screenshot/impl/WebDriverGenerator.java b/src/main/java/org/codelibs/fess/screenshot/impl/WebDriverGenerator.java index 8b2d930ba..f4515c675 100644 --- a/src/main/java/org/codelibs/fess/screenshot/impl/WebDriverGenerator.java +++ b/src/main/java/org/codelibs/fess/screenshot/impl/WebDriverGenerator.java @@ -22,6 +22,8 @@ import java.io.File; import java.io.FileInputStream; import java.io.IOException; +import javax.annotation.PostConstruct; +import javax.annotation.PreDestroy; import javax.imageio.ImageIO; import org.openqa.selenium.Dimension; @@ -29,8 +31,6 @@ import org.openqa.selenium.OutputType; import org.openqa.selenium.TakesScreenshot; import org.openqa.selenium.WebDriver; import org.openqa.selenium.phantomjs.PhantomJSDriver; -import org.seasar.framework.container.annotation.tiger.DestroyMethod; -import org.seasar.framework.container.annotation.tiger.InitMethod; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -48,7 +48,7 @@ public class WebDriverGenerator extends BaseScreenShotGenerator { public String imageFormatName = "png"; - @InitMethod + @PostConstruct public void init() { if (webDriver == null) { webDriver = new PhantomJSDriver(); @@ -56,7 +56,7 @@ public class WebDriverGenerator extends BaseScreenShotGenerator { webDriver.manage().window().setSize(new Dimension(windowWidth, windowHeight)); } - @DestroyMethod + @PreDestroy public void destroy() { webDriver.close(); } diff --git a/src/main/java/org/codelibs/fess/servlet/H2ConfigServlet.java b/src/main/java/org/codelibs/fess/servlet/H2ConfigServlet.java deleted file mode 100644 index d929ae5dd..000000000 --- a/src/main/java/org/codelibs/fess/servlet/H2ConfigServlet.java +++ /dev/null @@ -1,104 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.servlet; - -import java.nio.file.Files; -import java.nio.file.Paths; -import java.util.ArrayList; -import java.util.List; - -import javax.servlet.ServletException; -import javax.servlet.http.HttpServlet; - -import org.h2.tools.Server; -import org.seasar.framework.util.DisposableUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class H2ConfigServlet extends HttpServlet { - private static final Logger logger = LoggerFactory.getLogger(H2ConfigServlet.class); - - private static final long serialVersionUID = 1L; - - protected Server server = null; - - @Override - public void init() throws ServletException { - final List argList = new ArrayList(); - String value; - - try { - argList.add("-baseDir"); - value = getServletConfig().getInitParameter("baseDir"); - if (value != null) { - argList.add(value); - } else { - String baseDir = getServletContext().getRealPath("/WEB-INF/db/"); - if (Files.notExists(Paths.get(baseDir))) { - baseDir = getServletContext().getRealPath("/WEB-INF/") + "/../../h2/webapp/WEB-INF/db/"; - } - argList.add(baseDir); - } - - argList.add("-tcp"); - - value = getServletConfig().getInitParameter("tcpAllowOthers"); - if (value != null && "true".equalsIgnoreCase(value)) { - argList.add("-tcpAllowOthers"); - } - - value = getServletConfig().getInitParameter("tcpPort"); - if (value != null) { - argList.add("-tcpPort"); - argList.add(value); - } - - value = getServletConfig().getInitParameter("tcpSSL"); - if (value != null && "true".equalsIgnoreCase(value)) { - argList.add("-tcpSSL"); - } - - value = getServletConfig().getInitParameter("tcpPassword"); - if (value != null) { - argList.add("-tcpPassword"); - argList.add(value); - } - - if (logger.isInfoEnabled()) { - logger.info("Starting H2 server..."); - } - server = Server.createTcpServer(argList.toArray(new String[argList.size()])).start(); - } catch (final Exception e) { - throw new ServletException("Could not start Fess Config DB.", e); - } - } - - @Override - public void destroy() { - if (System.getProperty("java.specification.version").equals("1.7")) { - DisposableUtil.add(() -> { - if (server != null) { - server.stop(); - } - }); - } else { - if (server != null) { - server.stop(); - } - } - } -} diff --git a/src/main/java/org/codelibs/fess/struts/action/FessRequestProcessor.java b/src/main/java/org/codelibs/fess/struts/action/FessRequestProcessor.java deleted file mode 100644 index e1c4f08b5..000000000 --- a/src/main/java/org/codelibs/fess/struts/action/FessRequestProcessor.java +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.struts.action; - -import java.util.Map; - -import org.codelibs.fess.util.SearchParamMap; -import org.seasar.struts.action.S2RequestProcessor; - -public class FessRequestProcessor extends S2RequestProcessor/*ActionRequestProcessor*/{ - @Override - @SuppressWarnings("unchecked") - protected void setMapProperty(final Map map, final String name, final Object value) { - if (value instanceof String[]) { - if (map.get(SearchParamMap.CLASS_NAME) != null) { - map.put(name, value); - } else { - final String[] values = (String[]) value; - map.put(name, values.length > 0 ? values[0] : null); - } - } else { - map.put(name, value); - } - } - -} diff --git a/src/main/java/org/codelibs/fess/taglib/FessFunctions.java b/src/main/java/org/codelibs/fess/taglib/FessFunctions.java index 66e5932ec..56a6b9da3 100644 --- a/src/main/java/org/codelibs/fess/taglib/FessFunctions.java +++ b/src/main/java/org/codelibs/fess/taglib/FessFunctions.java @@ -29,7 +29,7 @@ import java.util.Map; import javax.servlet.http.HttpServletRequest; -import org.apache.commons.lang.StringEscapeUtils; +import org.apache.commons.lang3.StringEscapeUtils; import org.codelibs.core.misc.DynamicProperties; import org.codelibs.fess.Constants; import org.codelibs.fess.entity.FacetQueryView; @@ -37,8 +37,8 @@ import org.codelibs.fess.helper.HotSearchWordHelper; import org.codelibs.fess.helper.HotSearchWordHelper.Range; import org.codelibs.fess.helper.ViewHelper; import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.util.RequestUtil; -import org.seasar.struts.util.URLEncoderUtil; +import org.lastaflute.di.util.LdiURLUtil; +import org.lastaflute.web.util.LaRequestUtil; public class FessFunctions { @@ -52,7 +52,7 @@ public class FessFunctions { public static Boolean labelExists(final String value) { @SuppressWarnings("unchecked") - final Map labelValueMap = (Map) RequestUtil.getRequest().getAttribute(Constants.LABEL_VALUE_MAP); + final Map labelValueMap = (Map) LaRequestUtil.getRequest().getAttribute(Constants.LABEL_VALUE_MAP); if (labelValueMap != null) { return labelValueMap.get(value) != null; } @@ -61,7 +61,7 @@ public class FessFunctions { public static String label(final String value) { @SuppressWarnings("unchecked") - final Map labelValueMap = (Map) RequestUtil.getRequest().getAttribute(Constants.LABEL_VALUE_MAP); + final Map labelValueMap = (Map) LaRequestUtil.getRequest().getAttribute(Constants.LABEL_VALUE_MAP); if (labelValueMap != null) { final String name = labelValueMap.get(value); if (name != null) { @@ -177,7 +177,7 @@ public class FessFunctions { } private static String createQuery(final String key, final String prefix) { - final HttpServletRequest request = RequestUtil.getRequest(); + final HttpServletRequest request = LaRequestUtil.getRequest(); String query = (String) request.getAttribute(key); if (query == null) { final StringBuilder buf = new StringBuilder(100); @@ -189,9 +189,9 @@ public class FessFunctions { if (values != null) { for (final String value : values) { buf.append('&'); - buf.append(URLEncoderUtil.encode(name)); + buf.append(LdiURLUtil.encode(name, Constants.UTF_8)); buf.append('='); - buf.append(URLEncoderUtil.encode(value)); + buf.append(LdiURLUtil.encode(value, Constants.UTF_8)); } } } @@ -203,7 +203,7 @@ public class FessFunctions { } private static String createForm(final String key, final String prefix) { - final HttpServletRequest request = RequestUtil.getRequest(); + final HttpServletRequest request = LaRequestUtil.getRequest(); String query = (String) request.getAttribute(key); if (query == null) { final StringBuilder buf = new StringBuilder(100); @@ -215,9 +215,9 @@ public class FessFunctions { if (values != null) { for (final String value : values) { buf.append(""); } } diff --git a/src/main/java/org/codelibs/sastruts/core/util/ActivityUtil.java b/src/main/java/org/codelibs/fess/util/ActivityUtil.java similarity index 76% rename from src/main/java/org/codelibs/sastruts/core/util/ActivityUtil.java rename to src/main/java/org/codelibs/fess/util/ActivityUtil.java index 36cc988e9..3c5e9467d 100644 --- a/src/main/java/org/codelibs/sastruts/core/util/ActivityUtil.java +++ b/src/main/java/org/codelibs/fess/util/ActivityUtil.java @@ -13,7 +13,7 @@ * either express or implied. See the License for the specific language * governing permissions and limitations under the License. */ -package org.codelibs.sastruts.core.util; +package org.codelibs.fess.util; import javax.servlet.http.HttpServletRequest; @@ -28,23 +28,23 @@ import org.slf4j.LoggerFactory; public class ActivityUtil { private static Logger logger = LoggerFactory.getLogger("activity"); - public static void login(String username, HttpServletRequest request) { + public static void login(final String username, final HttpServletRequest request) { log(Action.LOGIN, username + ' ' + getRemoteAddr(request)); } - public static void logout(String username, HttpServletRequest request) { + public static void logout(final String username, final HttpServletRequest request) { log(Action.LOGOUT, username + ' ' + getRemoteAddr(request)); } - public static void access(String username, HttpServletRequest request) { + public static void access(final String username, final HttpServletRequest request) { log(Action.ACCESS, username + ' ' + getRemoteAddr(request) + ' ' + request.getRequestURL()); } - protected static void log(Action action, String msg) { + protected static void log(final Action action, final String msg) { logger.info("[" + action + "] " + msg); } - protected static String getRemoteAddr(HttpServletRequest request) { + protected static String getRemoteAddr(final HttpServletRequest request) { final String clientIp = request.getHeader("x-forwarded-for"); if (StringUtil.isNotBlank(clientIp)) { return clientIp; diff --git a/src/main/java/org/codelibs/fess/util/ComponentUtil.java b/src/main/java/org/codelibs/fess/util/ComponentUtil.java index 6d92fa89e..0b423c755 100644 --- a/src/main/java/org/codelibs/fess/util/ComponentUtil.java +++ b/src/main/java/org/codelibs/fess/util/ComponentUtil.java @@ -19,12 +19,12 @@ package org.codelibs.fess.util; import org.codelibs.core.crypto.CachedCipher; import org.codelibs.core.misc.DynamicProperties; import org.codelibs.fess.api.WebApiManagerFactory; -import org.codelibs.fess.client.FessEsClient; +import org.codelibs.fess.app.web.base.login.FessLoginAssist; import org.codelibs.fess.ds.DataStoreFactory; +import org.codelibs.fess.es.client.FessEsClient; import org.codelibs.fess.helper.AdRoleHelper; import org.codelibs.fess.helper.CrawlingConfigHelper; import org.codelibs.fess.helper.CrawlingSessionHelper; -import org.codelibs.fess.helper.DatabaseHelper; import org.codelibs.fess.helper.FieldHelper; import org.codelibs.fess.helper.FileTypeHelper; import org.codelibs.fess.helper.HotSearchWordHelper; @@ -42,18 +42,24 @@ import org.codelibs.fess.helper.SearchLogHelper; import org.codelibs.fess.helper.SystemHelper; import org.codelibs.fess.helper.UserAgentHelper; import org.codelibs.fess.helper.ViewHelper; +import org.codelibs.fess.indexer.IndexUpdater; import org.codelibs.fess.job.JobExecutor; -import org.codelibs.fess.solr.IndexUpdater; +import org.codelibs.robot.entity.EsAccessResult; import org.codelibs.robot.extractor.ExtractorFactory; -import org.seasar.framework.container.SingletonS2Container; +import org.codelibs.robot.service.DataService; +import org.lastaflute.core.message.MessageManager; +import org.lastaflute.di.core.SingletonLaContainer; +import org.lastaflute.di.core.factory.SingletonLaContainerFactory; public final class ComponentUtil { + private static final String DATA_SERVICE = "dataService"; + + private static final String MESSAGE_MANAGER = "messageManager"; + private static final String USER_AGENT_NAME = "userAgentName"; private static final String INDEX_UPDATER = "indexUpdater"; - private static final String DATABASE_HELPER = "databaseHelper"; - private static final String MAIL_HELPER = "mailHelper"; private static final String FILE_TYPE_HELPER = "fileTypeHelper"; @@ -114,135 +120,147 @@ public final class ComponentUtil { } public static CachedCipher getCipher(final String cipherName) { - return SingletonS2Container.getComponent(cipherName); + return SingletonLaContainer.getComponent(cipherName); } public static QueryResponseList getQueryResponseList() { - return SingletonS2Container.getComponent(QUERY_RESPONSE_LIST); + return SingletonLaContainer.getComponent(QUERY_RESPONSE_LIST); } public static DynamicProperties getSolrGroupProperties(final String groupName) { - return SingletonS2Container.getComponent(groupName + PROPERTIES_SUFFIX); + return SingletonLaContainer.getComponent(groupName + PROPERTIES_SUFFIX); } public static DynamicProperties getCrawlerProperties() { - return SingletonS2Container.getComponent(CRAWLER_PROPERTIES); + return SingletonLaContainer.getComponent(CRAWLER_PROPERTIES); } public static SystemHelper getSystemHelper() { - return SingletonS2Container.getComponent(SYSTEM_HELPER); + return SingletonLaContainer.getComponent(SYSTEM_HELPER); } public static ViewHelper getViewHelper() { - return SingletonS2Container.getComponent(VIEW_HELPER); + return SingletonLaContainer.getComponent(VIEW_HELPER); } public static SambaHelper getSambaHelper() { - return SingletonS2Container.getComponent(SAMBA_HELPER); + return SingletonLaContainer.getComponent(SAMBA_HELPER); } public static QueryHelper getQueryHelper() { - return SingletonS2Container.getComponent(QUERY_HELPER); + return SingletonLaContainer.getComponent(QUERY_HELPER); } public static LabelTypeHelper getLabelTypeHelper() { - return SingletonS2Container.getComponent(LABEL_TYPE_HELPER); + return SingletonLaContainer.getComponent(LABEL_TYPE_HELPER); } public static SearchLogHelper getSearchLogHelper() { - return SingletonS2Container.getComponent(SEARCH_LOG_HELPER); + return SingletonLaContainer.getComponent(SEARCH_LOG_HELPER); } public static CrawlingConfigHelper getCrawlingConfigHelper() { - return SingletonS2Container.getComponent(CRAWLING_CONFIG_HELPER); + return SingletonLaContainer.getComponent(CRAWLING_CONFIG_HELPER); } public static CrawlingSessionHelper getCrawlingSessionHelper() { - return SingletonS2Container.getComponent(CRAWLING_SESSION_HELPER); + return SingletonLaContainer.getComponent(CRAWLING_SESSION_HELPER); } public static HotSearchWordHelper getHotSearchWordHelper() { - return SingletonS2Container.getComponent(HOT_SEARCH_WORD_HELPER); + return SingletonLaContainer.getComponent(HOT_SEARCH_WORD_HELPER); } public static PathMappingHelper getPathMappingHelper() { - return SingletonS2Container.getComponent(PATH_MAPPING_HELPER); + return SingletonLaContainer.getComponent(PATH_MAPPING_HELPER); } public static OverlappingHostHelper getOverlappingHostHelper() { - return SingletonS2Container.getComponent(OVERLAPPING_HOST_HELPER); + return SingletonLaContainer.getComponent(OVERLAPPING_HOST_HELPER); } public static JobHelper getJobHelper() { - return SingletonS2Container.getComponent(JOB_HELPER); + return SingletonLaContainer.getComponent(JOB_HELPER); } public static WebApiManagerFactory getWebApiManagerFactory() { - return SingletonS2Container.getComponent(WEB_API_MANAGER_FACTORY); + return SingletonLaContainer.getComponent(WEB_API_MANAGER_FACTORY); } public static UserAgentHelper getUserAgentHelper() { - return SingletonS2Container.getComponent(USER_AGENT_HELPER); + return SingletonLaContainer.getComponent(USER_AGENT_HELPER); } public static DataStoreFactory getDataStoreFactory() { - return SingletonS2Container.getComponent(DATA_STORE_FACTORY); + return SingletonLaContainer.getComponent(DATA_STORE_FACTORY); } public static IntervalControlHelper getIntervalControlHelper() { - return SingletonS2Container.getComponent(INTERVAL_CONTROL_HELPER); + return SingletonLaContainer.getComponent(INTERVAL_CONTROL_HELPER); } public static ExtractorFactory getExtractorFactory() { - return SingletonS2Container.getComponent(EXTRACTOR_FACTORY); + return SingletonLaContainer.getComponent(EXTRACTOR_FACTORY); } public static JobExecutor getJobExecutor(final String name) { - return SingletonS2Container.getComponent(name + JOB_EXECUTOR_SUFFIX); + return SingletonLaContainer.getComponent(name + JOB_EXECUTOR_SUFFIX); } public static MailHelper getMailHelper() { - return SingletonS2Container.getComponent(MAIL_HELPER); + return SingletonLaContainer.getComponent(MAIL_HELPER); } public static FileTypeHelper getFileTypeHelper() { - return SingletonS2Container.getComponent(FILE_TYPE_HELPER); - } - - public static DatabaseHelper getDatabaseHelper() { - return SingletonS2Container.getComponent(DATABASE_HELPER); + return SingletonLaContainer.getComponent(FILE_TYPE_HELPER); } public static AdRoleHelper getAdRoleHelper() { - return SingletonS2Container.getComponent(AD_ROLE_HELPER); + return SingletonLaContainer.getComponent(AD_ROLE_HELPER); } public static IndexUpdater getIndexUpdater() { - return SingletonS2Container.getComponent(INDEX_UPDATER); + return SingletonLaContainer.getComponent(INDEX_UPDATER); } public static String getUserAgentName() { - return SingletonS2Container.getComponent(USER_AGENT_NAME); + return SingletonLaContainer.getComponent(USER_AGENT_NAME); } public static KeyMatchHelper getKeyMatchHelper() { - return SingletonS2Container.getComponent(KEY_MATCH_HELPER); + return SingletonLaContainer.getComponent(KEY_MATCH_HELPER); } public static IndexingHelper getIndexingHelper() { - return SingletonS2Container.getComponent(INDEXING_HELPER); + return SingletonLaContainer.getComponent(INDEXING_HELPER); } public static FieldHelper getFieldHelper() { - return SingletonS2Container.getComponent(FIELD_HELPER); + return SingletonLaContainer.getComponent(FIELD_HELPER); } public static FessEsClient getElasticsearchClient() { - return SingletonS2Container.getComponent(ELASTICSEARCH_CLIENT); + return SingletonLaContainer.getComponent(ELASTICSEARCH_CLIENT); } - public static T getComponent(Class clazz) { - return SingletonS2Container.getComponent(clazz); + public static MessageManager getMessageManager() { + return SingletonLaContainer.getComponent(MESSAGE_MANAGER); + } + + public static DataService getDataService() { + return SingletonLaContainer.getComponent(DATA_SERVICE); + } + + public static FessLoginAssist getLoginAssist() { + return getComponent(FessLoginAssist.class); + } + + public static T getComponent(final Class clazz) { + return SingletonLaContainer.getComponent(clazz); + } + + public static boolean hasQueryHelper() { + return SingletonLaContainerFactory.getContainer().hasComponentDef(QUERY_HELPER); } } diff --git a/src/main/java/org/codelibs/fess/util/DocumentUtil.java b/src/main/java/org/codelibs/fess/util/DocumentUtil.java new file mode 100644 index 000000000..0dd94840b --- /dev/null +++ b/src/main/java/org/codelibs/fess/util/DocumentUtil.java @@ -0,0 +1,87 @@ +package org.codelibs.fess.util; + +import java.util.Date; +import java.util.List; +import java.util.Map; + +import org.codelibs.fess.taglib.FessFunctions; + +public final class DocumentUtil { + + private DocumentUtil() { + } + + @SuppressWarnings("unchecked") + public static T getValue(final Map doc, final String key, final Class clazz) { + if (doc == null || key == null) { + return null; + } + + final Object value = doc.get(key); + if (value == null) { + return null; + } + + if (value instanceof List) { + if (clazz.isAssignableFrom(List.class)) { + return (T) value; + } + + if (((List) value).isEmpty()) { + return null; + } + + return convertObj(((List) value).get(0), clazz); + } + + return convertObj(value, clazz); + } + + @SuppressWarnings("unchecked") + private static T convertObj(Object value, final Class clazz) { + if (value == null) { + return null; + } + + if (clazz.isAssignableFrom(String.class)) { + return (T) value.toString(); + } else if (clazz.isAssignableFrom(Date.class)) { + if (value instanceof Date) { + return (T) value; + } else { + return (T) FessFunctions.parseDate(value.toString()); + } + } else if (clazz.isAssignableFrom(Long.class)) { + if (value instanceof Long) { + return (T) value; + } else { + return (T) Long.valueOf(value.toString()); + } + } else if (clazz.isAssignableFrom(Integer.class)) { + if (value instanceof Integer) { + return (T) value; + } else { + return (T) Integer.valueOf(value.toString()); + } + } else if (clazz.isAssignableFrom(Double.class)) { + if (value instanceof Double) { + return (T) value; + } else { + return (T) Double.valueOf(value.toString()); + } + } else if (clazz.isAssignableFrom(Float.class)) { + if (value instanceof Float) { + return (T) value; + } else { + return (T) Float.valueOf(value.toString()); + } + } else if (clazz.isAssignableFrom(Boolean.class)) { + if (value instanceof Boolean) { + return (T) value; + } else { + return (T) Boolean.valueOf(value.toString()); + } + } + return null; + } +} diff --git a/src/main/java/org/codelibs/fess/util/InputStreamThread.java b/src/main/java/org/codelibs/fess/util/InputStreamThread.java index 79aa69076..62d06263b 100644 --- a/src/main/java/org/codelibs/fess/util/InputStreamThread.java +++ b/src/main/java/org/codelibs/fess/util/InputStreamThread.java @@ -23,7 +23,7 @@ import java.io.UnsupportedEncodingException; import java.util.LinkedList; import java.util.List; -import org.codelibs.fess.FessSystemException; +import org.codelibs.fess.exception.FessSystemException; import org.slf4j.Logger; import org.slf4j.LoggerFactory; diff --git a/src/main/java/org/codelibs/fess/util/ParameterUtil.java b/src/main/java/org/codelibs/fess/util/ParameterUtil.java index 5d9e680f8..b5b6ce605 100644 --- a/src/main/java/org/codelibs/fess/util/ParameterUtil.java +++ b/src/main/java/org/codelibs/fess/util/ParameterUtil.java @@ -20,8 +20,8 @@ import java.util.HashMap; import java.util.Map; import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.FessSystemException; import org.codelibs.fess.es.exentity.CrawlingConfig.ConfigName; +import org.codelibs.fess.exception.FessSystemException; public class ParameterUtil { protected static final String XPATH_PREFIX = "field.xpath."; diff --git a/src/main/java/org/codelibs/fess/util/QueryResponseList.java b/src/main/java/org/codelibs/fess/util/QueryResponseList.java index 3c95a672e..dd30a6227 100644 --- a/src/main/java/org/codelibs/fess/util/QueryResponseList.java +++ b/src/main/java/org/codelibs/fess/util/QueryResponseList.java @@ -23,8 +23,9 @@ import java.util.Iterator; import java.util.List; import java.util.ListIterator; import java.util.Map; +import java.util.Optional; -import org.apache.commons.lang.StringUtils; +import org.apache.commons.lang3.StringUtils; import org.codelibs.fess.helper.QueryHelper; import org.codelibs.fess.helper.ViewHelper; import org.elasticsearch.action.search.SearchResponse; @@ -64,14 +65,10 @@ public class QueryResponseList implements List> { protected String searchQuery; - protected String solrQuery; - protected long execTime; protected FacetResponse facetResponse; - protected MoreLikeThisResponse moreLikeThisResponse; - protected boolean partialResults = false; protected long queryTime; @@ -85,11 +82,10 @@ public class QueryResponseList implements List> { this.parent = parent; } - public void init(final SearchResponse searchResponse, final long start, final int pageSize) { - long numFound = 0; - if (searchResponse != null) { + public void init(final Optional searchResponseOpt, final int start, final int pageSize) { + searchResponseOpt.ifPresent(searchResponse -> { final SearchHits searchHits = searchResponse.getHits(); - numFound = searchHits.getTotalHits(); + allRecordCount = searchHits.getTotalHits(); queryTime = searchResponse.getTookInMillis(); if (searchResponse.getTotalShards() != searchResponse.getSuccessfulShards()) { @@ -97,65 +93,71 @@ public class QueryResponseList implements List> { } // build highlighting fields - final QueryHelper queryHelper = ComponentUtil.getQueryHelper(); - ComponentUtil.getFieldHelper(); - final String hlPrefix = queryHelper.getHighlightingPrefix(); - for (final SearchHit searchHit : searchHits.getHits()) { - final Map docMap = new HashMap(); - docMap.putAll(searchHit.getSource()); + final QueryHelper queryHelper = ComponentUtil.getQueryHelper(); + ComponentUtil.getFieldHelper(); + final String hlPrefix = queryHelper.getHighlightPrefix(); + for (final SearchHit searchHit : searchHits.getHits()) { + final Map docMap = new HashMap(); + if (searchHit.getSource() == null) { + searchHit.getFields().forEach((key, value) -> { + docMap.put(key, value.getValue()); + }); + } else { + docMap.putAll(searchHit.getSource()); + } - final Map highlightFields = searchHit.getHighlightFields(); - try { - if (highlightFields != null) { - for (final Map.Entry entry : highlightFields.entrySet()) { - final HighlightField highlightField = entry.getValue(); - final Text[] fragments = highlightField.fragments(); - if (fragments != null && fragments.length != 0) { - final String[] texts = new String[fragments.length]; - for (int i = 0; i < fragments.length; i++) { - texts[i] = fragments[i].string(); + final Map highlightFields = searchHit.getHighlightFields(); + try { + if (highlightFields != null) { + for (final Map.Entry entry : highlightFields.entrySet()) { + final HighlightField highlightField = entry.getValue(); + final Text[] fragments = highlightField.fragments(); + if (fragments != null && fragments.length != 0) { + final String[] texts = new String[fragments.length]; + for (int i = 0; i < fragments.length; i++) { + texts[i] = fragments[i].string(); + } + final String value = StringUtils.join(texts, "..."); + docMap.put(hlPrefix + highlightField.getName(), value); } - final String value = StringUtils.join(texts, "..."); - docMap.put(hlPrefix + highlightField.getName(), value); } } + } catch (final Exception e) { + if (logger.isDebugEnabled()) { + logger.debug("Could not create a highlighting value: " + docMap, e); + } } - } catch (final Exception e) { - if (logger.isDebugEnabled()) { - logger.debug("Could not create a highlighting value: " + docMap, e); + + // ContentTitle + final ViewHelper viewHelper = ComponentUtil.getViewHelper(); + if (viewHelper != null) { + docMap.put("contentTitle", viewHelper.getContentTitle(docMap)); + docMap.put("contentDescription", viewHelper.getContentDescription(docMap)); + docMap.put("urlLink", viewHelper.getUrlLink(docMap)); + docMap.put("sitePath", viewHelper.getSitePath(docMap)); } + + parent.add(docMap); } - // ContentTitle - final ViewHelper viewHelper = ComponentUtil.getViewHelper(); - if (viewHelper != null) { - docMap.put("contentTitle", viewHelper.getContentTitle(docMap)); - docMap.put("contentDescription", viewHelper.getContentDescription(docMap)); - docMap.put("urlLink", viewHelper.getUrlLink(docMap)); - docMap.put("sitePath", viewHelper.getSitePath(docMap)); + // facet + final Aggregations aggregations = searchResponse.getAggregations(); + if (aggregations != null) { + facetResponse = new FacetResponse(aggregations); } - parent.add(docMap); - } + }); - // facet - final Aggregations aggregations = searchResponse.getAggregations(); - if (aggregations != null) { - facetResponse = new FacetResponse(aggregations); - } - - } - calculatePageInfo(start, pageSize, numFound); + calculatePageInfo(start, pageSize); } - protected void calculatePageInfo(final long start, final int size, final long numFound) { + protected void calculatePageInfo(final int start, final int size) { pageSize = size; - allRecordCount = numFound; allPageCount = (int) ((allRecordCount - 1) / pageSize) + 1; existPrevPage = start > 0; existNextPage = start < (long) (allPageCount - 1) * (long) pageSize; - currentPageNumber = (int) (start / pageSize) + 1; - currentStartRecordNumber = numFound != 0 ? (currentPageNumber - 1) * pageSize + 1 : 0; + currentPageNumber = start / pageSize + 1; + currentStartRecordNumber = allRecordCount != 0 ? (currentPageNumber - 1) * pageSize + 1 : 0; currentEndRecordNumber = currentPageNumber * pageSize; currentEndRecordNumber = allRecordCount < currentEndRecordNumber ? allRecordCount : currentEndRecordNumber; @@ -344,14 +346,6 @@ public class QueryResponseList implements List> { this.searchQuery = searchQuery; } - public String getSolrQuery() { - return solrQuery; - } - - public void setSolrQuery(final String solrQuery) { - this.solrQuery = solrQuery; - } - public long getExecTime() { return execTime; } @@ -364,10 +358,6 @@ public class QueryResponseList implements List> { return facetResponse; } - public MoreLikeThisResponse getMoreLikeThisResponse() { - return moreLikeThisResponse; - } - public boolean isPartialResults() { return partialResults; } diff --git a/src/main/java/org/codelibs/fess/util/QueryUtil.java b/src/main/java/org/codelibs/fess/util/QueryUtil.java index 183d5e3d0..528537f22 100644 --- a/src/main/java/org/codelibs/fess/util/QueryUtil.java +++ b/src/main/java/org/codelibs/fess/util/QueryUtil.java @@ -24,7 +24,7 @@ public class QueryUtil { } public static String escapeValue(final String value) { - final String escapedValue = Constants.SOLR_FIELD_RESERVED_PATTERN.matcher(value).replaceAll("\\\\$1"); + final String escapedValue = Constants.LUCENE_FIELD_RESERVED_PATTERN.matcher(value).replaceAll("\\\\$1"); if (escapedValue.length() > 1) { final char c = escapedValue.charAt(0); if (c == '*' || c == '?') { @@ -35,7 +35,7 @@ public class QueryUtil { } public static String escapeRangeValue(final String value) { - final String escapedValue = Constants.SOLR_RANGE_FIELD_RESERVED_PATTERN.matcher(value).replaceAll("\\\\$1"); + final String escapedValue = Constants.LUCENE_RANGE_FIELD_RESERVED_PATTERN.matcher(value).replaceAll("\\\\$1"); if (escapedValue.length() > 1) { final char c = escapedValue.charAt(0); if (c == '*' || c == '?') { diff --git a/src/main/java/org/codelibs/fess/util/ResourceUtil.java b/src/main/java/org/codelibs/fess/util/ResourceUtil.java index 98e394c3a..b60375a5f 100644 --- a/src/main/java/org/codelibs/fess/util/ResourceUtil.java +++ b/src/main/java/org/codelibs/fess/util/ResourceUtil.java @@ -24,8 +24,8 @@ import java.util.regex.Pattern; import javax.servlet.ServletContext; import org.codelibs.core.lang.StringUtil; -import org.seasar.framework.container.SingletonS2Container; -import org.seasar.struts.util.ServletContextUtil; +import org.lastaflute.di.core.SingletonLaContainer; +import org.lastaflute.web.util.LaServletContextUtil; public class ResourceUtil { protected ResourceUtil() { @@ -60,11 +60,11 @@ public class ResourceUtil { String path = null; try { - final ServletContext servletContext = SingletonS2Container.getComponent(ServletContext.class); + final ServletContext servletContext = SingletonLaContainer.getComponent(ServletContext.class); if (servletContext != null) { path = servletContext.getRealPath("/" + baseName + name); } - } catch (final Exception e) { // NOSONAR + } catch (final Throwable e) { // NOSONAR // ignore } if (path == null) { @@ -74,7 +74,7 @@ public class ResourceUtil { } public static File[] getJarFiles(final String namePrefix) { - final ServletContext context = ServletContextUtil.getServletContext(); + final ServletContext context = LaServletContextUtil.getServletContext(); if (context == null) { return new File[0]; } diff --git a/src/main/java/org/codelibs/fess/util/SearchParamMap.java b/src/main/java/org/codelibs/fess/util/SearchParamMap.java deleted file mode 100644 index e5a47b0a7..000000000 --- a/src/main/java/org/codelibs/fess/util/SearchParamMap.java +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.util; - -import java.util.HashMap; - -import org.codelibs.core.lang.StringUtil; - -public class SearchParamMap extends HashMap { - - private static final long serialVersionUID = 1L; - - public static final String CLASS_NAME = "org.codelibs.fess.util.SearchParamMap"; - - @Override - public String[] get(final Object key) { - if (CLASS_NAME.equals(key)) { - return StringUtil.EMPTY_STRINGS; - } - return super.get(key); - } - -} diff --git a/src/main/java/org/codelibs/fess/util/UserDictCSVUtil.java b/src/main/java/org/codelibs/fess/util/UserDictCSVUtil.java index 9c3344915..b0f106207 100644 --- a/src/main/java/org/codelibs/fess/util/UserDictCSVUtil.java +++ b/src/main/java/org/codelibs/fess/util/UserDictCSVUtil.java @@ -38,12 +38,12 @@ public final class UserDictCSVUtil { /** * Parse CSV line - * + * * @param line * line containing csv-encoded data * @return Array of values */ - public static String[] parse(String line) { + public static String[] parse(final String line) { boolean insideQuote = false; final ArrayList result = new ArrayList<>(); int quoteCount = 0; @@ -77,7 +77,7 @@ public final class UserDictCSVUtil { return result.toArray(new String[result.size()]); } - private static String unQuoteUnEscape(String original) { + private static String unQuoteUnEscape(final String original) { String result = original; // Unquote @@ -100,7 +100,7 @@ public final class UserDictCSVUtil { /** * Quote and escape input value for CSV */ - public static String quoteEscape(String original) { + public static String quoteEscape(final String original) { String result = original; if (result.indexOf('\"') >= 0) { diff --git a/src/main/java/org/codelibs/fess/util/WebApiUtil.java b/src/main/java/org/codelibs/fess/util/WebApiUtil.java index ead4963f8..8c6b57bae 100644 --- a/src/main/java/org/codelibs/fess/util/WebApiUtil.java +++ b/src/main/java/org/codelibs/fess/util/WebApiUtil.java @@ -16,8 +16,8 @@ package org.codelibs.fess.util; -import org.codelibs.fess.WebApiException; -import org.seasar.struts.util.RequestUtil; +import org.codelibs.fess.exception.WebApiException; +import org.lastaflute.web.util.LaRequestUtil; public final class WebApiUtil { @@ -27,25 +27,25 @@ public final class WebApiUtil { } public static void setObject(final String name, final Object value) { - RequestUtil.getRequest().setAttribute(name, value); + LaRequestUtil.getRequest().setAttribute(name, value); } public static T getObject(final String name) { @SuppressWarnings("unchecked") - final T value = (T) RequestUtil.getRequest().getAttribute(name); + final T value = (T) LaRequestUtil.getRequest().getAttribute(name); return value; } public static void setError(final int statusCode, final String message) { - RequestUtil.getRequest().setAttribute(WEB_API_EXCEPTION, new WebApiException(statusCode, message)); + LaRequestUtil.getRequest().setAttribute(WEB_API_EXCEPTION, new WebApiException(statusCode, message)); } public static void setError(final int statusCode, final Exception e) { - RequestUtil.getRequest().setAttribute(WEB_API_EXCEPTION, new WebApiException(statusCode, e)); + LaRequestUtil.getRequest().setAttribute(WEB_API_EXCEPTION, new WebApiException(statusCode, e)); } public static void validate() { - final WebApiException e = (WebApiException) RequestUtil.getRequest().getAttribute(WEB_API_EXCEPTION); + final WebApiException e = (WebApiException) LaRequestUtil.getRequest().getAttribute(WEB_API_EXCEPTION); if (e != null) { throw e; } diff --git a/src/main/java/org/codelibs/fess/validator/CronExpressionChecks.java b/src/main/java/org/codelibs/fess/validator/CronExpressionChecks.java index cd17d26f6..41e2939a8 100644 --- a/src/main/java/org/codelibs/fess/validator/CronExpressionChecks.java +++ b/src/main/java/org/codelibs/fess/validator/CronExpressionChecks.java @@ -16,28 +16,6 @@ package org.codelibs.fess.validator; -import javax.servlet.http.HttpServletRequest; - -import org.apache.commons.validator.Field; -import org.apache.commons.validator.Validator; -import org.apache.commons.validator.ValidatorAction; -import org.apache.struts.action.ActionMessages; -import org.codelibs.core.lang.StringUtil; -import org.quartz.CronExpression; -import org.seasar.struts.validator.S2FieldChecks; - -public class CronExpressionChecks extends S2FieldChecks { - - private static final long serialVersionUID = 1L; - - public static boolean validateCronExpression(final Object bean, final ValidatorAction validatorAction, final Field field, - final ActionMessages errors, final Validator validator, final HttpServletRequest request) { - final String value = getValueAsString(bean, field); - if (StringUtil.isNotBlank(value) && !CronExpression.isValidExpression(value)) { - addError(errors, field, validator, validatorAction, request); - return false; - } - return true; - } - +//TODO replace with hibernate validator +public class CronExpressionChecks /*extends S2FieldChecks*/{ } diff --git a/src/main/java/org/codelibs/fess/validator/UriTypeChecks.java b/src/main/java/org/codelibs/fess/validator/UriTypeChecks.java index 47a0e2086..447ccd52e 100644 --- a/src/main/java/org/codelibs/fess/validator/UriTypeChecks.java +++ b/src/main/java/org/codelibs/fess/validator/UriTypeChecks.java @@ -16,36 +16,28 @@ package org.codelibs.fess.validator; -import javax.servlet.http.HttpServletRequest; - -import org.apache.commons.validator.Field; -import org.apache.commons.validator.Validator; -import org.apache.commons.validator.ValidatorAction; -import org.apache.struts.action.ActionMessages; import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.FessSystemException; -import org.seasar.struts.validator.S2FieldChecks; -public class UriTypeChecks extends S2FieldChecks { +// TODO replace with hibernate validator +public class UriTypeChecks /*extends S2FieldChecks*/{ - private static final long serialVersionUID = 1L; - - public static boolean validateUriType(final Object bean, final ValidatorAction validatorAction, final Field field, - final ActionMessages errors, final Validator validator, final HttpServletRequest request) { - final String value = getValueAsString(bean, field); - if (StringUtil.isNotBlank(value)) { - final String protocols = field.getVarValue("protocols"); - if (StringUtil.isEmpty(protocols)) { - throw new FessSystemException("protocols is empty."); - } - if (!check(protocols, value)) { - addError(errors, field, validator, validatorAction, request); - return false; + /* + public static boolean validateUriType(final Object bean, final ValidatorAction validatorAction, final Field field, + final ActionMessages errors, final Validator validator, final HttpServletRequest request) { + final String value = getValueAsString(bean, field); + if (StringUtil.isNotBlank(value)) { + final String protocols = field.getVarValue("protocols"); + if (StringUtil.isEmpty(protocols)) { + throw new FessSystemException("protocols is empty."); + } + if (!check(protocols, value)) { + addError(errors, field, validator, validatorAction, request); + return false; + } } + return true; } - return true; - } - + */ protected static boolean check(final String protocols, final String values) { final String[] prtcls = protocols.split(","); final String[] paths = values.split("[\r\n]"); diff --git a/src/main/java/org/codelibs/fess/web/ErrorAction.java b/src/main/java/org/codelibs/fess/web/ErrorAction.java deleted file mode 100644 index 174e99d1c..000000000 --- a/src/main/java/org/codelibs/fess/web/ErrorAction.java +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web; - -import javax.annotation.Resource; - -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; - -public class ErrorAction { - - @ActionForm - @Resource - protected ErrorForm errorForm; - - @Execute(validator = false) - public String index() { - return "notFound.jsp"; - } - - @Execute(validator = false) - public String systemError() { - return "system.jsp"; - } - - @Execute(validator = false) - public String badRequest() { - return "badRequest.jsp"; - } - - @Execute(validator = false) - public String notFound() { - return "notFound.jsp"; - } -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/IndexAction.java b/src/main/java/org/codelibs/fess/web/IndexAction.java deleted file mode 100644 index 39acda24e..000000000 --- a/src/main/java/org/codelibs/fess/web/IndexAction.java +++ /dev/null @@ -1,1190 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web; - -import java.awt.Desktop; -import java.io.BufferedInputStream; -import java.io.File; -import java.io.FileInputStream; -import java.io.IOException; -import java.io.OutputStream; -import java.io.UnsupportedEncodingException; -import java.net.URLDecoder; -import java.net.URLEncoder; -import java.text.NumberFormat; -import java.time.Clock; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Enumeration; -import java.util.HashSet; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Locale; -import java.util.Map; -import java.util.Set; -import java.util.regex.Matcher; -import java.util.regex.Pattern; - -import javax.annotation.Resource; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; -import javax.servlet.http.HttpSession; - -import org.apache.commons.io.IOUtils; -import org.apache.commons.lang.StringEscapeUtils; -import org.apache.commons.lang.StringUtils; -import org.codelibs.core.lang.StringUtil; -import org.codelibs.core.misc.DynamicProperties; -import org.codelibs.fess.Constants; -import org.codelibs.fess.InvalidQueryException; -import org.codelibs.fess.ResultOffsetExceededException; -import org.codelibs.fess.UnsupportedSearchException; -import org.codelibs.fess.client.FessEsClient; -import org.codelibs.fess.client.FessEsClient.SearchConditionBuilder; -import org.codelibs.fess.entity.LoginInfo; -import org.codelibs.fess.es.exentity.ClickLog; -import org.codelibs.fess.es.exentity.SearchLog; -import org.codelibs.fess.es.exentity.UserInfo; -import org.codelibs.fess.helper.CrawlingConfigHelper; -import org.codelibs.fess.helper.FieldHelper; -import org.codelibs.fess.helper.HotSearchWordHelper; -import org.codelibs.fess.helper.HotSearchWordHelper.Range; -import org.codelibs.fess.helper.LabelTypeHelper; -import org.codelibs.fess.helper.OpenSearchHelper; -import org.codelibs.fess.helper.QueryHelper; -import org.codelibs.fess.helper.RoleQueryHelper; -import org.codelibs.fess.helper.SearchLogHelper; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.helper.UserInfoHelper; -import org.codelibs.fess.helper.ViewHelper; -import org.codelibs.fess.screenshot.ScreenShotManager; -import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.fess.util.FacetResponse; -import org.codelibs.fess.util.MoreLikeThisResponse; -import org.codelibs.fess.util.QueryResponseList; -import org.codelibs.fess.util.WebApiUtil; -import org.codelibs.robot.util.CharUtil; -import org.codelibs.sastruts.core.SSCConstants; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.dbflute.optional.OptionalEntity; -import org.elasticsearch.index.query.QueryBuilders; -import org.elasticsearch.index.query.TermQueryBuilder; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.container.annotation.tiger.Binding; -import org.seasar.framework.container.annotation.tiger.BindingType; -import org.seasar.framework.container.annotation.tiger.InitMethod; -import org.seasar.framework.util.InputStreamUtil; -import org.seasar.framework.util.OutputStreamUtil; -import org.seasar.framework.util.URLUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.taglib.S2Functions; -import org.seasar.struts.util.MessageResourcesUtil; -import org.seasar.struts.util.RequestUtil; -import org.seasar.struts.util.ResponseUtil; -import org.seasar.struts.util.URLEncoderUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class IndexAction { - - private static final Logger logger = LoggerFactory.getLogger(IndexAction.class); - - private static final String REDIRECT_TO_INDEX = "index?redirect=true"; - - private static final String LABEL_FIELD = "label"; - - protected static final long DEFAULT_START_COUNT = 0; - - protected static final int DEFAULT_PAGE_SIZE = 20; - - protected static final int MAX_PAGE_SIZE = 100; - - protected static final int DEFAULT_SUGGEST_PAGE_SIZE = 5; - - protected static final int DEFAULT_SPELLCHECK_PAGE_SIZE = 5; - - protected static final Pattern FIELD_EXTRACTION_PATTERN = Pattern.compile("^([a-zA-Z0-9_]+):.*"); - - @ActionForm - @Resource - protected IndexForm indexForm; - - @Resource - protected FessEsClient fessEsClient; - - @Binding(bindingType = BindingType.MAY) - @Resource - protected ScreenShotManager screenShotManager; - - @Resource - protected LabelTypeHelper labelTypeHelper; - - @Resource - protected ViewHelper viewHelper; - - @Resource - protected QueryHelper queryHelper; - - @Resource - protected RoleQueryHelper roleQueryHelper; - - @Resource - protected UserInfoHelper userInfoHelper; - - @Resource - protected OpenSearchHelper openSearchHelper; - - @Resource - protected SystemHelper systemHelper; - - @Resource - protected FieldHelper fieldHelper; - - @Resource - protected DynamicProperties crawlerProperties; - - @Resource - protected HttpServletRequest request; - - @Resource - protected HttpServletResponse response; - - public List> documentItems; - - public FacetResponse facetResponse; - - public MoreLikeThisResponse moreLikeThisResponse; - - public String pageSize; - - public String currentPageNumber; - - public String allRecordCount; - - public String allPageCount; - - public boolean existNextPage; - - public boolean existPrevPage; - - public String currentStartRecordNumber; - - public String currentEndRecordNumber; - - public List pageNumberList; - - public String execTime; - - public String queryTime = Constants.INVALID_NUMERIC_PARAMETER; - - public String searchTime = Constants.INVALID_NUMERIC_PARAMETER; - - public boolean partialResults; - - public List> labelTypeItems; - - public List> langItems; - - public String errorMessage; - - protected String pagingQuery = null; - - public boolean searchLogSupport; - - public boolean favoriteSupport; - - public boolean screenShotSupport; - - public String username; - - public String appendHighlightQueries; - - @InitMethod - public void init() { - searchLogSupport = Constants.TRUE.equals(crawlerProperties.getProperty(Constants.SEARCH_LOG_PROPERTY, Constants.TRUE)); - favoriteSupport = Constants.TRUE.equals(crawlerProperties.getProperty(Constants.USER_FAVORITE_PROPERTY, Constants.FALSE)); - } - - public String getPagingQuery() { - if (pagingQuery == null) { - final StringBuilder buf = new StringBuilder(200); - if (indexForm.additional != null) { - final Set fieldSet = new HashSet(); - for (final String additional : indexForm.additional) { - if (StringUtil.isNotBlank(additional) && additional.length() < 1000 && !hasFieldInQuery(fieldSet, additional)) { - buf.append("&additional=").append(S2Functions.u(additional)); - } - } - } - if (StringUtil.isNotBlank(indexForm.sort)) { - buf.append("&sort=").append(S2Functions.u(indexForm.sort)); - } - if (StringUtil.isNotBlank(indexForm.op)) { - buf.append("&op=").append(S2Functions.u(indexForm.op)); - } - if (indexForm.lang != null) { - final Set langSet = new HashSet(); - for (final String lang : indexForm.lang) { - if (StringUtil.isNotBlank(lang) && lang.length() < 1000) { - if (Constants.ALL_LANGUAGES.equals(lang)) { - langSet.clear(); - break; - } - final String normalizeLang = systemHelper.normalizeLang(lang); - if (normalizeLang != null) { - langSet.add(normalizeLang); - } - } - } - if (!langSet.isEmpty()) { - for (final String lang : langSet) { - buf.append("&lang=").append(S2Functions.u(lang)); - } - } - } - if (!indexForm.fields.isEmpty()) { - for (final Map.Entry entry : indexForm.fields.entrySet()) { - final String[] values = entry.getValue(); - if (values != null) { - for (final String v : values) { - if (StringUtil.isNotBlank(v)) { - buf.append("&fields.").append(S2Functions.u(entry.getKey())).append('=').append(S2Functions.u(v)); - } - } - } - } - } - - pagingQuery = buf.toString(); - } - return pagingQuery; - } - - @Execute(validator = false, input = "index.jsp") - public String index() { - searchAvailable(); - - buildViewParams(); - buildInitParams(); - - return "index.jsp"; - } - - protected void searchAvailable() { - final String supportedSearch = - crawlerProperties.getProperty(Constants.SUPPORTED_SEARCH_FEATURE_PROPERTY, Constants.SUPPORTED_SEARCH_WEB); - if (Constants.SUPPORTED_SEARCH_NONE.equals(supportedSearch)) { - throw new UnsupportedSearchException("A search is not supported: " + RequestUtil.getRequest().getRequestURL()); - } - } - - protected String doSearch() { - searchAvailable(); - - if (StringUtil.isBlank(indexForm.query)) { - try { - final String optionQuery = queryHelper.buildOptionQuery(indexForm.options); - indexForm.query = optionQuery; - } catch (final InvalidQueryException e) { - if (logger.isDebugEnabled()) { - logger.debug(e.getMessage(), e); - } - throw new SSCActionMessagesException(e, e.getMessageCode()); - } - } - - if (StringUtil.isBlank(indexForm.query) && indexForm.fields.isEmpty()) { - // redirect to index page - indexForm.query = null; - return REDIRECT_TO_INDEX; - } - - updateSearchParams(); - buildViewParams(); - doSearchInternal(); - - return "search.jsp"; - } - - @Execute(validator = true, input = "index") - public String cache() { - Map doc = null; - try { - doc = fessEsClient.getDocument(fieldHelper.docIndex, fieldHelper.docType, queryRequestBuilder -> { - final TermQueryBuilder termQuery = QueryBuilders.termQuery(fieldHelper.docIdField, indexForm.docId); - queryRequestBuilder.setQuery(termQuery); - queryRequestBuilder.addFields(queryHelper.getResponseFields()); - return true; - }).get(); - } catch (final Exception e) { - logger.warn("Failed to request: " + indexForm.docId, e); - } - if (doc == null) { - errorMessage = MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "errors.docid_not_found", indexForm.docId); - return "error.jsp"; - } - - final String content = viewHelper.createCacheContent(doc, indexForm.hq); - if (content == null) { - errorMessage = MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "errors.docid_not_found", indexForm.docId); - return "error.jsp"; - } - ResponseUtil.write(content, "text/html", Constants.UTF_8); - - return null; - } - - @Execute(validator = true, input = "index") - public String go() throws IOException { - Map doc = null; - try { - doc = fessEsClient.getDocument(fieldHelper.docIndex, fieldHelper.docType, queryRequestBuilder -> { - final TermQueryBuilder termQuery = QueryBuilders.termQuery(fieldHelper.docIdField, indexForm.docId); - queryRequestBuilder.setQuery(termQuery); - queryRequestBuilder.addFields(queryHelper.getResponseFields()); - return true; - }).get(); - } catch (final Exception e) { - logger.warn("Failed to request: " + indexForm.docId, e); - } - if (doc == null) { - errorMessage = MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "errors.docid_not_found", indexForm.docId); - return "error.jsp"; - } - final Object urlObj = doc.get(fieldHelper.urlField); - if (urlObj == null) { - errorMessage = - MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "errors.document_not_found", indexForm.docId); - return "error.jsp"; - } - final String url = urlObj.toString(); - - if (Constants.TRUE.equals(crawlerProperties.getProperty(Constants.SEARCH_LOG_PROPERTY, Constants.TRUE))) { - final String userSessionId = userInfoHelper.getUserCode(); - if (userSessionId != null) { - final SearchLogHelper searchLogHelper = ComponentUtil.getSearchLogHelper(); - final ClickLog clickLog = new ClickLog(); - clickLog.setUrl(url); - final long now = systemHelper.getCurrentTimeAsLong(); - clickLog.setRequestedTime(now); - clickLog.setQueryRequestedTime(Long.parseLong(indexForm.rt)); - clickLog.setUserSessionId(userSessionId); - clickLog.setDocId(indexForm.docId); - long clickCount = 0; - final Object count = doc.get(fieldHelper.clickCountField); - if (count instanceof Long) { - clickCount = ((Long) count).longValue(); - } - clickLog.setClickCount(clickCount); - searchLogHelper.addClickLog(clickLog); - } - } - - String hash; - if (StringUtil.isNotBlank(indexForm.hash)) { - final String value = URLUtil.decode(indexForm.hash, Constants.UTF_8); - final StringBuilder buf = new StringBuilder(value.length() + 100); - for (final char c : value.toCharArray()) { - if (CharUtil.isUrlChar(c) || c == ' ') { - buf.append(c); - } else { - try { - buf.append(URLEncoder.encode(String.valueOf(c), Constants.UTF_8)); - } catch (final UnsupportedEncodingException e) { - // NOP - } - } - } - hash = buf.toString(); - } else { - hash = StringUtil.EMPTY; - } - - if (isFileSystemPath(url)) { - if (Constants.TRUE.equals(crawlerProperties.getProperty(Constants.SEARCH_FILE_PROXY_PROPERTY, Constants.TRUE))) { - final CrawlingConfigHelper crawlingConfigHelper = ComponentUtil.getCrawlingConfigHelper(); - try { - crawlingConfigHelper.writeContent(doc); - return null; - } catch (final Exception e) { - logger.error("Failed to load: " + doc, e); - errorMessage = - MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "errors.not_load_from_server", url); - return "error.jsp"; - } - } else if (Constants.TRUE.equals(crawlerProperties.getProperty(Constants.SEARCH_DESKTOP_PROPERTY, Constants.FALSE))) { - final String path = url.replaceFirst("file:/+", "//"); - final File file = new File(path); - if (!file.exists()) { - errorMessage = - MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "errors.not_found_on_file_system", url); - return "error.jsp"; - } - final Desktop desktop = Desktop.getDesktop(); - try { - desktop.open(file); - } catch (final Exception e) { - errorMessage = - MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "errors.could_not_open_on_system", url); - logger.warn("Could not open " + path, e); - return "error.jsp"; - } - - ResponseUtil.getResponse().setStatus(HttpServletResponse.SC_NO_CONTENT); - return null; - } else { - ResponseUtil.getResponse().sendRedirect(url + hash); - } - } else { - ResponseUtil.getResponse().sendRedirect(url + hash); - } - return null; - } - - @Execute(validator = false, input = "index") - public String search() { - if (viewHelper.isUseSession() && StringUtil.isNotBlank(indexForm.num)) { - normalizePageNum(); - final HttpSession session = request.getSession(); - if (session != null) { - session.setAttribute(Constants.RESULTS_PER_PAGE, indexForm.num); - } - } - - return doSearch(); - } - - @Execute(validator = false, input = "index") - public String prev() { - return doMove(-1); - } - - @Execute(validator = false, input = "index") - public String next() { - return doMove(1); - } - - @Execute(validator = false, input = "index") - public String move() { - return doMove(0); - } - - @Execute(validator = false) - public String screenshot() { - OutputStream out = null; - BufferedInputStream in = null; - try { - final Map doc = fessEsClient.getDocument(fieldHelper.docIndex, fieldHelper.docType, queryRequestBuilder -> { - final TermQueryBuilder termQuery = QueryBuilders.termQuery(fieldHelper.docIdField, indexForm.docId); - queryRequestBuilder.setQuery(termQuery); - queryRequestBuilder.addFields(queryHelper.getResponseFields()); - return true; - }).get(); - final String url = doc == null ? null : (String) doc.get(fieldHelper.urlField); - if (StringUtil.isBlank(indexForm.queryId) || StringUtil.isBlank(url) || screenShotManager == null) { - // 404 - response.sendError(HttpServletResponse.SC_NOT_FOUND); - return null; - } - - final File screenShotFile = screenShotManager.getScreenShotFile(indexForm.queryId, indexForm.docId); - if (screenShotFile == null) { - // 404 - response.sendError(HttpServletResponse.SC_NOT_FOUND); - screenShotManager.generate(doc); - return null; - } - - response.setContentType(getImageMimeType(screenShotFile)); - - out = response.getOutputStream(); - in = new BufferedInputStream(new FileInputStream(screenShotFile)); - InputStreamUtil.copy(in, out); - OutputStreamUtil.flush(out); - } catch (final Exception e) { - logger.error("Failed to response: " + indexForm.docId, e); - } finally { - IOUtils.closeQuietly(in); - IOUtils.closeQuietly(out); - } - - return null; - } - - @Execute(validator = false) - public String searchApi() { - try { - WebApiUtil.setObject("searchQuery", doSearchInternal()); - WebApiUtil.setObject("searchTime", searchTime); - WebApiUtil.setObject("queryTime", queryTime); - WebApiUtil.setObject("execTime", execTime); - WebApiUtil.setObject("pageSize", pageSize); - WebApiUtil.setObject("currentPageNumber", currentPageNumber); - WebApiUtil.setObject("allRecordCount", allRecordCount); - WebApiUtil.setObject("allPageCount", allPageCount); - WebApiUtil.setObject("documentItems", documentItems); - WebApiUtil.setObject("facetResponse", facetResponse); - WebApiUtil.setObject("moreLikeThisResponse", moreLikeThisResponse); - } catch (final Exception e) { - WebApiUtil.setError(1, e); - } - return null; - } - - @Execute(validator = false) - public String suggestApi() { - if (Constants.FALSE.equals(crawlerProperties.getProperty(Constants.WEB_API_SUGGEST_PROPERTY, Constants.TRUE))) { - WebApiUtil.setError(9, "Unsupported operation."); - return null; - } - - if (indexForm.fn == null || indexForm.fn.length == 0) { - WebApiUtil.setError(2, "The field name is empty."); - return null; - } - - if (StringUtil.isBlank(indexForm.query)) { - WebApiUtil.setError(3, "Your query is empty."); - return null; - } - - if (StringUtil.isBlank(indexForm.num)) { - indexForm.num = String.valueOf(DEFAULT_SUGGEST_PAGE_SIZE); - } - - int num = Integer.parseInt(indexForm.num); - if (num > getMaxPageSize()) { - num = getMaxPageSize(); - } - - final String[] fieldNames = indexForm.fn; - final String[] labels = indexForm.fields.get("label"); - - // final List suggestResultList = new ArrayList(); - // WebApiUtil.setObject("suggestResultList", suggestResultList); - - final List suggestFieldName = Arrays.asList(fieldNames); - WebApiUtil.setObject("suggestFieldName", suggestFieldName); - - if (labels == null) { - new ArrayList(); - } else { - Arrays.asList(labels); - } - - try { - if (roleQueryHelper != null) { - roleQueryHelper.build(); - } else { - new HashSet<>(); - } - - // TODO - // final SuggestResponse suggestResponse = - // suggestService.getSuggestResponse(indexForm.query, suggestFieldName, labelList, new ArrayList(roleSet), num); - // - // if (!suggestResponse.isEmpty()) { - // suggestResultList.add(suggestResponse); - // } - - WebApiUtil.setObject("suggestRecordCount", 1); - } catch (final Exception e) { - WebApiUtil.setError(1, e); - } - return null; - } - - @Execute(validator = false) - public String hotSearchWordApi() { - if (Constants.FALSE.equals(crawlerProperties.getProperty(Constants.WEB_API_HOT_SEARCH_WORD_PROPERTY, Constants.TRUE))) { - WebApiUtil.setError(9, "Unsupported operation."); - return null; - } - - Range range; - if (indexForm.range == null) { - range = Range.ENTIRE; - } else if ("day".equals(indexForm.range) || "1".equals(indexForm.range)) { - range = Range.ONE_DAY; - } else if ("week".equals(indexForm.range) || "7".equals(indexForm.range)) { - range = Range.ONE_DAY; - } else if ("month".equals(indexForm.range) || "30".equals(indexForm.range)) { - range = Range.ONE_DAY; - } else if ("year".equals(indexForm.range) || "365".equals(indexForm.range)) { - range = Range.ONE_DAY; - } else { - range = Range.ENTIRE; - } - - try { - final HotSearchWordHelper hotSearchWordHelper = ComponentUtil.getHotSearchWordHelper(); - final List hotSearchWordList = hotSearchWordHelper.getHotSearchWordList(range); - WebApiUtil.setObject("hotSearchWordList", hotSearchWordList); - } catch (final Exception e) { - WebApiUtil.setError(1, e); - } - return null; - - } - - @Execute(validator = false) - public String favoriteApi() { - if (Constants.FALSE.equals(crawlerProperties.getProperty(Constants.USER_FAVORITE_PROPERTY, Constants.FALSE))) { - WebApiUtil.setError(9, "Unsupported operation."); - return null; - } - - try { - final Map doc = - indexForm.docId == null ? null : fessEsClient.getDocument(fieldHelper.docIndex, fieldHelper.docType, - queryRequestBuilder -> { - final TermQueryBuilder termQuery = QueryBuilders.termQuery(fieldHelper.docIdField, indexForm.docId); - queryRequestBuilder.setQuery(termQuery); - queryRequestBuilder.addFields(queryHelper.getResponseFields()); - return true; - }).get(); - final String userCode = userInfoHelper.getUserCode(); - final String favoriteUrl = doc == null ? null : (String) doc.get(fieldHelper.urlField); - - if (StringUtil.isBlank(userCode)) { - WebApiUtil.setError(2, "No user session."); - return null; - } else if (StringUtil.isBlank(favoriteUrl)) { - WebApiUtil.setError(2, "URL is null."); - return null; - } - - final String[] docIds = userInfoHelper.getResultDocIds(URLDecoder.decode(indexForm.queryId, Constants.UTF_8)); - if (docIds == null) { - WebApiUtil.setError(6, "No searched urls."); - return null; - } - - boolean found = false; - for (final String docId : docIds) { - if (indexForm.docId.equals(docId)) { - found = true; - break; - } - } - if (!found) { - WebApiUtil.setError(5, "Not found: " + favoriteUrl); - return null; - } - - final SearchLogHelper searchLogHelper = ComponentUtil.getSearchLogHelper(); - if (!searchLogHelper.addfavoriteLog(userCode, favoriteUrl)) { - WebApiUtil.setError(4, "Failed to add url: " + favoriteUrl); - return null; - } - - final FessEsClient fessEsClient = ComponentUtil.getElasticsearchClient(); - final Object count = doc.get(fieldHelper.favoriteCountField); - if (count instanceof Long) { - fessEsClient.update(fieldHelper.docIndex, fieldHelper.docType, indexForm.docId, fieldHelper.favoriteCountField, - ((Long) count).longValue() + 1); - } else { - WebApiUtil.setError(7, "Failed to update count: " + favoriteUrl); - return null; - } - } catch (final Exception e) { - WebApiUtil.setError(1, e); - } - return null; - - } - - @Execute(validator = false) - public String osdd() { - openSearchHelper.write(ResponseUtil.getResponse()); - return null; - } - - @Execute(validator = false, input = "index") - public String help() { - buildViewParams(); - buildInitParams(); - return "help.jsp"; - } - - protected String doSearchInternal() { - final StringBuilder queryBuf = new StringBuilder(255); - if (StringUtil.isNotBlank(indexForm.query)) { - queryBuf.append(indexForm.query); - } - if (StringUtil.isNotBlank(indexForm.op)) { - request.setAttribute(Constants.DEFAULT_OPERATOR, indexForm.op); - } - if (queryBuf.indexOf(" OR ") >= 0) { - queryBuf.insert(0, '(').append(')'); - } - if (indexForm.additional != null) { - final Set fieldSet = new HashSet(); - for (final String additional : indexForm.additional) { - if (StringUtil.isNotBlank(additional) && additional.length() < 1000 && !hasFieldInQuery(fieldSet, additional)) { - queryBuf.append(' ').append(additional); - } - } - } - if (!indexForm.fields.isEmpty()) { - for (final Map.Entry entry : indexForm.fields.entrySet()) { - final List valueList = new ArrayList(); - final String[] values = entry.getValue(); - if (values != null) { - for (final String v : values) { - valueList.add(v); - } - } - if (valueList.size() == 1) { - queryBuf.append(' ').append(entry.getKey()).append(":\"").append(valueList.get(0)).append('\"'); - } else if (valueList.size() > 1) { - queryBuf.append(" ("); - for (int i = 0; i < valueList.size(); i++) { - if (i != 0) { - queryBuf.append(" OR"); - } - queryBuf.append(' ').append(entry.getKey()).append(":\"").append(valueList.get(i)).append('\"'); - } - queryBuf.append(')'); - } - - } - } - if (StringUtil.isNotBlank(indexForm.sort)) { - queryBuf.append(" sort:").append(indexForm.sort); - } - if (indexForm.lang != null) { - final Set langSet = new HashSet<>(); - for (final String lang : indexForm.lang) { - if (StringUtil.isNotBlank(lang) && lang.length() < 1000) { - if (Constants.ALL_LANGUAGES.equalsIgnoreCase(lang)) { - langSet.add(Constants.ALL_LANGUAGES); - } else { - final String normalizeLang = systemHelper.normalizeLang(lang); - if (normalizeLang != null) { - langSet.add(normalizeLang); - } - } - } - } - if (langSet.size() > 1 && langSet.contains(Constants.ALL_LANGUAGES)) { - langSet.clear(); - indexForm.lang = new String[] { Constants.ALL_LANGUAGES }; - } else { - langSet.remove(Constants.ALL_LANGUAGES); - } - appendLangQuery(queryBuf, langSet); - } else if (Constants.TRUE.equals(crawlerProperties.getProperty(Constants.USE_BROWSER_LOCALE_FOR_SEARCH_PROPERTY, Constants.FALSE))) { - final Set langSet = new HashSet<>(); - final Enumeration locales = request.getLocales(); - if (locales != null) { - while (locales.hasMoreElements()) { - final Locale locale = locales.nextElement(); - final String normalizeLang = systemHelper.normalizeLang(locale.toString()); - if (normalizeLang != null) { - langSet.add(normalizeLang); - } - } - if (!langSet.isEmpty()) { - appendLangQuery(queryBuf, langSet); - } - } - } - - final String query = queryBuf.toString().trim(); - - // init pager - if (StringUtil.isBlank(indexForm.start)) { - indexForm.start = String.valueOf(DEFAULT_START_COUNT); - } else { - try { - Long.parseLong(indexForm.start); - } catch (final NumberFormatException e) { - indexForm.start = String.valueOf(DEFAULT_START_COUNT); - } - } - if (StringUtil.isBlank(indexForm.num)) { - indexForm.num = String.valueOf(getDefaultPageSize()); - } - normalizePageNum(); - - final int pageStart = Integer.parseInt(indexForm.start); - final int pageNum = Integer.parseInt(indexForm.num); - try { - documentItems = - fessEsClient.getDocumentList(fieldHelper.docIndex, fieldHelper.docType, - searchRequestBuilder -> { - return SearchConditionBuilder.builder(searchRequestBuilder).query(query).offset(pageStart).size(pageNum) - .facetInfo(indexForm.facet).geoInfo(indexForm.geo).responseFields(queryHelper.getResponseFields()) - .build(); - }); - } catch (final InvalidQueryException e) { - if (logger.isDebugEnabled()) { - logger.debug(e.getMessage(), e); - } - throw new SSCActionMessagesException(e, e.getMessageCode()); - } catch (final ResultOffsetExceededException e) { - if (logger.isDebugEnabled()) { - logger.debug(e.getMessage(), e); - } - throw new SSCActionMessagesException(e, "errors.result_size_exceeded"); - } - // search - final QueryResponseList queryResponseList = (QueryResponseList) documentItems; - facetResponse = queryResponseList.getFacetResponse(); - moreLikeThisResponse = queryResponseList.getMoreLikeThisResponse(); - final NumberFormat nf = NumberFormat.getInstance(RequestUtil.getRequest().getLocale()); - nf.setMaximumIntegerDigits(2); - nf.setMaximumFractionDigits(2); - try { - execTime = nf.format((double) queryResponseList.getExecTime() / 1000); - } catch (final Exception e) { - // ignore - } - - final Clock clock = Clock.systemDefaultZone(); - indexForm.rt = Long.toString(clock.millis()); - - // favorite - if (favoriteSupport || screenShotManager != null) { - indexForm.queryId = userInfoHelper.generateQueryId(query, documentItems); - if (screenShotManager != null) { - screenShotManager.storeRequest(indexForm.queryId, documentItems); - screenShotSupport = true; - } - } - - // search log - if (searchLogSupport) { - final long now = systemHelper.getCurrentTimeAsLong(); - - final SearchLogHelper searchLogHelper = ComponentUtil.getSearchLogHelper(); - final SearchLog searchLog = new SearchLog(); - - String userCode = null; - if (Constants.TRUE.equals(crawlerProperties.getProperty(Constants.USER_INFO_PROPERTY, Constants.TRUE))) { - userCode = userInfoHelper.getUserCode(); - if (StringUtil.isNotBlank(userCode)) { - final UserInfo userInfo = new UserInfo(); - userInfo.setCode(userCode); - userInfo.setCreatedTime(now); - userInfo.setUpdatedTime(now); - searchLog.setUserInfo(OptionalEntity.of(userInfo)); - } - } - - searchLog.setHitCount(queryResponseList.getAllRecordCount()); - searchLog.setResponseTime(Integer.valueOf((int) queryResponseList.getExecTime())); - searchLog.setSearchWord(StringUtils.abbreviate(query, 1000)); - searchLog.setSearchQuery(StringUtils.abbreviate(queryResponseList.getSearchQuery(), 1000)); - searchLog.setSolrQuery(StringUtils.abbreviate(queryResponseList.getSolrQuery(), 1000)); - searchLog.setRequestedTime(now); - searchLog.setQueryOffset(pageStart); - searchLog.setQueryPageSize(pageNum); - - searchLog.setClientIp(StringUtils.abbreviate(request.getRemoteAddr(), 50)); - searchLog.setReferer(StringUtils.abbreviate(request.getHeader("referer"), 1000)); - searchLog.setUserAgent(StringUtils.abbreviate(request.getHeader("user-agent"), 255)); - if (userCode != null) { - searchLog.setUserSessionId(userCode); - } - final Object accessType = request.getAttribute(Constants.SEARCH_LOG_ACCESS_TYPE); - if (Constants.SEARCH_LOG_ACCESS_TYPE_JSON.equals(accessType)) { - searchLog.setAccessType(Constants.SEARCH_LOG_ACCESS_TYPE_JSON); - } else if (Constants.SEARCH_LOG_ACCESS_TYPE_XML.equals(accessType)) { - searchLog.setAccessType(Constants.SEARCH_LOG_ACCESS_TYPE_XML); - } else if (Constants.SEARCH_LOG_ACCESS_TYPE_OTHER.equals(accessType)) { - searchLog.setAccessType(Constants.SEARCH_LOG_ACCESS_TYPE_OTHER); - } else { - searchLog.setAccessType(Constants.SEARCH_LOG_ACCESS_TYPE_WEB); - } - - @SuppressWarnings("unchecked") - final Map> fieldLogMap = (Map>) request.getAttribute(Constants.FIELD_LOGS); - if (fieldLogMap != null) { - for (final Map.Entry> logEntry : fieldLogMap.entrySet()) { - for (final String value : logEntry.getValue()) { - searchLog.addSearchFieldLogValue(logEntry.getKey(), StringUtils.abbreviate(value, 1000)); - } - } - } - - searchLogHelper.addSearchLog(searchLog); - } - - final String[] highlightQueries = (String[]) request.getAttribute(Constants.HIGHLIGHT_QUERIES); - if (highlightQueries != null) { - final StringBuilder buf = new StringBuilder(100); - for (final String q : highlightQueries) { - buf.append("&hq=").append(q); - } - appendHighlightQueries = buf.toString(); - } - - Beans.copy(documentItems, this) - .includes("pageSize", "currentPageNumber", "allRecordCount", "allPageCount", "existNextPage", "existPrevPage", - "currentStartRecordNumber", "currentEndRecordNumber", "pageNumberList", "partialResults", "queryTime", "searchTime") - .execute(); - - return query; - } - - private void appendLangQuery(final StringBuilder queryBuf, final Set langSet) { - if (langSet.size() == 1) { - queryBuf.append(' ').append(fieldHelper.langField).append(':').append(langSet.iterator().next()); - } else if (langSet.size() > 1) { - boolean first = true; - for (final String lang : langSet) { - if (first) { - queryBuf.append(" ("); - first = false; - } else { - queryBuf.append(" OR "); - } - queryBuf.append(fieldHelper.langField).append(':').append(lang); - } - queryBuf.append(')'); - } - } - - protected void updateSearchParams() { - if (indexForm.facet == null) { - indexForm.facet = queryHelper.getDefaultFacetInfo(); - } - - if (indexForm.geo == null) { - indexForm.geo = queryHelper.getDefaultGeoInfo(); - } - } - - protected boolean isFileSystemPath(final String url) { - return url.startsWith("file:") || url.startsWith("smb:"); - } - - protected String doMove(final int move) { - int pageNum = getDefaultPageSize(); - if (StringUtil.isBlank(indexForm.num)) { - indexForm.num = String.valueOf(getDefaultPageSize()); - } else { - try { - pageNum = Integer.parseInt(indexForm.num); - } catch (final NumberFormatException e) { - indexForm.num = String.valueOf(getDefaultPageSize()); - } - } - - if (StringUtil.isBlank(indexForm.pn)) { - indexForm.start = String.valueOf(DEFAULT_START_COUNT); - } else { - Integer pageNumber = Integer.parseInt(indexForm.pn); - if (pageNumber != null && pageNumber > 0) { - pageNumber = pageNumber + move; - if (pageNumber < 1) { - pageNumber = 1; - } - indexForm.start = String.valueOf((pageNumber - 1) * pageNum); - } else { - indexForm.start = String.valueOf(DEFAULT_START_COUNT); - } - } - - return doSearch(); - } - - public List> getLabelTypeItems() { - return labelTypeItems; - } - - public boolean isDisplayLabelTypeItems() { - if (labelTypeItems != null) { - return !labelTypeItems.isEmpty(); - } else { - return false; - } - } - - public String getDisplayQuery() { - final StringBuilder buf = new StringBuilder(100); - buf.append(indexForm.query); - if (!indexForm.fields.isEmpty() && indexForm.fields.containsKey(LABEL_FIELD)) { - final String[] values = indexForm.fields.get(LABEL_FIELD); - final List labelList = new ArrayList(); - if (values != null) { - for (final String v : values) { - labelList.add(v); - } - } - for (final String labelTypeValue : labelList) { - for (final Map map : labelTypeItems) { - if (map.get(Constants.ITEM_VALUE).equals(labelTypeValue)) { - buf.append(' '); - buf.append(map.get(Constants.ITEM_LABEL)); - break; - } - } - } - } - return buf.toString(); - } - - protected void buildViewParams() { - // label - labelTypeItems = labelTypeHelper.getLabelTypeItemList(); - - if (!labelTypeItems.isEmpty() && !indexForm.fields.containsKey(LABEL_FIELD)) { - final String defaultLabelValue = crawlerProperties.getProperty(Constants.DEFAULT_LABEL_VALUE_PROPERTY, StringUtil.EMPTY); - if (StringUtil.isNotBlank(defaultLabelValue)) { - final String[] values = defaultLabelValue.split("\n"); - if (values != null && values.length > 0) { - final List list = new ArrayList(values.length); - for (final String value : values) { - if (StringUtil.isNotBlank(value)) { - list.add(value); - } - } - if (!list.isEmpty()) { - indexForm.fields.put(LABEL_FIELD, list.toArray(new String[list.size()])); - } - } - } - } - - final Map labelMap = new LinkedHashMap(); - if (!labelTypeItems.isEmpty()) { - for (final Map map : labelTypeItems) { - labelMap.put(map.get(Constants.ITEM_VALUE), map.get(Constants.ITEM_LABEL)); - } - } - request.setAttribute(Constants.LABEL_VALUE_MAP, labelMap); - - if (viewHelper.isUseSession()) { - final HttpSession session = request.getSession(false); - if (session != null) { - final Object resultsPerPage = session.getAttribute(Constants.RESULTS_PER_PAGE); - if (resultsPerPage != null) { - indexForm.num = resultsPerPage.toString(); - } - } - } - - Locale locale = request.getLocale(); - if (locale == null) { - locale = Locale.ENGLISH; - } - langItems = systemHelper.getLanguageItems(locale); - - final HttpSession session = request.getSession(false); - if (session != null) { - final Object obj = session.getAttribute(SSCConstants.USER_INFO); - if (obj instanceof LoginInfo) { - final LoginInfo loginInfo = (LoginInfo) obj; - username = loginInfo.getUsername(); - } - } - - } - - protected void buildInitParams() { - buildInitParamMap(viewHelper.getInitFacetParamMap(), Constants.FACET_QUERY, Constants.FACET_FORM); - buildInitParamMap(viewHelper.getInitGeoParamMap(), Constants.GEO_QUERY, Constants.GEO_FORM); - } - - protected void buildInitParamMap(final Map paramMap, final String queryKey, final String formKey) { - if (!paramMap.isEmpty()) { - final StringBuilder queryBuf = new StringBuilder(100); - final StringBuilder formBuf = new StringBuilder(100); - for (final Map.Entry entry : paramMap.entrySet()) { - queryBuf.append('&'); - queryBuf.append(URLEncoderUtil.encode(entry.getValue())); - queryBuf.append('='); - queryBuf.append(URLEncoderUtil.encode(entry.getKey())); - formBuf.append(""); - } - request.setAttribute(queryKey, queryBuf.toString()); - request.setAttribute(formKey, formBuf.toString()); - } - } - - protected void normalizePageNum() { - try { - final int num = Integer.parseInt(indexForm.num); - if (num > getMaxPageSize()) { - // max page size - indexForm.num = String.valueOf(getMaxPageSize()); - } else if (num <= 0) { - indexForm.num = String.valueOf(getDefaultPageSize()); - } - } catch (final NumberFormatException e) { - indexForm.num = String.valueOf(getDefaultPageSize()); - } - } - - protected int getDefaultPageSize() { - return DEFAULT_PAGE_SIZE; - } - - protected int getMaxPageSize() { - final Object maxPageSize = crawlerProperties.get(Constants.SEARCH_RESULT_MAX_PAGE_SIZE); - if (maxPageSize == null) { - return MAX_PAGE_SIZE; - } - try { - return Integer.parseInt(maxPageSize.toString()); - } catch (final NumberFormatException e) { - return MAX_PAGE_SIZE; - } - } - - public boolean isOsddLink() { - return openSearchHelper.hasOpenSearchFile(); - } - - public String getHelpPage() { - return viewHelper.getPagePath("common/help"); - } - - protected boolean hasFieldInQuery(final Set fieldSet, final String query) { - final Matcher matcher = FIELD_EXTRACTION_PATTERN.matcher(query); - if (matcher.matches()) { - final String field = matcher.replaceFirst("$1"); - if (fieldSet.contains(field)) { - return true; - } - fieldSet.add(field); - } - return false; - } - - protected String getImageMimeType(final File imageFile) { - final String path = imageFile.getAbsolutePath(); - if (path.endsWith(".png")) { - return "image/png"; - } else if (path.endsWith(".gif")) { - return "image/gif"; - } else if (path.endsWith(".jpg") || path.endsWith(".jpeg")) { - return "image/jpeg"; - } else { - return "application/octet-stream"; - } - } - -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/LoginAction.java b/src/main/java/org/codelibs/fess/web/LoginAction.java deleted file mode 100644 index 6628e3dbc..000000000 --- a/src/main/java/org/codelibs/fess/web/LoginAction.java +++ /dev/null @@ -1,198 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web; - -import java.io.IOException; -import java.io.Serializable; -import java.util.Enumeration; -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; -import java.util.Set; - -import javax.annotation.Resource; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; -import javax.servlet.http.HttpSession; - -import org.apache.struts.Globals; -import org.codelibs.core.crypto.CachedCipher; -import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; -import org.codelibs.fess.entity.LoginInfo; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.sastruts.core.SSCConstants; -import org.codelibs.sastruts.core.util.ActivityUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.util.RequestUtil; -import org.seasar.struts.util.ResponseUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class LoginAction implements Serializable { - private static final Logger logger = LoggerFactory.getLogger(LoginAction.class); - - private static final long serialVersionUID = 1L; - - @ActionForm - @Resource - protected LoginForm loginForm; - - @Resource - protected SystemHelper systemHelper; - - @Execute(validator = false, input = "../index") - public String index() { - final HttpServletRequest request = RequestUtil.getRequest(); - final HttpSession session = request.getSession(); - // check login session - final Object obj = session.getAttribute(SSCConstants.USER_INFO); - if (obj instanceof LoginInfo) { - final LoginInfo loginInfo = (LoginInfo) obj; - if (loginInfo.isAdministrator()) { - redirect(getAdminRootPath()); - return null; - } else { - return "logout.jsp"; - } - } - - if ("logout".equals(loginForm.type)) { - if (logger.isInfoEnabled()) { - logger.info("Invalidated session. The username is " + request.getRemoteUser()); - } - session.invalidate(); - } - - String returnPath; - if (StringUtil.isNotBlank(loginForm.returnPath)) { - final CachedCipher cipher = ComponentUtil.getCipher(Constants.AUTH_CIPHER); - if (cipher == null) { - throw new FessSystemException("A cipher for authentication is null. Please check a filter setting."); - } - final String value = cipher.decryptoText(loginForm.returnPath); - final int idx = value.indexOf('|'); - if (idx >= 0) { - returnPath = value.substring(idx + 1); - RequestUtil.getRequest().getSession().setAttribute(Constants.RETURN_PATH, returnPath); - } else { - // invalid returnPath - RequestUtil.getRequest().getSession().removeAttribute(Constants.RETURN_PATH); - } - } else { - RequestUtil.getRequest().getSession().removeAttribute(Constants.RETURN_PATH); - } - - return "login?redirect=true"; - } - - @Execute(validator = false, input = "../index") - public String login() { - final HttpServletRequest request = RequestUtil.getRequest(); - final HttpSession oldSession = request.getSession(); - - final Map sessionObjMap = new HashMap(); - final Enumeration e = oldSession.getAttributeNames(); - while (e.hasMoreElements()) { - final String name = e.nextElement(); - sessionObjMap.put(name, oldSession.getAttribute(name)); - } - oldSession.invalidate(); - - sessionObjMap.remove(Globals.MESSAGE_KEY); - - final HttpSession session = request.getSession(); - for (final Map.Entry entry : sessionObjMap.entrySet()) { - session.setAttribute(entry.getKey(), entry.getValue()); - } - - // create user info - final LoginInfo loginInfo = new LoginInfo(); - loginInfo.setUsername(request.getRemoteUser()); - session.setAttribute(SSCConstants.USER_INFO, loginInfo); - - String returnPath; - final Set authenticatedRoleList = systemHelper.getAuthenticatedRoleSet(); - final Set roleSet = new HashSet<>(); - for (final String role : authenticatedRoleList) { - if (request.isUserInRole(role)) { - roleSet.add(role); - } - } - loginInfo.setRoleSet(roleSet); - - if (loginInfo.isAdministrator()) { - ActivityUtil.login(request.getRemoteUser(), request); - - returnPath = (String) session.getAttribute(Constants.RETURN_PATH); - if (returnPath != null) { - session.removeAttribute(Constants.RETURN_PATH); - } else { - // admin page - returnPath = getAdminRootPath(); - } - } else { - if (!loginInfo.getRoleSet().isEmpty()) { - ActivityUtil.login(request.getRemoteUser(), request); - } else { - if (logger.isWarnEnabled()) { - logger.warn("Login Failure: " + request.getRemoteUser() + " does not have authenticated roles."); - } - // logout - session.invalidate(); - } - returnPath = RequestUtil.getRequest().getContextPath(); - } - - redirect(returnPath); - - return null; - } - - private void redirect(final String returnPath) { - final HttpServletResponse response = ResponseUtil.getResponse(); - try { - response.sendRedirect(response.encodeURL(returnPath)); - } catch (final IOException e) { - throw new FessSystemException("Failed to redirect to " + returnPath, e); - } - } - - private String getAdminRootPath() { - String returnPath = RequestUtil.getRequest().getContextPath(); - if (StringUtil.isEmpty(returnPath) || "/".equals(returnPath)) { - returnPath = "/admin"; - } else { - returnPath = returnPath + "/admin"; - } - return returnPath; - } - - @Execute(validator = false, input = "../index") - public String logout() { - final HttpServletRequest request = RequestUtil.getRequest(); - ActivityUtil.logout(request.getRemoteUser(), request); - - final HttpSession session = request.getSession(); - session.invalidate(); - - return "login?redirect=true"; - } -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/BoostDocumentRuleAction.java b/src/main/java/org/codelibs/fess/web/admin/BoostDocumentRuleAction.java deleted file mode 100644 index 129629a9a..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/BoostDocumentRuleAction.java +++ /dev/null @@ -1,325 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.BoostDocumentRule; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.BoostDocumentRulePager; -import org.codelibs.fess.service.BoostDocumentRuleService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class BoostDocumentRuleAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(BoostDocumentRuleAction.class); - - // for list - - public List boostDocumentRuleItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected BoostDocumentRuleForm boostDocumentRuleForm; - - @Resource - protected BoostDocumentRuleService boostDocumentRuleService; - - @Resource - protected BoostDocumentRulePager boostDocumentRulePager; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("boostDocumentRule"); - } - - protected String displayList(final boolean redirect) { - // page navi - boostDocumentRuleItems = boostDocumentRuleService.getBoostDocumentRuleList(boostDocumentRulePager); - - // restore from pager - Beans.copy(boostDocumentRulePager, boostDocumentRuleForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(boostDocumentRuleForm.pageNumber)) { - try { - boostDocumentRulePager.setCurrentPageNumber(Integer.parseInt(boostDocumentRuleForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + boostDocumentRuleForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(boostDocumentRuleForm.searchParams, boostDocumentRulePager).excludes(CommonConstants.PAGER_CONVERSION_RULE).execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - boostDocumentRulePager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (boostDocumentRuleForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - boostDocumentRuleForm.crudMode }); - } - - loadBoostDocumentRule(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - boostDocumentRuleForm.initialize(); - boostDocumentRuleForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (boostDocumentRuleForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, - boostDocumentRuleForm.crudMode }); - } - - loadBoostDocumentRule(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - boostDocumentRuleForm.crudMode = CommonConstants.EDIT_MODE; - - loadBoostDocumentRule(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (boostDocumentRuleForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - boostDocumentRuleForm.crudMode }); - } - - loadBoostDocumentRule(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - boostDocumentRuleForm.crudMode = CommonConstants.DELETE_MODE; - - loadBoostDocumentRule(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final BoostDocumentRule boostDocumentRule = createBoostDocumentRule(); - boostDocumentRuleService.store(boostDocumentRule); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final BoostDocumentRule boostDocumentRule = createBoostDocumentRule(); - boostDocumentRuleService.store(boostDocumentRule); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", boostDocumentRuleForm.id); - - return keys; - } - - protected void loadBoostDocumentRule() { - - final BoostDocumentRule boostDocumentRule = boostDocumentRuleService.getBoostDocumentRule(createKeyMap()); - if (boostDocumentRule == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { boostDocumentRuleForm.id }); - } - - FessBeans.copy(boostDocumentRule, boostDocumentRuleForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - } - - protected BoostDocumentRule createBoostDocumentRule() { - BoostDocumentRule boostDocumentRule; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (boostDocumentRuleForm.crudMode == CommonConstants.EDIT_MODE) { - boostDocumentRule = boostDocumentRuleService.getBoostDocumentRule(createKeyMap()); - if (boostDocumentRule == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { boostDocumentRuleForm.id }); - } - } else { - boostDocumentRule = new BoostDocumentRule(); - boostDocumentRule.setCreatedBy(username); - boostDocumentRule.setCreatedTime(currentTime); - } - boostDocumentRule.setUpdatedBy(username); - boostDocumentRule.setUpdatedTime(currentTime); - FessBeans.copy(boostDocumentRuleForm, boostDocumentRule).excludesCommonColumns().execute(); - - return boostDocumentRule; - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (boostDocumentRuleForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - boostDocumentRuleForm.crudMode }); - } - - try { - final BoostDocumentRule boostDocumentRule = boostDocumentRuleService.getBoostDocumentRule(createKeyMap()); - if (boostDocumentRule == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { boostDocumentRuleForm.id }); - } - - boostDocumentRuleService.delete(boostDocumentRule); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/BoostDocumentRuleForm.java b/src/main/java/org/codelibs/fess/web/admin/BoostDocumentRuleForm.java deleted file mode 100644 index 8d6e74c90..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/BoostDocumentRuleForm.java +++ /dev/null @@ -1,92 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.HashMap; -import java.util.Map; - -import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; - -public class BoostDocumentRuleForm { - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType - public int crudMode; - - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) - public String id; - - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 4000) - public String urlExpr; - - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 4000) - public String boostExpr; - - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @IntegerType - @IntRange(min = 0, max = 2147483647) - public String sortOrder; - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) - public String createdBy; - - @Required(target = "confirmfromupdate,update,delete") - @LongType - public String createdTime; - - @Maxbytelength(maxbytelength = 255) - public String updatedBy; - - @LongType - public String updatedTime; - - @Required(target = "confirmfromupdate,update,delete") - @IntegerType - public String versionNo; - - public void initialize() { - - id = null; - urlExpr = null; - boostExpr = null; - sortOrder = null; - createdBy = "system"; - createdTime = Long.toString(ComponentUtil.getSystemHelper().getCurrentTimeAsLong()); - updatedBy = null; - updatedTime = null; - versionNo = null; - - sortOrder = "0"; - } - -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/CrawlAction.java b/src/main/java/org/codelibs/fess/web/admin/CrawlAction.java deleted file mode 100644 index e273d2f18..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/CrawlAction.java +++ /dev/null @@ -1,177 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.Serializable; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.core.lang.StringUtil; -import org.codelibs.core.misc.DynamicProperties; -import org.codelibs.fess.Constants; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.util.MessageResourcesUtil; -import org.seasar.struts.util.RequestUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class CrawlAction implements Serializable { - private static final Logger logger = LoggerFactory.getLogger(CrawlAction.class); - - private static final long serialVersionUID = 1L; - - @ActionForm - @Resource - protected CrawlForm crawlForm; - - @Resource - protected DynamicProperties crawlerProperties; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("crawl"); - } - - protected String showIndex(final boolean redirect) { - crawlForm.diffCrawling = crawlerProperties.getProperty(Constants.DIFF_CRAWLING_PROPERTY, Constants.TRUE); - crawlForm.useAclAsRole = crawlerProperties.getProperty(Constants.USE_ACL_AS_ROLE, Constants.FALSE); - crawlForm.dayForCleanup = crawlerProperties.getProperty(Constants.DAY_FOR_CLEANUP_PROPERTY, "1"); - crawlForm.crawlingThreadCount = crawlerProperties.getProperty(Constants.CRAWLING_THREAD_COUNT_PROPERTY, "5"); - crawlForm.searchLog = crawlerProperties.getProperty(Constants.SEARCH_LOG_PROPERTY, Constants.TRUE); - crawlForm.userInfo = crawlerProperties.getProperty(Constants.USER_INFO_PROPERTY, Constants.TRUE); - crawlForm.userFavorite = crawlerProperties.getProperty(Constants.USER_FAVORITE_PROPERTY, Constants.FALSE); - crawlForm.webApiXml = crawlerProperties.getProperty(Constants.WEB_API_XML_PROPERTY, Constants.TRUE); - crawlForm.webApiJson = crawlerProperties.getProperty(Constants.WEB_API_JSON_PROPERTY, Constants.TRUE); - crawlForm.defaultLabelValue = crawlerProperties.getProperty(Constants.DEFAULT_LABEL_VALUE_PROPERTY, StringUtil.EMPTY); - crawlForm.appendQueryParameter = crawlerProperties.getProperty(Constants.APPEND_QUERY_PARAMETER_PROPERTY, Constants.FALSE); - crawlForm.supportedSearch = - crawlerProperties.getProperty(Constants.SUPPORTED_SEARCH_FEATURE_PROPERTY, Constants.SUPPORTED_SEARCH_WEB); - crawlForm.ignoreFailureType = - crawlerProperties.getProperty(Constants.IGNORE_FAILURE_TYPE_PROPERTY, Constants.DEFAULT_IGNORE_FAILURE_TYPE); - crawlForm.failureCountThreshold = - crawlerProperties.getProperty(Constants.FAILURE_COUNT_THRESHOLD_PROPERTY, Constants.DEFAULT_FAILURE_COUNT); - crawlForm.hotSearchWord = crawlerProperties.getProperty(Constants.WEB_API_HOT_SEARCH_WORD_PROPERTY, Constants.TRUE); - crawlForm.csvFileEncoding = crawlerProperties.getProperty(Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8); - crawlForm.purgeSearchLogDay = crawlerProperties.getProperty(Constants.PURGE_SEARCH_LOG_DAY_PROPERTY, Constants.DEFAULT_PURGE_DAY); - crawlForm.purgeJobLogDay = crawlerProperties.getProperty(Constants.PURGE_JOB_LOG_DAY_PROPERTY, Constants.DEFAULT_PURGE_DAY); - crawlForm.purgeUserInfoDay = crawlerProperties.getProperty(Constants.PURGE_USER_INFO_DAY_PROPERTY, Constants.DEFAULT_PURGE_DAY); - crawlForm.purgeByBots = crawlerProperties.getProperty(Constants.PURGE_BY_BOTS_PROPERTY, Constants.DEFAULT_PURGE_BY_BOTS); - crawlForm.notificationTo = crawlerProperties.getProperty(Constants.NOTIFICATION_TO_PROPERTY, StringUtil.EMPTY); - crawlForm.suggestSearchLog = crawlerProperties.getProperty(Constants.SUGGEST_SEARCH_LOG_PROPERTY, Constants.TRUE); - crawlForm.purgeSuggestSearchLogDay = crawlerProperties.getProperty(Constants.PURGE_SUGGEST_SEARCH_LOG_DAY_PROPERTY, "30"); - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Token(save = true, validate = false) - @Execute(validator = false) - public String index() { - return showIndex(false); - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "index.jsp") - public String update() { - crawlerProperties.setProperty(Constants.DIFF_CRAWLING_PROPERTY, - crawlForm.diffCrawling != null && Constants.ON.equalsIgnoreCase(crawlForm.diffCrawling) ? Constants.TRUE : Constants.FALSE); - crawlerProperties.setProperty(Constants.USE_ACL_AS_ROLE, - crawlForm.useAclAsRole != null && Constants.ON.equalsIgnoreCase(crawlForm.useAclAsRole) ? Constants.TRUE : Constants.FALSE); - crawlerProperties.setProperty(Constants.DAY_FOR_CLEANUP_PROPERTY, crawlForm.dayForCleanup); - crawlerProperties.setProperty(Constants.CRAWLING_THREAD_COUNT_PROPERTY, crawlForm.crawlingThreadCount); - crawlerProperties.setProperty(Constants.SEARCH_LOG_PROPERTY, - crawlForm.searchLog != null && Constants.ON.equalsIgnoreCase(crawlForm.searchLog) ? Constants.TRUE : Constants.FALSE); - crawlerProperties.setProperty(Constants.USER_INFO_PROPERTY, - crawlForm.userInfo != null && Constants.ON.equalsIgnoreCase(crawlForm.userInfo) ? Constants.TRUE : Constants.FALSE); - crawlerProperties.setProperty(Constants.USER_FAVORITE_PROPERTY, - crawlForm.userFavorite != null && Constants.ON.equalsIgnoreCase(crawlForm.userFavorite) ? Constants.TRUE : Constants.FALSE); - crawlerProperties.setProperty(Constants.WEB_API_XML_PROPERTY, - crawlForm.webApiXml != null && Constants.ON.equalsIgnoreCase(crawlForm.webApiXml) ? Constants.TRUE : Constants.FALSE); - crawlerProperties.setProperty(Constants.WEB_API_JSON_PROPERTY, - crawlForm.webApiJson != null && Constants.ON.equalsIgnoreCase(crawlForm.webApiJson) ? Constants.TRUE : Constants.FALSE); - crawlerProperties.setProperty(Constants.DEFAULT_LABEL_VALUE_PROPERTY, crawlForm.defaultLabelValue); - crawlerProperties.setProperty(Constants.APPEND_QUERY_PARAMETER_PROPERTY, - crawlForm.appendQueryParameter != null && Constants.ON.equalsIgnoreCase(crawlForm.appendQueryParameter) ? Constants.TRUE - : Constants.FALSE); - crawlerProperties.setProperty(Constants.SUPPORTED_SEARCH_FEATURE_PROPERTY, crawlForm.supportedSearch); - crawlerProperties.setProperty(Constants.IGNORE_FAILURE_TYPE_PROPERTY, crawlForm.ignoreFailureType); - crawlerProperties.setProperty(Constants.FAILURE_COUNT_THRESHOLD_PROPERTY, crawlForm.failureCountThreshold); - crawlerProperties.setProperty(Constants.WEB_API_HOT_SEARCH_WORD_PROPERTY, - crawlForm.hotSearchWord != null && Constants.ON.equalsIgnoreCase(crawlForm.hotSearchWord) ? Constants.TRUE - : Constants.FALSE); - crawlerProperties.setProperty(Constants.CSV_FILE_ENCODING_PROPERTY, crawlForm.csvFileEncoding); - crawlerProperties.setProperty(Constants.PURGE_SEARCH_LOG_DAY_PROPERTY, crawlForm.purgeSearchLogDay); - crawlerProperties.setProperty(Constants.PURGE_JOB_LOG_DAY_PROPERTY, crawlForm.purgeJobLogDay); - crawlerProperties.setProperty(Constants.PURGE_USER_INFO_DAY_PROPERTY, crawlForm.purgeUserInfoDay); - crawlerProperties.setProperty(Constants.PURGE_BY_BOTS_PROPERTY, crawlForm.purgeByBots); - crawlerProperties.setProperty(Constants.NOTIFICATION_TO_PROPERTY, crawlForm.notificationTo); - crawlerProperties.setProperty(Constants.SUGGEST_SEARCH_LOG_PROPERTY, - crawlForm.suggestSearchLog != null && Constants.ON.equalsIgnoreCase(crawlForm.suggestSearchLog) ? Constants.TRUE - : Constants.FALSE); - crawlerProperties.setProperty(Constants.PURGE_SUGGEST_SEARCH_LOG_DAY_PROPERTY, crawlForm.purgeSuggestSearchLogDay); - try { - crawlerProperties.store(); - SAStrutsUtil.addSessionMessage("success.update_crawler_params"); - return showIndex(true); - } catch (final Exception e) { - logger.error("Failed to update crawler parameters.", e); - throw new SSCActionMessagesException(e, "errors.failed_to_update_crawler_params", e); - } - } - - public List getDayItems() { - final List items = new ArrayList(); - for (int i = 0; i < 32; i++) { - items.add(Integer.valueOf(i).toString()); - } - for (int i = 40; i < 370; i += 10) { - items.add(Integer.valueOf(i).toString()); - } - items.add(Integer.valueOf(365).toString()); - return items; - } - - public List> getSupportedSearchItems() { - final List> list = new ArrayList>(); - list.add(createItem(MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "labels.supported_search_web"), - Constants.SUPPORTED_SEARCH_WEB)); - list.add(createItem(MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "labels.supported_search_none"), - Constants.SUPPORTED_SEARCH_NONE)); - return list; - } - - private Map createItem(final String label, final String value) { - final Map map = new HashMap(); - map.put(Constants.ITEM_LABEL, label); - map.put(Constants.ITEM_VALUE, value); - return map; - - } -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/CrawlingSessionAction.java b/src/main/java/org/codelibs/fess/web/admin/CrawlingSessionAction.java deleted file mode 100644 index 19950bf1f..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/CrawlingSessionAction.java +++ /dev/null @@ -1,352 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.Collections; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.CrawlingSession; -import org.codelibs.fess.es.exentity.CrawlingSessionInfo; -import org.codelibs.fess.helper.JobHelper; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.CrawlingSessionPager; -import org.codelibs.fess.service.CrawlingSessionService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class CrawlingSessionAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(CrawlingSessionAction.class); - - //for list - public List crawlingSessionItems; - - // for edit/confirm/delete - @ActionForm - @Resource - protected CrawlingSessionForm crawlingSessionForm; - - @Resource - protected CrawlingSessionService crawlingSessionService; - - @Resource - protected CrawlingSessionPager crawlingSessionPager; - - @Resource - protected SystemHelper systemHelper; - - @Resource - protected JobHelper jobHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("crawlingSession"); - } - - protected String displayList(final boolean redirect) { - // page navi - crawlingSessionItems = crawlingSessionService.getCrawlingSessionList(crawlingSessionPager); - - // restore from pager - Beans.copy(crawlingSessionPager, crawlingSessionForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - public List getCrawlingSessionInfoItems() { - if (crawlingSessionForm.id != null) { - return crawlingSessionService.getCrawlingSessionInfoList(crawlingSessionForm.id); - } - return Collections.emptyList(); - } - - @Execute(validator = false, input = "error.jsp") - public String deleteall() { - crawlingSessionService.deleteOldSessions(jobHelper.getRunningSessionIdSet()); - SAStrutsUtil.addSessionMessage("success.crawling_session_delete_all"); - return displayList(true); - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(crawlingSessionForm.pageNumber)) { - try { - crawlingSessionPager.setCurrentPageNumber(Integer.parseInt(crawlingSessionForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + crawlingSessionForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(crawlingSessionForm.searchParams, crawlingSessionPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - crawlingSessionPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (crawlingSessionForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - crawlingSessionForm.crudMode }); - } - - loadCrawlingSession(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - crawlingSessionForm.initialize(); - crawlingSessionForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (crawlingSessionForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, - crawlingSessionForm.crudMode }); - } - - loadCrawlingSession(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - crawlingSessionForm.crudMode = CommonConstants.EDIT_MODE; - - loadCrawlingSession(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (crawlingSessionForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - crawlingSessionForm.crudMode }); - } - - loadCrawlingSession(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - crawlingSessionForm.crudMode = CommonConstants.DELETE_MODE; - - loadCrawlingSession(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final CrawlingSession crawlingSession = createCrawlingSession(); - crawlingSessionService.store(crawlingSession); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final CrawlingSession crawlingSession = createCrawlingSession(); - crawlingSessionService.store(crawlingSession); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (crawlingSessionForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - crawlingSessionForm.crudMode }); - } - - try { - final CrawlingSession crawlingSession = crawlingSessionService.getCrawlingSession(createKeyMap()); - if (crawlingSession == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { crawlingSessionForm.id }); - - } - - crawlingSessionService.delete(crawlingSession); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_delete_crud_table"); - } - } - - protected void loadCrawlingSession() { - - final CrawlingSession crawlingSession = crawlingSessionService.getCrawlingSession(createKeyMap()); - if (crawlingSession == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { crawlingSessionForm.id }); - - } - - Beans.copy(crawlingSession, crawlingSessionForm).excludes("searchParams", "mode") - - .execute(); - } - - protected CrawlingSession createCrawlingSession() { - CrawlingSession crawlingSession; - if (crawlingSessionForm.crudMode == CommonConstants.EDIT_MODE) { - crawlingSession = crawlingSessionService.getCrawlingSession(createKeyMap()); - if (crawlingSession == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { crawlingSessionForm.id }); - - } - } else { - crawlingSession = new CrawlingSession(); - } - Beans.copy(crawlingSessionForm, crawlingSession).excludes("searchParams", "mode") - - .execute(); - - return crawlingSession; - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", crawlingSessionForm.id); - - return keys; - } - -} diff --git a/src/main/java/org/codelibs/fess/web/admin/DataAction.java b/src/main/java/org/codelibs/fess/web/admin/DataAction.java deleted file mode 100644 index c960b71af..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/DataAction.java +++ /dev/null @@ -1,184 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.BufferedInputStream; -import java.io.BufferedReader; -import java.io.BufferedWriter; -import java.io.File; -import java.io.FileInputStream; -import java.io.FileOutputStream; -import java.io.InputStreamReader; -import java.io.OutputStreamWriter; -import java.io.Reader; -import java.io.Serializable; -import java.io.Writer; -import java.text.DateFormat; -import java.text.SimpleDateFormat; -import java.util.Date; - -import javax.annotation.Resource; -import javax.servlet.http.HttpServletResponse; - -import org.apache.commons.io.IOUtils; -import org.codelibs.core.CoreLibConstants; -import org.codelibs.core.misc.DynamicProperties; -import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.service.CrawlingSessionService; -import org.codelibs.robot.util.StreamUtil; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.seasar.struts.util.ResponseUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class DataAction implements Serializable { - - private static final long serialVersionUID = 1L; - - private static final Logger logger = LoggerFactory.getLogger(DataAction.class); - - @Resource - @ActionForm - protected DataForm dataForm; - - @Resource - protected CrawlingSessionService crawlingSessionService; - - @Resource - protected DynamicProperties crawlerProperties; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("data"); - } - - @Execute(validator = false) - public String index() { - // set a default value - dataForm.overwrite = "on"; - return "index.jsp"; - } - - @Execute(validator = false) - public String downloadCrawlingSession() { - final DateFormat df = new SimpleDateFormat(CoreLibConstants.DATE_FORMAT_DIGIT_ONLY); - final StringBuilder buf = new StringBuilder(); - buf.append("backup-cs-"); - buf.append(df.format(new Date())); - buf.append(".csv"); - - final HttpServletResponse response = ResponseUtil.getResponse(); - response.setContentType("application/octet-stream"); - response.setHeader("Content-Disposition", "attachment; filename=\"" + buf.toString() + "\""); - - Writer writer = null; - try { - writer = - new BufferedWriter(new OutputStreamWriter(response.getOutputStream(), crawlerProperties.getProperty( - Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8))); - crawlingSessionService.exportCsv(writer); - writer.flush(); - return null; - } catch (final Exception e) { - logger.error("Failed to export data.", e); - throw new SSCActionMessagesException(e, "errors.failed_to_export_data"); - } finally { - IOUtils.closeQuietly(writer); - } - } - - @Execute(validator = true, input = "index") - public String upload() { - final String fileName = dataForm.uploadedFile.getFileName(); - if (fileName.endsWith(".csv")) { - BufferedInputStream is = null; - File tempFile = null; - FileOutputStream fos = null; - final byte[] b = new byte[20]; - try { - tempFile = File.createTempFile("fess-import-", ".csv"); - is = new BufferedInputStream(dataForm.uploadedFile.getInputStream()); - is.mark(20); - if (is.read(b, 0, 20) <= 0) { - throw new FessSystemException("no import data."); - } - is.reset(); - fos = new FileOutputStream(tempFile); - StreamUtil.drain(is, fos); - } catch (final Exception e) { - if (tempFile != null && !tempFile.delete()) { - logger.warn("Could not delete " + tempFile.getAbsolutePath()); - } - logger.error("Failed to import data.", e); - throw new SSCActionMessagesException(e, "errors.failed_to_import_data"); - } finally { - IOUtils.closeQuietly(is); - IOUtils.closeQuietly(fos); - } - - final File oFile = tempFile; - try { - final String head = new String(b, Constants.UTF_8); - if (!head.startsWith("SessionId,")) { - logger.error("Unknown file: " + dataForm.uploadedFile); - throw new SSCActionMessagesException("errors.unknown_import_file"); - } - final String enc = crawlerProperties.getProperty(Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8); - new Thread(() -> { - Reader reader = null; - try { - reader = new BufferedReader(new InputStreamReader(new FileInputStream(oFile), enc)); - if (head.startsWith("SessionId,")) { - // Crawling Session - crawlingSessionService.importCsv(reader); - } - } catch (final Exception e) { - logger.error("Failed to import data.", e); - throw new FessSystemException("Failed to import data.", e); - } finally { - if (!oFile.delete()) { - logger.warn("Could not delete " + oFile.getAbsolutePath()); - } - IOUtils.closeQuietly(reader); - } - } ).start(); - } catch (final ActionMessagesException e) { - if (!oFile.delete()) { - logger.warn("Could not delete " + oFile.getAbsolutePath()); - } - throw e; - } catch (final Exception e) { - if (!oFile.delete()) { - logger.warn("Could not delete " + oFile.getAbsolutePath()); - } - logger.error("Failed to import data.", e); - throw new SSCActionMessagesException(e, "errors.failed_to_import_data"); - } - } - - SAStrutsUtil.addSessionMessage("success.importing_data"); - return "index?redirect=true"; - } -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/DataConfigAction.java b/src/main/java/org/codelibs/fess/web/admin/DataConfigAction.java deleted file mode 100644 index c7e5e17ea..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/DataConfigAction.java +++ /dev/null @@ -1,374 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.Constants; -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.ds.DataStoreFactory; -import org.codelibs.fess.es.exentity.DataConfig; -import org.codelibs.fess.es.exentity.LabelType; -import org.codelibs.fess.es.exentity.RoleType; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.DataConfigPager; -import org.codelibs.fess.service.DataConfigService; -import org.codelibs.fess.service.FailureUrlService; -import org.codelibs.fess.service.LabelTypeService; -import org.codelibs.fess.service.RoleTypeService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class DataConfigAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(DataConfigAction.class); - - // for list - - public List dataConfigItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected DataConfigForm dataConfigForm; - - @Resource - protected DataConfigService dataConfigService; - - @Resource - protected DataConfigPager dataConfigPager; - - @Resource - protected RoleTypeService roleTypeService; - - @Resource - protected LabelTypeService labelTypeService; - - @Resource - protected DataStoreFactory dataStoreFactory; - - @Resource - protected FailureUrlService failureUrlService; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("dataConfig"); - } - - protected String displayList(final boolean redirect) { - // page navi - dataConfigItems = dataConfigService.getDataConfigList(dataConfigPager); - - // restore from pager - Beans.copy(dataConfigPager, dataConfigForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(dataConfigForm.pageNumber)) { - try { - dataConfigPager.setCurrentPageNumber(Integer.parseInt(dataConfigForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + dataConfigForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(dataConfigForm.searchParams, dataConfigPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - dataConfigPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (dataConfigForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - dataConfigForm.crudMode }); - } - - loadDataConfig(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - dataConfigForm.initialize(); - dataConfigForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (dataConfigForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.EDIT_MODE, dataConfigForm.crudMode }); - } - - loadDataConfig(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - dataConfigForm.crudMode = CommonConstants.EDIT_MODE; - - loadDataConfig(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (dataConfigForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - dataConfigForm.crudMode }); - } - - loadDataConfig(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - dataConfigForm.crudMode = CommonConstants.DELETE_MODE; - - loadDataConfig(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final DataConfig dataConfig = createDataConfig(); - dataConfigService.store(dataConfig); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final DataConfig dataConfig = createDataConfig(); - dataConfigService.store(dataConfig); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", dataConfigForm.id); - - return keys; - } - - protected void loadDataConfig() { - - final DataConfig dataConfig = dataConfigService.getDataConfig(createKeyMap()); - if (dataConfig == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { dataConfigForm.id }); - } - - FessBeans.copy(dataConfig, dataConfigForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - - // normalize boost - if (dataConfigForm.boost != null && dataConfigForm.boost.indexOf('.') > 0) { - dataConfigForm.boost = dataConfigForm.boost.substring(0, dataConfigForm.boost.indexOf('.')); - } - } - - protected DataConfig createDataConfig() { - DataConfig dataConfig; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (dataConfigForm.crudMode == CommonConstants.EDIT_MODE) { - dataConfig = dataConfigService.getDataConfig(createKeyMap()); - if (dataConfig == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { dataConfigForm.id }); - } - } else { - dataConfig = new DataConfig(); - dataConfig.setCreatedBy(username); - dataConfig.setCreatedTime(currentTime); - } - dataConfig.setUpdatedBy(username); - dataConfig.setUpdatedTime(currentTime); - FessBeans.copy(dataConfigForm, dataConfig).excludesCommonColumns().execute(); - - return dataConfig; - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (dataConfigForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - dataConfigForm.crudMode }); - } - - try { - final DataConfig dataConfig = dataConfigService.getDataConfig(createKeyMap()); - if (dataConfig == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { dataConfigForm.id }); - } - - failureUrlService.deleteByConfigId(dataConfig.getConfigId()); - - dataConfigService.delete(dataConfig); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - public List getRoleTypeItems() { - return roleTypeService.getRoleTypeList(); - } - - public List getLabelTypeItems() { - return labelTypeService.getLabelTypeList(); - } - - public List> getHandlerNameItems() { - final List dataStoreNameList = dataStoreFactory.getDataStoreNameList(); - final List> itemList = new ArrayList>(); - for (final String name : dataStoreNameList) { - final Map map = new HashMap(); - map.put(Constants.ITEM_LABEL, name); - map.put(Constants.ITEM_VALUE, name); - itemList.add(map); - } - return itemList; - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/DesignAction.java b/src/main/java/org/codelibs/fess/web/admin/DesignAction.java deleted file mode 100644 index 6601eab48..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/DesignAction.java +++ /dev/null @@ -1,303 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.BufferedInputStream; -import java.io.File; -import java.io.FileInputStream; -import java.io.Serializable; -import java.io.UnsupportedEncodingException; -import java.util.ArrayList; -import java.util.List; -import java.util.Locale; - -import javax.annotation.Resource; - -import org.apache.commons.io.FileUtils; -import org.apache.commons.io.IOUtils; -import org.codelibs.core.lang.StringUtil; -import org.codelibs.core.misc.DynamicProperties; -import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.util.FileUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.util.ResponseUtil; -import org.seasar.struts.util.ServletContextUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class DesignAction implements Serializable { - private static final long serialVersionUID = 1L; - - private static final Logger logger = LoggerFactory.getLogger(DesignAction.class); - - @ActionForm - @Resource - protected DesignForm designForm; - - @Resource - protected DynamicProperties crawlerProperties; - - public boolean editable = true; - - @Resource - protected SystemHelper systemHelper; - - public List fileNameItems; - - public String getHelpLink() { - return systemHelper.getHelpLink("design"); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "index") - public String index() { - checkEditorStatus(); - loadFileNameItems(); - return "index.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false) - public String back() { - checkEditorStatus(); - loadFileNameItems(); - return "index.jsp"; - } - - private boolean checkFileType(final String fileName, final String[] exts) { - if (fileName == null) { - return false; - } - final String lFileName = fileName.toLowerCase(Locale.ENGLISH); - for (final String ext : exts) { - if (lFileName.endsWith("." + ext)) { - return true; - } - } - return false; - } - - @Execute(validator = true, input = "index") - public String upload() { - checkEditorStatus(); - final String uploadedFileName = designForm.designFile.getFileName(); - String fileName = designForm.designFileName; - if (StringUtil.isBlank(fileName)) { - fileName = uploadedFileName; - try { - int pos = fileName.indexOf('/'); - if (pos >= 0) { - fileName = fileName.substring(pos + 1); - } - pos = fileName.indexOf('\\'); - if (pos >= 0) { - fileName = fileName.substring(pos + 1); - } - } catch (final Exception e) { - throw new SSCActionMessagesException(e, "errors.design_file_name_is_invalid"); - } - } - if (StringUtil.isBlank(fileName)) { - throw new SSCActionMessagesException("errors.design_file_name_is_not_found"); - } - - String baseDir = null; - // normalize filename - if (checkFileType(fileName, systemHelper.getSupportedUploadedMediaExtentions()) - && checkFileType(uploadedFileName, systemHelper.getSupportedUploadedMediaExtentions())) { - baseDir = "/images/"; - } else if (checkFileType(fileName, systemHelper.getSupportedUploadedCssExtentions()) - && checkFileType(uploadedFileName, systemHelper.getSupportedUploadedCssExtentions())) { - baseDir = "/css/"; - } else if (checkFileType(fileName, systemHelper.getSupportedUploadedJSExtentions()) - && checkFileType(uploadedFileName, systemHelper.getSupportedUploadedJSExtentions())) { - baseDir = "/js/"; - } else { - throw new SSCActionMessagesException("errors.design_file_is_unsupported_type"); - } - - final File uploadFile = new File(ServletContextUtil.getServletContext().getRealPath(baseDir + fileName)); - final File parentFile = uploadFile.getParentFile(); - if (!parentFile.exists() && !parentFile.mkdirs()) { - logger.warn("Could not create " + parentFile.getAbsolutePath()); - } - - try { - FileUtil.write(uploadFile.getAbsolutePath(), designForm.designFile.getFileData()); - SAStrutsUtil.addSessionMessage("success.upload_design_file", fileName); - return "index?redirect=true"; - } catch (final Exception e) { - logger.error("Failed to write an image file.", e); - throw new SSCActionMessagesException(e, "errors.failed_to_write_design_image_file"); - } - - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "index") - public String edit() { - checkEditorStatus(); - final String jspType = "view"; - final File jspFile = getJspFile(jspType); - - try { - designForm.content = new String(FileUtil.getBytes(jspFile), Constants.UTF_8); - } catch (final UnsupportedEncodingException e) { - throw new FessSystemException("Invalid encoding", e); - } - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "index") - public String editAsUseDefault() { - checkEditorStatus(); - final String jspType = "orig/view"; - final File jspFile = getJspFile(jspType); - - try { - designForm.content = new String(FileUtil.getBytes(jspFile), Constants.UTF_8); - } catch (final UnsupportedEncodingException e) { - throw new FessSystemException("Invalid encoding", e); - } - - return "edit.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = false, input = "index") - public String update() { - checkEditorStatus(); - final String jspType = "view"; - final File jspFile = getJspFile(jspType); - - if (designForm.content == null) { - designForm.content = StringUtil.EMPTY; - } - - try { - FileUtil.write(jspFile.getAbsolutePath(), designForm.content.getBytes(Constants.UTF_8)); - SAStrutsUtil.addSessionMessage("success.update_design_jsp_file", systemHelper.getDesignJspFileName(designForm.fileName)); - return "index?redirect=true"; - } catch (final Exception e) { - logger.error("Failed to update " + designForm.fileName, e); - throw new SSCActionMessagesException(e, "errors.failed_to_update_jsp_file"); - } - } - - @Execute(validator = false, input = "index") - public String download() { - checkEditorStatus(); - - final File file = getTargetFile(); - if (file == null) { - throw new SSCActionMessagesException("errors.target_file_does_not_exist", designForm.fileName); - } - - BufferedInputStream bis = null; - try { - bis = new BufferedInputStream(new FileInputStream(file)); - ResponseUtil.download(file.getName(), bis); - } catch (final Exception e) { - logger.error("Failed to download " + file.getAbsolutePath(), e); - throw new SSCActionMessagesException(e, "errors.failed_to_download_file", designForm.fileName); - } finally { - IOUtils.closeQuietly(bis); - } - return null; - } - - @Token(save = false, validate = true) - @Execute(validator = false, input = "index") - public String delete() { - checkEditorStatus(); - - final File file = getTargetFile(); - if (file == null) { - throw new SSCActionMessagesException("errors.target_file_does_not_exist", designForm.fileName); - } - - if (file.delete()) { - SAStrutsUtil.addSessionMessage("success.delete_file", designForm.fileName); - return "index?redirect=true"; - } else { - logger.error("Failed to delete " + file.getAbsolutePath()); - throw new SSCActionMessagesException("errors.failed_to_delete_file", designForm.fileName); - } - } - - private File getJspFile(final String jspType) { - final String jspFileName = systemHelper.getDesignJspFileName(designForm.fileName); - if (jspFileName == null) { - throw new SSCActionMessagesException("errors.invalid_design_jsp_file_name"); - } - final File jspFile = new File(ServletContextUtil.getServletContext().getRealPath("/WEB-INF/" + jspType + "/" + jspFileName)); - if (jspFile == null || !jspFile.exists()) { - throw new SSCActionMessagesException("errors.design_jsp_file_does_not_exist"); - } - return jspFile; - } - - private void checkEditorStatus() { - if (Constants.FALSE.equals(crawlerProperties.getProperty(Constants.WEB_DESIGN_EDITOR_PROPERTY, Constants.TRUE))) { - editable = false; - throw new SSCActionMessagesException("errors.design_editor_disabled"); - } - } - - private void loadFileNameItems() { - final File baseDir = new File(ServletContextUtil.getServletContext().getRealPath("/")); - fileNameItems = new ArrayList(); - final List fileList = getAccessibleFileList(baseDir); - final int length = baseDir.getAbsolutePath().length(); - for (final File file : fileList) { - fileNameItems.add(file.getAbsolutePath().substring(length)); - } - } - - private List getAccessibleFileList(final File baseDir) { - final List fileList = new ArrayList(); - fileList.addAll(FileUtils.listFiles(new File(baseDir, "images"), systemHelper.getSupportedUploadedMediaExtentions(), true)); - fileList.addAll(FileUtils.listFiles(new File(baseDir, "css"), systemHelper.getSupportedUploadedCssExtentions(), true)); - fileList.addAll(FileUtils.listFiles(new File(baseDir, "js"), systemHelper.getSupportedUploadedJSExtentions(), true)); - return fileList; - } - - private File getTargetFile() { - final File baseDir = new File(ServletContextUtil.getServletContext().getRealPath("/")); - final File targetFile = new File(ServletContextUtil.getServletContext().getRealPath(designForm.fileName)); - final List fileList = getAccessibleFileList(baseDir); - boolean exist = false; - for (final File file : fileList) { - if (targetFile.equals(file)) { - exist = true; - break; - } - } - if (exist) { - return targetFile; - } - return null; - } -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/DictAction.java b/src/main/java/org/codelibs/fess/web/admin/DictAction.java deleted file mode 100644 index 3f2925f15..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/DictAction.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.Serializable; - -import javax.annotation.Resource; - -import org.codelibs.fess.dict.DictionaryFile; -import org.codelibs.fess.dict.DictionaryItem; -import org.codelibs.fess.dict.DictionaryManager; -import org.codelibs.fess.helper.SystemHelper; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; - -public class DictAction implements Serializable { - private static final long serialVersionUID = 1L; - - @Resource - @ActionForm - protected DictForm dictForm; - - @Resource - protected DictionaryManager dictionaryManager; - - @Resource - protected SystemHelper systemHelper; - - public DictionaryFile[] dictFiles; - - public String getHelpLink() { - return systemHelper.getHelpLink("dict"); - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - dictFiles = dictionaryManager.getDictionaryFiles(); - return "index.jsp"; - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/DocumentAction.java b/src/main/java/org/codelibs/fess/web/admin/DocumentAction.java deleted file mode 100644 index fae5c0b6c..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/DocumentAction.java +++ /dev/null @@ -1,249 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.Serializable; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.Map; -import java.util.Set; - -import javax.annotation.Resource; - -import org.codelibs.fess.client.FessEsClient; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.helper.FieldHelper; -import org.codelibs.fess.helper.JobHelper; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.helper.WebManagementHelper; -import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.elasticsearch.index.query.QueryBuilder; -import org.elasticsearch.index.query.QueryBuilders; -import org.elasticsearch.search.aggregations.AggregationBuilders; -import org.elasticsearch.search.aggregations.bucket.terms.Terms; -import org.elasticsearch.search.aggregations.bucket.terms.Terms.Bucket; -import org.elasticsearch.search.aggregations.bucket.terms.Terms.Order; -import org.elasticsearch.search.aggregations.bucket.terms.TermsBuilder; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.taglib.S2Functions; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class DocumentAction implements Serializable { - private static final Logger logger = LoggerFactory.getLogger(DocumentAction.class); - - private static final long serialVersionUID = 1L; - - @ActionForm - @Resource - protected DocumentForm documentForm; - - @Resource - protected FessEsClient fessEsClient; - - @Resource - protected WebManagementHelper webManagementHelper; - - @Resource - protected SystemHelper systemHelper; - - @Resource - protected FieldHelper fieldHelper; - - @Resource - protected JobHelper jobHelper; - - public Map suggestDocumentNums; - - public String getHelpLink() { - return systemHelper.getHelpLink("document"); - } - - protected String showIndex(final boolean redirect) { - // TODO - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Token(save = true, validate = false) - @Execute(validator = false) - public String index() { - return showIndex(false); - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "index") - public String commit() { - // TODO change to flush - if (jobHelper.isCrawlProcessRunning()) { - throw new SSCActionMessagesException("errors.failed_to_start_solr_process_because_of_running"); - } - - fessEsClient.flush(ComponentUtil.getFieldHelper().docIndex); - SAStrutsUtil.addSessionMessage("success.commit_solr_index"); - return showIndex(true); - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "index") - public String optimize() { - // TODO change to optimize - if (jobHelper.isCrawlProcessRunning()) { - throw new SSCActionMessagesException("errors.failed_to_start_solr_process_because_of_running"); - } - fessEsClient.optimize(ComponentUtil.getFieldHelper().docIndex); - SAStrutsUtil.addSessionMessage("success.optimize_solr_index"); - return showIndex(true); - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "index") - public String delete() { - QueryBuilder deleteQuery; - if ("*".equals(documentForm.sessionId)) { - deleteQuery = QueryBuilders.matchAllQuery(); - } else { - deleteQuery = QueryBuilders.termQuery(fieldHelper.segmentField, documentForm.sessionId); - } - return deleteByQuery(deleteQuery); - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "index") - public String confirmByUrl() { - final String confirmQuery = fieldHelper.urlField + ":\"" + documentForm.deleteUrl + "\""; - return "/admin/searchList/search?query=" + S2Functions.u(confirmQuery) + "&redirect=true"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "index") - public String deleteByUrl() { - return deleteByQuery(QueryBuilders.termQuery(fieldHelper.urlField, documentForm.deleteUrl)); - } - - private String deleteByQuery(final QueryBuilder queryBuilder) { - if (jobHelper.isCrawlProcessRunning()) { - throw new SSCActionMessagesException("errors.failed_to_start_solr_process_because_of_running"); - } - - fessEsClient.deleteByQuery(fieldHelper.docIndex, fieldHelper.docType, queryBuilder); - SAStrutsUtil.addSessionMessage("success.delete_solr_index"); - return showIndex(true); - } - - protected SessionIdList> getSessionIdList(final String groupName) { - // TODO remove groupName? - final FieldHelper fieldHelper = ComponentUtil.getFieldHelper(); - return fessEsClient.search( - fieldHelper.docIndex, - fieldHelper.docType, - queryRequestBuilder -> { - queryRequestBuilder.setQuery(QueryBuilders.matchAllQuery()); - final TermsBuilder termsBuilder = - AggregationBuilders.terms(fieldHelper.segmentField).field(fieldHelper.segmentField).size(100) - .order(Order.count(false)); - queryRequestBuilder.addAggregation(termsBuilder); - return true; - }, (queryRequestBuilder, execTime, searchResponse) -> { - final SessionIdList> sessionIdList = new SessionIdList>(); - searchResponse.ifPresent(response -> { - final Terms terms = response.getAggregations().get(fieldHelper.segmentField); - for (final Bucket bucket : terms.getBuckets()) { - final Map map = new HashMap(3); - map.put("label", bucket.getKey() + " (" + bucket.getDocCount() + ")"); - map.put("value", bucket.getKey()); - map.put("count", Long.toString(bucket.getDocCount())); - sessionIdList.add(map); - sessionIdList.addTotalCount(bucket.getDocCount()); - } - }); - return sessionIdList; - }); - - } - - public boolean isSolrProcessRunning() { - return jobHelper.isCrawlProcessRunning(); - } - - public Set getRunningSessionIdSet() { - return jobHelper.getRunningSessionIdSet(); - } - - protected Map getSuggestDocumentNum() { - final Map map = new HashMap(); - // map.put(SUGGEST_TYPE_CONTENT, - // suggestService.getContentDocumentNum()); - // map.put(SUGGEST_TYPE_SEARCH_LOG, - // suggestService.getSearchLogDocumentNum()); - // map.put(SUGGEST_TYPE_ALL, suggestService.getDocumentNum()); - return map; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "index") - public String deleteSuggest() { - // TODO - /* - * final SuggestSolrServer suggestSolrServer = - * suggestService.getSuggestSolrServer(); final String query; if - * (SUGGEST_TYPE_CONTENT.equals(documentForm.deleteSuggestType)) { query - * = "*:* NOT " + SuggestConstants.SuggestFieldNames.SEGMENT + ":" + - * SuggestConstants.SEGMENT_ELEVATE + " NOT " + - * SuggestConstants.SuggestFieldNames.SEGMENT + ":" + - * SuggestConstants.SEGMENT_QUERY; } else if - * (SUGGEST_TYPE_SEARCH_LOG.equals(documentForm.deleteSuggestType)) { - * query = SuggestConstants.SuggestFieldNames.SEGMENT + ":" + - * SuggestConstants.SEGMENT_QUERY; } else { query = ""; } - * - * if (StringUtil.isNotBlank(query)) { final Thread thread = new - * Thread(new Runnable() { - * - * @Override public void run() { if (!jobHelper.isCrawlProcessRunning()) - * { final long execTime = System.currentTimeMillis(); try { - * suggestSolrServer.deleteByQuery(query); suggestSolrServer.commit(); - * if (logger.isInfoEnabled()) { - * logger.info("[EXEC TIME] suggest index cleanup time: " + - * (System.currentTimeMillis() - execTime) + "ms"); } } catch (final - * Exception e) { logger.error("Failed to delete suggest index (query=" - * + query + ").", e); } } else { if (logger.isInfoEnabled()) { - * logger.info("could not start index cleanup process" + - * " because of running solr process."); } } } }); thread.start(); - * SAStrutsUtil.addSessionMessage("success.delete_solr_index"); } - */ - return showIndex(true); - } - - private static class SessionIdList extends ArrayList { - - private static final long serialVersionUID = 1L; - - private long totalCount = 0; - - public void addTotalCount(final long count) { - totalCount += count; - } - - } -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/DocumentForm.java b/src/main/java/org/codelibs/fess/web/admin/DocumentForm.java deleted file mode 100644 index 892309751..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/DocumentForm.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.Serializable; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -import org.seasar.struts.annotation.Required; - -public class DocumentForm implements Serializable { - - private static final long serialVersionUID = 1L; - - public String currentServerForUpdate; - - public String currentServerForSelect; - - public String currentServerStatusForUpdate; - - public String currentServerStatusForSelect; - - public List> serverStatusList = new ArrayList>(); - - @Required(target = "commit,optimize,delete") - public String groupName; - - @Required(target = "delete") - public String sessionId; - - @Required(target = "deleteByUrl,confirmByUrl") - public String deleteUrl; - - @Required(target = "startSolrInstance,stopSolrInstance,reloadSolrInstance") - public String solrInstanceName; - - @Required(target = "deleteSuggest") - public String deleteSuggestType; -} diff --git a/src/main/java/org/codelibs/fess/web/admin/FailureUrlAction.java b/src/main/java/org/codelibs/fess/web/admin/FailureUrlAction.java deleted file mode 100644 index 7c1227d31..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/FailureUrlAction.java +++ /dev/null @@ -1,340 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.FailureUrl; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.FailureUrlPager; -import org.codelibs.fess.service.FailureUrlService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class FailureUrlAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(FailureUrlAction.class); - - // for list - - public List failureUrlItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected FailureUrlForm failureUrlForm; - - @Resource - protected FailureUrlService failureUrlService; - - @Resource - protected FailureUrlPager failureUrlPager; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("failureUrl"); - } - - protected String displayList(final boolean redirect) { - // page navi - failureUrlItems = failureUrlService.getFailureUrlList(failureUrlPager); - - // restore from pager - Beans.copy(failureUrlPager, failureUrlForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(failureUrlForm.pageNumber)) { - try { - failureUrlPager.setCurrentPageNumber(Integer.parseInt(failureUrlForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + failureUrlForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(failureUrlForm.searchParams, failureUrlPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - failureUrlPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (failureUrlForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - failureUrlForm.crudMode }); - } - - loadFailureUrl(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - failureUrlForm.initialize(); - failureUrlForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (failureUrlForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.EDIT_MODE, failureUrlForm.crudMode }); - } - - loadFailureUrl(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - failureUrlForm.crudMode = CommonConstants.EDIT_MODE; - - loadFailureUrl(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (failureUrlForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - failureUrlForm.crudMode }); - } - - loadFailureUrl(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - failureUrlForm.crudMode = CommonConstants.DELETE_MODE; - - loadFailureUrl(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final FailureUrl failureUrl = createFailureUrl(); - failureUrlService.store(failureUrl); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final FailureUrl failureUrl = createFailureUrl(); - failureUrlService.store(failureUrl); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (failureUrlForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - failureUrlForm.crudMode }); - } - - try { - final FailureUrl failureUrl = failureUrlService.getFailureUrl(createKeyMap()); - if (failureUrl == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { failureUrlForm.id }); - - } - - failureUrlService.delete(failureUrl); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_delete_crud_table"); - } - } - - protected void loadFailureUrl() { - - final FailureUrl failureUrl = failureUrlService.getFailureUrl(createKeyMap()); - if (failureUrl == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { failureUrlForm.id }); - - } - - Beans.copy(failureUrl, failureUrlForm).excludes("searchParams", "mode") - - .execute(); - } - - protected FailureUrl createFailureUrl() { - FailureUrl failureUrl; - if (failureUrlForm.crudMode == CommonConstants.EDIT_MODE) { - failureUrl = failureUrlService.getFailureUrl(createKeyMap()); - if (failureUrl == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { failureUrlForm.id }); - - } - } else { - failureUrl = new FailureUrl(); - } - Beans.copy(failureUrlForm, failureUrl).excludes("searchParams", "mode") - - .execute(); - - return failureUrl; - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", failureUrlForm.id); - - return keys; - } - - @Execute(validator = false, input = "error.jsp") - public String deleteall() { - failureUrlService.deleteAll(failureUrlPager); - SAStrutsUtil.addSessionMessage("success.failure_url_delete_all"); - return displayList(true); - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/FileAuthenticationAction.java b/src/main/java/org/codelibs/fess/web/admin/FileAuthenticationAction.java deleted file mode 100644 index 5a58d194a..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/FileAuthenticationAction.java +++ /dev/null @@ -1,369 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.Constants; -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.FileAuthentication; -import org.codelibs.fess.es.exentity.FileConfig; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.FileAuthenticationPager; -import org.codelibs.fess.service.FileAuthenticationService; -import org.codelibs.fess.service.FileConfigService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.seasar.struts.util.MessageResourcesUtil; -import org.seasar.struts.util.RequestUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class FileAuthenticationAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(FileAuthenticationAction.class); - - // for list - public List fileAuthenticationItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected FileAuthenticationForm fileAuthenticationForm; - - @Resource - protected FileConfigService fileConfigService; - - @Resource - protected SystemHelper systemHelper; - - @Resource - protected FileAuthenticationService fileAuthenticationService; - - @Resource - protected FileAuthenticationPager fileAuthenticationPager; - - public String getHelpLink() { - return systemHelper.getHelpLink("fileAuthentication"); - } - - protected String displayList(final boolean redirect) { - // page navi - fileAuthenticationItems = fileAuthenticationService.getFileAuthenticationList(fileAuthenticationPager); - - // restore from pager - Beans.copy(fileAuthenticationPager, fileAuthenticationForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(fileAuthenticationForm.pageNumber)) { - try { - fileAuthenticationPager.setCurrentPageNumber(Integer.parseInt(fileAuthenticationForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + fileAuthenticationForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(fileAuthenticationForm.searchParams, fileAuthenticationPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - fileAuthenticationPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (fileAuthenticationForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - fileAuthenticationForm.crudMode }); - } - - loadFileAuthentication(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - fileAuthenticationForm.initialize(); - fileAuthenticationForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (fileAuthenticationForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, - fileAuthenticationForm.crudMode }); - } - - loadFileAuthentication(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - fileAuthenticationForm.crudMode = CommonConstants.EDIT_MODE; - - loadFileAuthentication(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (fileAuthenticationForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - fileAuthenticationForm.crudMode }); - } - - loadFileAuthentication(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - fileAuthenticationForm.crudMode = CommonConstants.DELETE_MODE; - - loadFileAuthentication(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final FileAuthentication fileAuthentication = createFileAuthentication(); - fileAuthenticationService.store(fileAuthentication); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final FileAuthentication fileAuthentication = createFileAuthentication(); - fileAuthenticationService.store(fileAuthentication); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected void loadFileAuthentication() { - - final FileAuthentication fileAuthentication = fileAuthenticationService.getFileAuthentication(createKeyMap()); - if (fileAuthentication == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { fileAuthenticationForm.id }); - } - - FessBeans.copy(fileAuthentication, fileAuthenticationForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - if ("-1".equals(fileAuthenticationForm.port)) { - fileAuthenticationForm.port = StringUtil.EMPTY; - } - } - - protected FileAuthentication createFileAuthentication() { - FileAuthentication fileAuthentication; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (fileAuthenticationForm.crudMode == CommonConstants.EDIT_MODE) { - fileAuthentication = fileAuthenticationService.getFileAuthentication(createKeyMap()); - if (fileAuthentication == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { fileAuthenticationForm.id }); - } - } else { - fileAuthentication = new FileAuthentication(); - fileAuthentication.setCreatedBy(username); - fileAuthentication.setCreatedTime(currentTime); - } - fileAuthentication.setUpdatedBy(username); - fileAuthentication.setUpdatedTime(currentTime); - if (StringUtil.isBlank(fileAuthenticationForm.port)) { - fileAuthenticationForm.port = "-1"; - } - FessBeans.copy(fileAuthenticationForm, fileAuthentication).excludesCommonColumns().execute(); - - return fileAuthentication; - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (fileAuthenticationForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - fileAuthenticationForm.crudMode }); - } - - try { - final FileAuthentication fileAuthentication = fileAuthenticationService.getFileAuthentication(createKeyMap()); - if (fileAuthentication == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { fileAuthenticationForm.id }); - } - - fileAuthenticationService.delete(fileAuthentication); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", fileAuthenticationForm.id); - - return keys; - } - - public boolean isDisplayCreateLink() { - return !fileConfigService.getAllFileConfigList(false, false, false, null).isEmpty(); - } - - public List> getFileConfigItems() { - final List> items = new ArrayList>(); - final List fileConfigList = fileConfigService.getAllFileConfigList(false, false, false, null); - for (final FileConfig fileConfig : fileConfigList) { - items.add(createItem(fileConfig.getName(), fileConfig.getId().toString())); - } - return items; - } - - public List> getProtocolSchemeItems() { - final List> items = new ArrayList>(); - items.add(createItem( - MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "labels.file_authentication_scheme_samba"), - Constants.SAMBA)); - return items; - } - - protected Map createItem(final String label, final String value) { - final Map map = new HashMap(2); - map.put("label", label); - map.put("value", value); - return map; - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/FileConfigAction.java b/src/main/java/org/codelibs/fess/web/admin/FileConfigAction.java deleted file mode 100644 index 98e888417..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/FileConfigAction.java +++ /dev/null @@ -1,357 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.FileConfig; -import org.codelibs.fess.es.exentity.LabelType; -import org.codelibs.fess.es.exentity.RoleType; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.FileConfigPager; -import org.codelibs.fess.service.FailureUrlService; -import org.codelibs.fess.service.FileConfigService; -import org.codelibs.fess.service.LabelTypeService; -import org.codelibs.fess.service.RoleTypeService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class FileConfigAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(FileConfigAction.class); - - // for list - - public List fileConfigItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected FileConfigForm fileConfigForm; - - @Resource - protected FileConfigService fileConfigService; - - @Resource - protected FileConfigPager fileConfigPager; - - @Resource - protected RoleTypeService roleTypeService; - - @Resource - protected LabelTypeService labelTypeService; - - @Resource - protected FailureUrlService failureUrlService; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("fileConfig"); - } - - protected String displayList(final boolean redirect) { - // page navi - fileConfigItems = fileConfigService.getFileConfigList(fileConfigPager); - - // restore from pager - Beans.copy(fileConfigPager, fileConfigForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(fileConfigForm.pageNumber)) { - try { - fileConfigPager.setCurrentPageNumber(Integer.parseInt(fileConfigForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + fileConfigForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(fileConfigForm.searchParams, fileConfigPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - fileConfigPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (fileConfigForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - fileConfigForm.crudMode }); - } - - loadFileConfig(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - fileConfigForm.initialize(); - fileConfigForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (fileConfigForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.EDIT_MODE, fileConfigForm.crudMode }); - } - - loadFileConfig(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - fileConfigForm.crudMode = CommonConstants.EDIT_MODE; - - loadFileConfig(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (fileConfigForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - fileConfigForm.crudMode }); - } - - loadFileConfig(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - fileConfigForm.crudMode = CommonConstants.DELETE_MODE; - - loadFileConfig(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final FileConfig fileConfig = createFileConfig(); - fileConfigService.store(fileConfig); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final FileConfig fileConfig = createFileConfig(); - fileConfigService.store(fileConfig); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", fileConfigForm.id); - - return keys; - } - - protected void loadFileConfig() { - - final FileConfig fileConfig = fileConfigService.getFileConfig(createKeyMap()); - if (fileConfig == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { fileConfigForm.id }); - } - - FessBeans.copy(fileConfig, fileConfigForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - - // normalize boost - if (fileConfigForm.boost != null && fileConfigForm.boost.indexOf('.') > 0) { - fileConfigForm.boost = fileConfigForm.boost.substring(0, fileConfigForm.boost.indexOf('.')); - } - } - - protected FileConfig createFileConfig() { - FileConfig fileConfig; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (fileConfigForm.crudMode == CommonConstants.EDIT_MODE) { - fileConfig = fileConfigService.getFileConfig(createKeyMap()); - if (fileConfig == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { fileConfigForm.id }); - } - } else { - fileConfig = new FileConfig(); - fileConfig.setCreatedBy(username); - fileConfig.setCreatedTime(currentTime); - } - fileConfig.setUpdatedBy(username); - fileConfig.setUpdatedTime(currentTime); - FessBeans.copy(fileConfigForm, fileConfig).excludesCommonColumns().execute(); - - return fileConfig; - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (fileConfigForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - fileConfigForm.crudMode }); - } - - try { - final FileConfig fileConfig = fileConfigService.getFileConfig(createKeyMap()); - if (fileConfig == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { fileConfigForm.id }); - } - - failureUrlService.deleteByConfigId(fileConfig.getConfigId()); - - fileConfigService.delete(fileConfig); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - public List getRoleTypeItems() { - return roleTypeService.getRoleTypeList(); - } - - public List getLabelTypeItems() { - return labelTypeService.getLabelTypeList(); - } - -} diff --git a/src/main/java/org/codelibs/fess/web/admin/IndexAction.java b/src/main/java/org/codelibs/fess/web/admin/IndexAction.java deleted file mode 100644 index cabfa962f..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/IndexAction.java +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import javax.annotation.Resource; -import javax.servlet.http.HttpServletRequest; - -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.sastruts.core.util.ActivityUtil; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.util.RequestUtil; - -public class IndexAction { - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("wizard"); - } - - @Execute(validator = false) - public String index() { - return "/admin/wizard/index?redirect=true"; - } - - @Execute(validator = false) - public String logout() { - final HttpServletRequest request = RequestUtil.getRequest(); - ActivityUtil.logout(request.getRemoteUser(), request); - - request.getSession().invalidate(); - return "/admin/wizard/index?redirect=true"; - } -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/JobLogAction.java b/src/main/java/org/codelibs/fess/web/admin/JobLogAction.java deleted file mode 100644 index 66c17969f..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/JobLogAction.java +++ /dev/null @@ -1,342 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.Constants; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.JobLog; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.JobLogPager; -import org.codelibs.fess.service.JobLogService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class JobLogAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(JobLogAction.class); - - // for list - - public List jobLogItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected JobLogForm jobLogForm; - - @Resource - protected JobLogService jobLogService; - - @Resource - protected JobLogPager jobLogPager; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("jobLog"); - } - - protected String displayList(final boolean redirect) { - // page navi - jobLogItems = jobLogService.getJobLogList(jobLogPager); - - // restore from pager - Beans.copy(jobLogPager, jobLogForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(jobLogForm.pageNumber)) { - try { - jobLogPager.setCurrentPageNumber(Integer.parseInt(jobLogForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + jobLogForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(jobLogForm.searchParams, jobLogPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - jobLogPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (jobLogForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.CONFIRM_MODE, jobLogForm.crudMode }); - } - - loadJobLog(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - jobLogForm.initialize(); - jobLogForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (jobLogForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, jobLogForm.crudMode }); - } - - loadJobLog(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - jobLogForm.crudMode = CommonConstants.EDIT_MODE; - - loadJobLog(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (jobLogForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, jobLogForm.crudMode }); - } - - loadJobLog(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - jobLogForm.crudMode = CommonConstants.DELETE_MODE; - - loadJobLog(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final JobLog jobLog = createJobLog(); - jobLogService.store(jobLog); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final JobLog jobLog = createJobLog(); - jobLogService.store(jobLog); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (jobLogForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, jobLogForm.crudMode }); - } - - try { - final JobLog jobLog = jobLogService.getJobLog(createKeyMap()); - if (jobLog == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { jobLogForm.id }); - - } - - jobLogService.delete(jobLog); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_delete_crud_table"); - } - } - - protected void loadJobLog() { - - final JobLog jobLog = jobLogService.getJobLog(createKeyMap()); - if (jobLog == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { jobLogForm.id }); - - } - - Beans.copy(jobLog, jobLogForm).excludes("searchParams", "mode") - - .execute(); - } - - protected JobLog createJobLog() { - JobLog jobLog; - if (jobLogForm.crudMode == CommonConstants.EDIT_MODE) { - jobLog = jobLogService.getJobLog(createKeyMap()); - if (jobLog == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { jobLogForm.id }); - - } - } else { - jobLog = new JobLog(); - } - Beans.copy(jobLogForm, jobLog).excludes("searchParams", "mode") - - .execute(); - - return jobLog; - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", jobLogForm.id); - - return keys; - } - - @Execute(validator = false, input = "error.jsp") - public String deleteall() { - final List jobStatusList = new ArrayList(); - jobStatusList.add(Constants.OK); - jobStatusList.add(Constants.FAIL); - jobLogService.deleteByJobStatus(jobStatusList); - SAStrutsUtil.addSessionMessage("success.joblog_delete_all"); - return displayList(true); - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/KeyMatchAction.java b/src/main/java/org/codelibs/fess/web/admin/KeyMatchAction.java deleted file mode 100644 index 0cf23a1cd..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/KeyMatchAction.java +++ /dev/null @@ -1,333 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.KeyMatch; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.KeyMatchPager; -import org.codelibs.fess.service.KeyMatchService; -import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class KeyMatchAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(KeyMatchAction.class); - - // for list - - public List keyMatchItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected KeyMatchForm keyMatchForm; - - @Resource - protected KeyMatchService keyMatchService; - - @Resource - protected KeyMatchPager keyMatchPager; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("keyMatch"); - } - - protected String displayList(final boolean redirect) { - // page navi - keyMatchItems = keyMatchService.getKeyMatchList(keyMatchPager); - - // restore from pager - Beans.copy(keyMatchPager, keyMatchForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(keyMatchForm.pageNumber)) { - try { - keyMatchPager.setCurrentPageNumber(Integer.parseInt(keyMatchForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + keyMatchForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(keyMatchForm.searchParams, keyMatchPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - keyMatchPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (keyMatchForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - keyMatchForm.crudMode }); - } - - loadKeyMatch(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - keyMatchForm.initialize(); - keyMatchForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (keyMatchForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, keyMatchForm.crudMode }); - } - - loadKeyMatch(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - keyMatchForm.crudMode = CommonConstants.EDIT_MODE; - - loadKeyMatch(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (keyMatchForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.DELETE_MODE, keyMatchForm.crudMode }); - } - - loadKeyMatch(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - keyMatchForm.crudMode = CommonConstants.DELETE_MODE; - - loadKeyMatch(); - - return "confirm.jsp"; - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", keyMatchForm.id); - - return keys; - } - - protected void loadKeyMatch() { - - final KeyMatch keyMatch = keyMatchService.getKeyMatch(createKeyMap()); - if (keyMatch == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { keyMatchForm.id }); - } - - FessBeans.copy(keyMatch, keyMatchForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - } - - protected KeyMatch createKeyMatch() { - KeyMatch keyMatch; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (keyMatchForm.crudMode == CommonConstants.EDIT_MODE) { - keyMatch = keyMatchService.getKeyMatch(createKeyMap()); - if (keyMatch == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { keyMatchForm.id }); - } - } else { - keyMatch = new KeyMatch(); - keyMatch.setCreatedBy(username); - keyMatch.setCreatedTime(currentTime); - } - keyMatch.setUpdatedBy(username); - keyMatch.setUpdatedTime(currentTime); - FessBeans.copy(keyMatchForm, keyMatch).excludesCommonColumns().execute(); - - return keyMatch; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - ComponentUtil.getKeyMatchHelper().update(); - try { - final KeyMatch keyMatch = createKeyMatch(); - keyMatchService.store(keyMatch); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final KeyMatch keyMatch = createKeyMatch(); - keyMatchService.store(keyMatch); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - final String result = displayList(true); - ComponentUtil.getKeyMatchHelper().update(); - return result; - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (keyMatchForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - keyMatchForm.crudMode }); - } - - try { - final KeyMatch keyMatch = keyMatchService.getKeyMatch(createKeyMap()); - if (keyMatch == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { keyMatchForm.id }); - } - - keyMatchService.delete(keyMatch); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - ComponentUtil.getKeyMatchHelper().update(); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - -} diff --git a/src/main/java/org/codelibs/fess/web/admin/LabelTypeAction.java b/src/main/java/org/codelibs/fess/web/admin/LabelTypeAction.java deleted file mode 100644 index 3b12eb774..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/LabelTypeAction.java +++ /dev/null @@ -1,336 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.LabelType; -import org.codelibs.fess.es.exentity.RoleType; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.LabelTypePager; -import org.codelibs.fess.service.LabelTypeService; -import org.codelibs.fess.service.RoleTypeService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class LabelTypeAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(LabelTypeAction.class); - - // for list - - public List labelTypeItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected LabelTypeForm labelTypeForm; - - @Resource - protected LabelTypeService labelTypeService; - - @Resource - protected LabelTypePager labelTypePager; - - @Resource - protected RoleTypeService roleTypeService; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("labelType"); - } - - protected String displayList(final boolean redirect) { - // page navi - labelTypeItems = labelTypeService.getLabelTypeList(labelTypePager); - - // restore from pager - Beans.copy(labelTypePager, labelTypeForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(labelTypeForm.pageNumber)) { - try { - labelTypePager.setCurrentPageNumber(Integer.parseInt(labelTypeForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + labelTypeForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(labelTypeForm.searchParams, labelTypePager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - labelTypePager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (labelTypeForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - labelTypeForm.crudMode }); - } - - loadLabelType(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - labelTypeForm.initialize(); - labelTypeForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (labelTypeForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.EDIT_MODE, labelTypeForm.crudMode }); - } - - loadLabelType(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - labelTypeForm.crudMode = CommonConstants.EDIT_MODE; - - loadLabelType(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (labelTypeForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - labelTypeForm.crudMode }); - } - - loadLabelType(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - labelTypeForm.crudMode = CommonConstants.DELETE_MODE; - - loadLabelType(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final LabelType labelType = createLabelType(); - labelTypeService.store(labelType); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final LabelType labelType = createLabelType(); - labelTypeService.store(labelType); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", labelTypeForm.id); - - return keys; - } - - protected void loadLabelType() { - - final LabelType labelType = labelTypeService.getLabelType(createKeyMap()); - if (labelType == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { labelTypeForm.id }); - } - - FessBeans.copy(labelType, labelTypeForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - } - - protected LabelType createLabelType() { - LabelType labelType; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (labelTypeForm.crudMode == CommonConstants.EDIT_MODE) { - labelType = labelTypeService.getLabelType(createKeyMap()); - if (labelType == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { labelTypeForm.id }); - } - } else { - labelType = new LabelType(); - labelType.setCreatedBy(username); - labelType.setCreatedTime(currentTime); - } - labelType.setUpdatedBy(username); - labelType.setUpdatedTime(currentTime); - FessBeans.copy(labelTypeForm, labelType).excludesCommonColumns().execute(); - - return labelType; - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (labelTypeForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - labelTypeForm.crudMode }); - } - - try { - final LabelType labelType = labelTypeService.getLabelType(createKeyMap()); - if (labelType == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { labelTypeForm.id }); - } - - labelTypeService.delete(labelType); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - public List getRoleTypeItems() { - return roleTypeService.getRoleTypeList(); - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/LabelTypeForm.java b/src/main/java/org/codelibs/fess/web/admin/LabelTypeForm.java deleted file mode 100644 index 22fb2b941..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/LabelTypeForm.java +++ /dev/null @@ -1,105 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; - -import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Mask; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Msg; -import org.seasar.struts.annotation.Required; - -public class LabelTypeForm implements Serializable { - - private static final long serialVersionUID = 1L; - - public String[] roleTypeIds; - - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType - public int crudMode; - - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) - public String id; - - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 100) - public String name; - - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 20) - @Mask(mask = "^[a-zA-Z0-9_-]+$", msg = @Msg(key = "errors.alphaDigitOnly")) - public String value; - - @Maxbytelength(maxbytelength = 4000) - public String includedPaths; - - @Maxbytelength(maxbytelength = 4000) - public String excludedPaths; - - @Required(target = "confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) - public String sortOrder; - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) - public String createdBy; - - @Required(target = "confirmfromupdate,update,delete") - @LongType - public String createdTime; - - @Maxbytelength(maxbytelength = 255) - public String updatedBy; - - @LongType - public String updatedTime; - - @Required(target = "confirmfromupdate,update,delete") - @IntegerType - public String versionNo; - - public void initialize() { - id = null; - name = null; - value = null; - includedPaths = null; - excludedPaths = null; - sortOrder = null; - createdBy = "system"; - createdTime = Long.toString(ComponentUtil.getSystemHelper().getCurrentTimeAsLong()); - updatedBy = null; - updatedTime = null; - versionNo = null; - sortOrder = "0"; - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/LogAction.java b/src/main/java/org/codelibs/fess/web/admin/LogAction.java deleted file mode 100644 index 719527796..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/LogAction.java +++ /dev/null @@ -1,144 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.File; -import java.io.FileInputStream; -import java.io.FileNotFoundException; -import java.io.FilenameFilter; -import java.io.Serializable; -import java.io.UnsupportedEncodingException; -import java.nio.charset.Charset; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Date; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.apache.commons.codec.binary.Base64; -import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.Constants; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.util.ComponentUtil; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.util.ResponseUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class LogAction implements Serializable { - - private static final long serialVersionUID = 1L; - - private static final Logger logger = LoggerFactory.getLogger(LogAction.class); - - @ActionForm - @Resource - protected LogForm logForm; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("log"); - } - - @Execute(validator = false) - public String index() { - return "index.jsp"; - } - - @Execute(validator = true, input = "index", urlPattern = "download/{logFileName}") - public String download() { - final String logFilePath = ComponentUtil.getSystemHelper().getLogFilePath(); - if (StringUtil.isNotBlank(logFilePath)) { - final File file = new File(logFilePath); - final File parentDir = file.getParentFile(); - String fileName; - try { - fileName = new String(Base64.decodeBase64(logForm.logFileName.getBytes(Constants.UTF_8)), Constants.UTF_8); - } catch (final UnsupportedEncodingException e1) { - fileName = - new String(Base64.decodeBase64(logForm.logFileName.getBytes(Charset.defaultCharset())), Charset.defaultCharset()); - } - final File logFile = new File(parentDir, fileName); - if (logFile.isFile()) { - try { - ResponseUtil.download(fileName, new FileInputStream(logFile)); - return null; - } catch (final FileNotFoundException e) { - logger.warn("Could not find " + logFile.getAbsolutePath(), e); - } - } - } - throw new SSCActionMessagesException("errors.could_not_find_log_file", new Object[] { logForm.logFileName }); - } - - public List> getLogFileItems() { - final List> logFileItems = new ArrayList>(); - final String logFilePath = ComponentUtil.getSystemHelper().getLogFilePath(); - if (StringUtil.isNotBlank(logFilePath)) { - try { - final File file = new File(logFilePath); - final File parentDir = file.getParentFile(); - if (!parentDir.exists()) { - logger.warn("Log directory does not exist: " + parentDir.getAbsolutePath()); - return logFileItems; - } - final File[] files = parentDir.listFiles((FilenameFilter) (dir, name) -> { - if (name.indexOf(".out") > 0) { - return true; - } - return false; - }); - if (files == null) { - return logFileItems; - } - Arrays.sort(files, (o1, o2) -> { - if (o1.lastModified() < o2.lastModified()) { - return 1; - } else { - return -1; - } - }); - for (final File logFile : files) { - logFileItems.add(createLogFileItem(logFile)); - } - } catch (final Exception e) { - logger.warn("Could not find log files.", e); - } - } - return logFileItems; - } - - protected Map createLogFileItem(final File file) { - final Map map = new HashMap(); - map.put("name", file.getName()); - try { - map.put("logFileName", new String(Base64.encodeBase64(file.getName().getBytes(Constants.UTF_8)), "UTF-8")); - } catch (final UnsupportedEncodingException e) { - map.put("logFileName", - new String(Base64.encodeBase64(file.getName().getBytes(Charset.defaultCharset())), Charset.defaultCharset())); - } - map.put("lastModified", new Date(file.lastModified())); - return map; - } -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/OverlappingHostAction.java b/src/main/java/org/codelibs/fess/web/admin/OverlappingHostAction.java deleted file mode 100644 index b1e3f0a82..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/OverlappingHostAction.java +++ /dev/null @@ -1,328 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.OverlappingHost; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.OverlappingHostPager; -import org.codelibs.fess.service.OverlappingHostService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class OverlappingHostAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(OverlappingHostAction.class); - - // for list - - public List overlappingHostItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected OverlappingHostForm overlappingHostForm; - - @Resource - protected OverlappingHostService overlappingHostService; - - @Resource - protected OverlappingHostPager overlappingHostPager; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("overlappingHost"); - } - - protected String displayList(final boolean redirect) { - // page navi - overlappingHostItems = overlappingHostService.getOverlappingHostList(overlappingHostPager); - - // restore from pager - Beans.copy(overlappingHostPager, overlappingHostForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(overlappingHostForm.pageNumber)) { - try { - overlappingHostPager.setCurrentPageNumber(Integer.parseInt(overlappingHostForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + overlappingHostForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(overlappingHostForm.searchParams, overlappingHostPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - overlappingHostPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (overlappingHostForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - overlappingHostForm.crudMode }); - } - - loadOverlappingHost(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - overlappingHostForm.initialize(); - overlappingHostForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (overlappingHostForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, - overlappingHostForm.crudMode }); - } - - loadOverlappingHost(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - overlappingHostForm.crudMode = CommonConstants.EDIT_MODE; - - loadOverlappingHost(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (overlappingHostForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - overlappingHostForm.crudMode }); - } - - loadOverlappingHost(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - overlappingHostForm.crudMode = CommonConstants.DELETE_MODE; - - loadOverlappingHost(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final OverlappingHost overlappingHost = createOverlappingHost(); - overlappingHostService.store(overlappingHost); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final OverlappingHost overlappingHost = createOverlappingHost(); - overlappingHostService.store(overlappingHost); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", overlappingHostForm.id); - - return keys; - } - - protected void loadOverlappingHost() { - - final OverlappingHost overlappingHost = overlappingHostService.getOverlappingHost(createKeyMap()); - if (overlappingHost == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { overlappingHostForm.id }); - } - - FessBeans.copy(overlappingHost, overlappingHostForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - } - - protected OverlappingHost createOverlappingHost() { - OverlappingHost overlappingHost; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (overlappingHostForm.crudMode == CommonConstants.EDIT_MODE) { - overlappingHost = overlappingHostService.getOverlappingHost(createKeyMap()); - if (overlappingHost == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { overlappingHostForm.id }); - } - } else { - overlappingHost = new OverlappingHost(); - overlappingHost.setCreatedBy(username); - overlappingHost.setCreatedTime(currentTime); - } - overlappingHost.setUpdatedBy(username); - overlappingHost.setUpdatedTime(currentTime); - FessBeans.copy(overlappingHostForm, overlappingHost).excludesCommonColumns().execute(); - - return overlappingHost; - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (overlappingHostForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - overlappingHostForm.crudMode }); - } - - try { - final OverlappingHost overlappingHost = overlappingHostService.getOverlappingHost(createKeyMap()); - if (overlappingHost == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { overlappingHostForm.id }); - } - - overlappingHostService.delete(overlappingHost); - - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/PathMappingAction.java b/src/main/java/org/codelibs/fess/web/admin/PathMappingAction.java deleted file mode 100644 index 97cf13290..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/PathMappingAction.java +++ /dev/null @@ -1,336 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.PathMapping; -import org.codelibs.fess.helper.PathMappingHelper; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.PathMappingPager; -import org.codelibs.fess.service.PathMappingService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class PathMappingAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(PathMappingAction.class); - - // for list - - public List pathMappingItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected PathMappingForm pathMappingForm; - - @Resource - protected PathMappingService pathMappingService; - - @Resource - protected PathMappingPager pathMappingPager; - - @Resource - protected PathMappingHelper pathMappingHelper; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("pathMapping"); - } - - protected String displayList(final boolean redirect) { - if (redirect) { - pathMappingHelper.init(); - } - - // page navi - pathMappingItems = pathMappingService.getPathMappingList(pathMappingPager); - - // restore from pager - Beans.copy(pathMappingPager, pathMappingForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(pathMappingForm.pageNumber)) { - try { - pathMappingPager.setCurrentPageNumber(Integer.parseInt(pathMappingForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + pathMappingForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(pathMappingForm.searchParams, pathMappingPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - pathMappingPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (pathMappingForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - pathMappingForm.crudMode }); - } - - loadPathMapping(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - pathMappingForm.initialize(); - pathMappingForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (pathMappingForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, - pathMappingForm.crudMode }); - } - - loadPathMapping(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - pathMappingForm.crudMode = CommonConstants.EDIT_MODE; - - loadPathMapping(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (pathMappingForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - pathMappingForm.crudMode }); - } - - loadPathMapping(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - pathMappingForm.crudMode = CommonConstants.DELETE_MODE; - - loadPathMapping(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final PathMapping pathMapping = createPathMapping(); - pathMappingService.store(pathMapping); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final PathMapping pathMapping = createPathMapping(); - pathMappingService.store(pathMapping); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", pathMappingForm.id); - - return keys; - } - - protected void loadPathMapping() { - - final PathMapping pathMapping = pathMappingService.getPathMapping(createKeyMap()); - if (pathMapping == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { pathMappingForm.id }); - } - - FessBeans.copy(pathMapping, pathMappingForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - } - - protected PathMapping createPathMapping() { - PathMapping pathMapping; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (pathMappingForm.crudMode == CommonConstants.EDIT_MODE) { - pathMapping = pathMappingService.getPathMapping(createKeyMap()); - if (pathMapping == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { pathMappingForm.id }); - } - } else { - pathMapping = new PathMapping(); - pathMapping.setCreatedBy(username); - pathMapping.setCreatedTime(currentTime); - } - pathMapping.setUpdatedBy(username); - pathMapping.setUpdatedTime(currentTime); - FessBeans.copy(pathMappingForm, pathMapping).excludesCommonColumns().execute(); - - return pathMapping; - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (pathMappingForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - pathMappingForm.crudMode }); - } - - try { - final PathMapping pathMapping = pathMappingService.getPathMapping(createKeyMap()); - if (pathMapping == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { pathMappingForm.id }); - } - - pathMappingService.delete(pathMapping); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - -} diff --git a/src/main/java/org/codelibs/fess/web/admin/RequestHeaderAction.java b/src/main/java/org/codelibs/fess/web/admin/RequestHeaderAction.java deleted file mode 100644 index cc5ed3df7..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/RequestHeaderAction.java +++ /dev/null @@ -1,364 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.RequestHeader; -import org.codelibs.fess.es.exentity.WebConfig; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.RequestHeaderPager; -import org.codelibs.fess.service.RequestHeaderService; -import org.codelibs.fess.service.WebConfigService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.seasar.struts.util.MessageResourcesUtil; -import org.seasar.struts.util.RequestUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class RequestHeaderAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(RequestHeaderAction.class); - - // for list - - public List requestHeaderItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected RequestHeaderForm requestHeaderForm; - - @Resource - protected RequestHeaderService requestHeaderService; - - @Resource - protected RequestHeaderPager requestHeaderPager; - - @Resource - protected WebConfigService webConfigService; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("requestHeader"); - } - - protected String displayList(final boolean redirect) { - // page navi - requestHeaderItems = requestHeaderService.getRequestHeaderList(requestHeaderPager); - - // restore from pager - Beans.copy(requestHeaderPager, requestHeaderForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(requestHeaderForm.pageNumber)) { - try { - requestHeaderPager.setCurrentPageNumber(Integer.parseInt(requestHeaderForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + requestHeaderForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(requestHeaderForm.searchParams, requestHeaderPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - requestHeaderPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (requestHeaderForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - requestHeaderForm.crudMode }); - } - - loadRequestHeader(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - requestHeaderForm.initialize(); - requestHeaderForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (requestHeaderForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, - requestHeaderForm.crudMode }); - } - - loadRequestHeader(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - requestHeaderForm.crudMode = CommonConstants.EDIT_MODE; - - loadRequestHeader(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (requestHeaderForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - requestHeaderForm.crudMode }); - } - - loadRequestHeader(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - requestHeaderForm.crudMode = CommonConstants.DELETE_MODE; - - loadRequestHeader(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final RequestHeader requestHeader = createRequestHeader(); - requestHeaderService.store(requestHeader); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final RequestHeader requestHeader = createRequestHeader(); - requestHeaderService.store(requestHeader); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", requestHeaderForm.id); - - return keys; - } - - protected void loadRequestHeader() { - - final RequestHeader requestHeader = requestHeaderService.getRequestHeader(createKeyMap()); - if (requestHeader == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { requestHeaderForm.id }); - } - - FessBeans.copy(requestHeader, requestHeaderForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - } - - protected RequestHeader createRequestHeader() { - RequestHeader requestHeader; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (requestHeaderForm.crudMode == CommonConstants.EDIT_MODE) { - requestHeader = requestHeaderService.getRequestHeader(createKeyMap()); - if (requestHeader == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { requestHeaderForm.id }); - } - } else { - requestHeader = new RequestHeader(); - requestHeader.setCreatedBy(username); - requestHeader.setCreatedTime(currentTime); - } - requestHeader.setUpdatedBy(username); - requestHeader.setUpdatedTime(currentTime); - FessBeans.copy(requestHeaderForm, requestHeader).excludesCommonColumns().execute(); - - return requestHeader; - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (requestHeaderForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - requestHeaderForm.crudMode }); - } - - try { - final RequestHeader requestHeader = requestHeaderService.getRequestHeader(createKeyMap()); - if (requestHeader == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { requestHeaderForm.id }); - } - - requestHeaderService.delete(requestHeader); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - public List> getWebConfigItems() { - final List> items = new ArrayList>(); - final List webConfigList = webConfigService.getAllWebConfigList(false, false, false, null); - for (final WebConfig webConfig : webConfigList) { - items.add(createItem(webConfig.getName(), webConfig.getId().toString())); - } - return items; - } - - public List> getProtocolSchemeItems() { - final List> items = new ArrayList>(); - items.add(createItem( - MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "labels.web_authentication_scheme_basic"), "BASIC")); - items.add(createItem( - MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "labels.web_authentication_scheme_digest"), "DIGEST")); - return items; - } - - protected Map createItem(final String label, final String value) { - final Map map = new HashMap(2); - map.put("label", label); - map.put("value", value); - return map; - } - - public boolean isDisplayCreateLink() { - return !webConfigService.getAllWebConfigList(false, false, false, null).isEmpty(); - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/RoleTypeAction.java b/src/main/java/org/codelibs/fess/web/admin/RoleTypeAction.java deleted file mode 100644 index d0f8e7cfa..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/RoleTypeAction.java +++ /dev/null @@ -1,328 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.RoleType; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.RoleTypePager; -import org.codelibs.fess.service.RoleTypeService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class RoleTypeAction extends FessAdminAction { - private static final Logger logger = LoggerFactory.getLogger(RoleTypeAction.class); - - @Resource - protected SystemHelper systemHelper; - - // for list - - public List roleTypeItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected RoleTypeForm roleTypeForm; - - @Resource - protected RoleTypeService roleTypeService; - - @Resource - protected RoleTypePager roleTypePager; - - public String getHelpLink() { - return systemHelper.getHelpLink("roleType"); - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - roleTypeForm.value = roleTypeForm.value.trim(); - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - roleTypeForm.value = roleTypeForm.value.trim(); - return "confirm.jsp"; - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(roleTypeForm.pageNumber)) { - try { - roleTypePager.setCurrentPageNumber(Integer.parseInt(roleTypeForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + roleTypeForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(roleTypeForm.searchParams, roleTypePager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - roleTypePager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (roleTypeForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - roleTypeForm.crudMode }); - } - - loadRoleType(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - roleTypeForm.initialize(); - roleTypeForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (roleTypeForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, roleTypeForm.crudMode }); - } - - loadRoleType(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - roleTypeForm.crudMode = CommonConstants.EDIT_MODE; - - loadRoleType(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (roleTypeForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.DELETE_MODE, roleTypeForm.crudMode }); - } - - loadRoleType(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - roleTypeForm.crudMode = CommonConstants.DELETE_MODE; - - loadRoleType(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final RoleType roleType = createRoleType(); - roleTypeService.store(roleType); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final RoleType roleType = createRoleType(); - roleTypeService.store(roleType); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected void loadRoleType() { - final RoleType roleType = roleTypeService.getRoleType(createKeyMap()); - if (roleType == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { roleTypeForm.id }); - } - - FessBeans.copy(roleType, roleTypeForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", roleTypeForm.id); - - return keys; - } - - protected RoleType createRoleType() { - RoleType roleType; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (roleTypeForm.crudMode == CommonConstants.EDIT_MODE) { - roleType = roleTypeService.getRoleType(createKeyMap()); - if (roleType == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { roleTypeForm.id }); - } - } else { - roleType = new RoleType(); - roleType.setCreatedBy(username); - roleType.setCreatedTime(currentTime); - } - roleType.setUpdatedBy(username); - roleType.setUpdatedTime(currentTime); - roleTypeForm.value = roleTypeForm.value.trim(); - FessBeans.copy(roleTypeForm, roleType).excludesCommonColumns().execute(); - - return roleType; - } - - @Token(save = false, validate = true) - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (roleTypeForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - roleTypeForm.crudMode }); - } - - try { - final RoleType roleType = roleTypeService.getRoleType(createKeyMap()); - if (roleType == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { roleTypeForm.id }); - } - - roleTypeService.delete(roleType); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - protected String displayList(final boolean redirect) { - // page navi - roleTypeItems = roleTypeService.getRoleTypeList(roleTypePager); - - // restore from pager - Beans.copy(roleTypePager, roleTypeForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/RoleTypeForm.java b/src/main/java/org/codelibs/fess/web/admin/RoleTypeForm.java deleted file mode 100644 index 2b41639f5..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/RoleTypeForm.java +++ /dev/null @@ -1,95 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.Serializable; -import java.util.HashMap; -import java.util.Map; - -import org.codelibs.fess.util.ComponentUtil; -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.IntegerType; -import org.seasar.struts.annotation.LongType; -import org.seasar.struts.annotation.Mask; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Msg; -import org.seasar.struts.annotation.Required; - -public class RoleTypeForm implements Serializable { - - private static final long serialVersionUID = 1L; - - @IntegerType - public String pageNumber; - - public Map searchParams = new HashMap(); - - @IntegerType - public int crudMode; - - public String getCurrentPageNumber() { - return pageNumber; - } - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 1000) - public String id; - - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 100) - public String name; - - @Required(target = "confirmfromcreate,create,confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 20) - @Mask(mask = "^[a-zA-Z0-9_-| ]+$", msg = @Msg(key = "errors.alphaDigitSpaceOnly")) - public String value; - - @Required(target = "confirmfromupdate,update,delete") - @IntRange(min = 0, max = 2147483647) - public String sortOrder; - - @Required(target = "confirmfromupdate,update,delete") - @Maxbytelength(maxbytelength = 255) - public String createdBy; - - @Required(target = "confirmfromupdate,update,delete") - @LongType - public String createdTime; - - @Maxbytelength(maxbytelength = 255) - public String updatedBy; - - @LongType - public String updatedTime; - - @Required(target = "confirmfromupdate,update,delete") - @IntegerType - public String versionNo; - - public void initialize() { - id = null; - name = null; - value = null; - sortOrder = null; - createdBy = "system"; - createdTime = Long.toString(ComponentUtil.getSystemHelper().getCurrentTimeAsLong()); - updatedBy = null; - updatedTime = null; - versionNo = null; - sortOrder = "0"; - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/ScheduledJobAction.java b/src/main/java/org/codelibs/fess/web/admin/ScheduledJobAction.java deleted file mode 100644 index 0ff265dd0..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/ScheduledJobAction.java +++ /dev/null @@ -1,380 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.Constants; -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.RoleType; -import org.codelibs.fess.es.exentity.ScheduledJob; -import org.codelibs.fess.helper.JobHelper; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.job.JobExecutor; -import org.codelibs.fess.pager.ScheduledJobPager; -import org.codelibs.fess.service.RoleTypeService; -import org.codelibs.fess.service.ScheduledJobService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class ScheduledJobAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(ScheduledJobAction.class); - - @Resource - protected RoleTypeService roleTypeService; - - @Resource - protected SystemHelper systemHelper; - - @Resource - protected JobHelper jobHelper; - - // for list - - public List scheduledJobItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected ScheduledJobForm scheduledJobForm; - - @Resource - protected ScheduledJobService scheduledJobService; - - @Resource - protected ScheduledJobPager scheduledJobPager; - - public boolean running = false; - - public String getHelpLink() { - return systemHelper.getHelpLink("scheduledJob"); - } - - protected void loadScheduledJob() { - - final ScheduledJob scheduledJob = getScheduledJob(); - - FessBeans.copy(scheduledJob, scheduledJobForm).commonColumnDateConverter().excludes("searchParams", "mode", "jobLogging").execute(); - scheduledJobForm.jobLogging = scheduledJob.isLoggingEnabled() ? Constants.ON : null; - scheduledJobForm.crawler = scheduledJob.isCrawlerJob() ? Constants.ON : null; - scheduledJobForm.available = scheduledJob.isEnabled() ? Constants.ON : null; - running = scheduledJob.isRunning(); - } - - protected ScheduledJob createScheduledJob() { - ScheduledJob scheduledJob; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (scheduledJobForm.crudMode == CommonConstants.EDIT_MODE) { - scheduledJob = scheduledJobService.getScheduledJob(createKeyMap()); - if (scheduledJob == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { scheduledJobForm.id }); - } - } else { - scheduledJob = new ScheduledJob(); - scheduledJob.setCreatedBy(username); - scheduledJob.setCreatedTime(currentTime); - } - scheduledJob.setUpdatedBy(username); - scheduledJob.setUpdatedTime(currentTime); - FessBeans.copy(scheduledJobForm, scheduledJob).excludesCommonColumns().execute(); - scheduledJob.setJobLogging(Constants.ON.equals(scheduledJobForm.jobLogging) ? Constants.T : Constants.F); - scheduledJob.setCrawler(Constants.ON.equals(scheduledJobForm.crawler) ? Constants.T : Constants.F); - scheduledJob.setAvailable(Constants.ON.equals(scheduledJobForm.available) ? Constants.T : Constants.F); - - return scheduledJob; - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (scheduledJobForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - scheduledJobForm.crudMode }); - } - - try { - final ScheduledJob scheduledJob = getScheduledJob(); - - scheduledJobService.delete(scheduledJob); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - @Execute(validator = false, input = "error.jsp") - public String start() { - final ScheduledJob scheduledJob = getScheduledJob(); - try { - scheduledJob.start(); - SAStrutsUtil.addSessionMessage("success.job_started", scheduledJob.getName()); - return displayList(true); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.failed_to_start_job", scheduledJob.getName()); - } - - } - - @Execute(validator = false, input = "error.jsp") - public String stop() { - final ScheduledJob scheduledJob = getScheduledJob(); - try { - final JobExecutor jobExecutoer = jobHelper.getJobExecutoer(scheduledJob.getId()); - jobExecutoer.shutdown(); - SAStrutsUtil.addSessionMessage("success.job_stopped", scheduledJob.getName()); - return displayList(true); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.failed_to_stop_job", scheduledJob.getName()); - } - } - - public List getRoleTypeItems() { - return roleTypeService.getRoleTypeList(); - } - - protected ScheduledJob getScheduledJob() { - final ScheduledJob scheduledJob = scheduledJobService.getScheduledJob(createKeyMap()); - if (scheduledJob == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { scheduledJobForm.id }); - } - return scheduledJob; - } - - protected String displayList(final boolean redirect) { - // page navi - scheduledJobItems = scheduledJobService.getScheduledJobList(scheduledJobPager); - - // restore from pager - Beans.copy(scheduledJobPager, scheduledJobForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(scheduledJobForm.pageNumber)) { - try { - scheduledJobPager.setCurrentPageNumber(Integer.parseInt(scheduledJobForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + scheduledJobForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(scheduledJobForm.searchParams, scheduledJobPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - scheduledJobPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (scheduledJobForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - scheduledJobForm.crudMode }); - } - - loadScheduledJob(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - scheduledJobForm.initialize(); - scheduledJobForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (scheduledJobForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, - scheduledJobForm.crudMode }); - } - - loadScheduledJob(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - scheduledJobForm.crudMode = CommonConstants.EDIT_MODE; - - loadScheduledJob(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (scheduledJobForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - scheduledJobForm.crudMode }); - } - - loadScheduledJob(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - scheduledJobForm.crudMode = CommonConstants.DELETE_MODE; - - loadScheduledJob(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final ScheduledJob scheduledJob = createScheduledJob(); - scheduledJobService.store(scheduledJob); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final ScheduledJob scheduledJob = createScheduledJob(); - scheduledJobService.store(scheduledJob); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", scheduledJobForm.id); - - return keys; - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/SearchListAction.java b/src/main/java/org/codelibs/fess/web/admin/SearchListAction.java deleted file mode 100644 index 1ee0ac257..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/SearchListAction.java +++ /dev/null @@ -1,279 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.Serializable; -import java.text.NumberFormat; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; -import javax.servlet.http.HttpServletRequest; - -import org.codelibs.core.lang.StringUtil; -import org.codelibs.core.misc.DynamicProperties; -import org.codelibs.fess.Constants; -import org.codelibs.fess.InvalidQueryException; -import org.codelibs.fess.ResultOffsetExceededException; -import org.codelibs.fess.client.FessEsClient; -import org.codelibs.fess.client.FessEsClient.SearchConditionBuilder; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.helper.FieldHelper; -import org.codelibs.fess.helper.JobHelper; -import org.codelibs.fess.helper.QueryHelper; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.util.QueryResponseList; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.elasticsearch.index.query.QueryBuilder; -import org.elasticsearch.index.query.QueryBuilders; -import org.seasar.framework.beans.util.Beans; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.taglib.S2Functions; -import org.seasar.struts.util.RequestUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class SearchListAction implements Serializable { - private static final Logger logger = LoggerFactory.getLogger(SearchListAction.class); - - private static final long serialVersionUID = 1L; - - @ActionForm - @Resource - protected SearchListForm searchListForm; - - @Resource - protected FessEsClient fessEsClient; - - @Resource - protected DynamicProperties crawlerProperties; - - @Resource - protected HttpServletRequest request; - - @Resource - protected SystemHelper systemHelper; - - @Resource - protected FieldHelper fieldHelper; - - @Resource - protected QueryHelper queryHelper; - - @Resource - protected JobHelper jobHelper; - - public List> documentItems; - - public String pageSize; - - public String currentPageNumber; - - public String allRecordCount; - - public String allPageCount; - - public boolean existNextPage; - - public boolean existPrevPage; - - public String currentStartRecordNumber; - - public String currentEndRecordNumber; - - public List pageNumberList; - - public String execTime; - - public String getHelpLink() { - return systemHelper.getHelpLink("searchList"); - } - - @Execute(validator = false) - public String index() { - return "index.jsp"; - } - - protected String doSearch() { - - if (StringUtil.isBlank(searchListForm.query)) { - // redirect to index page - searchListForm.query = null; - return "index?redirect=true"; - } - - doSearchInternal(); - - return "index.jsp"; - } - - private String doSearchInternal() { - final String query = searchListForm.query; - - // init pager - if (StringUtil.isBlank(searchListForm.start)) { - searchListForm.start = String.valueOf(Constants.DEFAULT_START_COUNT); - } else { - try { - Long.parseLong(searchListForm.start); - } catch (final NumberFormatException e) { - searchListForm.start = String.valueOf(Constants.DEFAULT_START_COUNT); - } - } - if (StringUtil.isBlank(searchListForm.num)) { - searchListForm.num = String.valueOf(Constants.DEFAULT_PAGE_SIZE); - } else { - try { - final int num = Integer.parseInt(searchListForm.num); - if (num > 100) { - // max page size - searchListForm.num = "100"; - } - } catch (final NumberFormatException e) { - searchListForm.num = String.valueOf(Constants.DEFAULT_PAGE_SIZE); - } - } - - final int offset = Integer.parseInt(searchListForm.start); - final int size = Integer.parseInt(searchListForm.num); - try { - documentItems = - fessEsClient.getDocumentList(fieldHelper.docIndex, fieldHelper.docType, searchRequestBuilder -> { - return SearchConditionBuilder.builder(searchRequestBuilder).administrativeAccess().offset(offset).size(size) - .responseFields(queryHelper.getResponseFields()).build(); - }); - } catch (final InvalidQueryException e) { - if (logger.isDebugEnabled()) { - logger.debug(e.getMessage(), e); - } - throw new SSCActionMessagesException(e, e.getMessageCode()); - } catch (final ResultOffsetExceededException e) { - if (logger.isDebugEnabled()) { - logger.debug(e.getMessage(), e); - } - throw new SSCActionMessagesException(e, "errors.result_size_exceeded"); - } - final QueryResponseList queryResponseList = (QueryResponseList) documentItems; - final NumberFormat nf = NumberFormat.getInstance(RequestUtil.getRequest().getLocale()); - nf.setMaximumIntegerDigits(2); - nf.setMaximumFractionDigits(2); - try { - execTime = nf.format((double) queryResponseList.getExecTime() / 1000); - } catch (final Exception e) {} - - Beans.copy(documentItems, this) - .includes("pageSize", "currentPageNumber", "allRecordCount", "allPageCount", "existNextPage", "existPrevPage", - "currentStartRecordNumber", "currentEndRecordNumber", "pageNumberList").execute(); - - return query; - } - - @Execute(validator = false) - public String search() { - return doSearch(); - } - - @Execute(validator = false) - public String prev() { - return doMove(-1); - } - - @Execute(validator = false) - public String next() { - return doMove(1); - } - - @Execute(validator = false) - public String move() { - return doMove(0); - } - - protected String doMove(final int move) { - int size = Constants.DEFAULT_PAGE_SIZE; - if (StringUtil.isBlank(searchListForm.num)) { - searchListForm.num = String.valueOf(Constants.DEFAULT_PAGE_SIZE); - } else { - try { - size = Integer.parseInt(searchListForm.num); - } catch (final NumberFormatException e) { - searchListForm.num = String.valueOf(Constants.DEFAULT_PAGE_SIZE); - } - } - - if (StringUtil.isBlank(searchListForm.pn)) { - searchListForm.start = String.valueOf(Constants.DEFAULT_START_COUNT); - } else { - Integer pageNumber = Integer.parseInt(searchListForm.pn); - if (pageNumber != null && pageNumber > 0) { - pageNumber = pageNumber + move; - if (pageNumber < 1) { - pageNumber = 1; - } - searchListForm.start = String.valueOf((pageNumber - 1) * size); - } else { - searchListForm.start = String.valueOf(Constants.DEFAULT_START_COUNT); - } - } - - return doSearch(); - } - - @Token(save = true, validate = false) - @Execute(validator = true, input = "index") - public String confirmDelete() { - return "confirmDelete.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "index") - public String delete() { - return deleteByQuery(searchListForm.docId); - } - - private String deleteByQuery(final String docId) { - if (jobHelper.isCrawlProcessRunning()) { - throw new SSCActionMessagesException("errors.failed_to_start_solr_process_because_of_running"); - } - final Thread thread = new Thread(() -> { - if (!jobHelper.isCrawlProcessRunning()) { - final long time = System.currentTimeMillis(); - try { - final QueryBuilder query = QueryBuilders.termQuery(fieldHelper.docIdField, docId); - fessEsClient.deleteByQuery(fieldHelper.docIndex, fieldHelper.docType, query); - if (logger.isInfoEnabled()) { - logger.info("[EXEC TIME] index cleanup time: " + (System.currentTimeMillis() - time) + "ms"); - } - } catch (final Exception e) { - logger.error("Failed to delete index (query=" + fieldHelper.docIdField + ":" + docId + ").", e); - } - } else { - if (logger.isInfoEnabled()) { - logger.info("could not start index cleanup process" + " because of running solr process."); - } - } - }); - thread.start(); - SAStrutsUtil.addSessionMessage("success.delete_solr_index"); - return "search?query=" + S2Functions.u(searchListForm.query) + "&redirect=true"; - } - - public boolean isSolrProcessRunning() { - return jobHelper.isCrawlProcessRunning(); - } -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/SuggestBadWordAction.java b/src/main/java/org/codelibs/fess/web/admin/SuggestBadWordAction.java deleted file mode 100644 index dc87b14ba..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/SuggestBadWordAction.java +++ /dev/null @@ -1,458 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.BufferedInputStream; -import java.io.BufferedReader; -import java.io.BufferedWriter; -import java.io.File; -import java.io.FileInputStream; -import java.io.FileOutputStream; -import java.io.InputStreamReader; -import java.io.OutputStreamWriter; -import java.io.Reader; -import java.io.Writer; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; -import javax.servlet.http.HttpServletResponse; - -import org.apache.commons.io.IOUtils; -import org.codelibs.core.misc.DynamicProperties; -import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.SuggestBadWord; -import org.codelibs.fess.helper.SuggestHelper; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.SuggestBadWordPager; -import org.codelibs.fess.service.SuggestBadWordService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.robot.util.StreamUtil; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.seasar.struts.util.ResponseUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class SuggestBadWordAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(SuggestBadWordAction.class); - - // for list - - public List suggestBadWordItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected SuggestBadWordForm suggestBadWordForm; - - @Resource - protected SuggestBadWordService suggestBadWordService; - - @Resource - protected SuggestBadWordPager suggestBadWordPager; - - @Resource - protected SystemHelper systemHelper; - - @Resource - protected SuggestHelper suggestHelper; - - @Resource - protected DynamicProperties crawlerProperties; - - protected String displayList(final boolean redirect) { - // page navi - suggestBadWordItems = suggestBadWordService.getSuggestBadWordList(suggestBadWordPager); - - // restore from pager - Beans.copy(suggestBadWordPager, suggestBadWordForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(suggestBadWordForm.pageNumber)) { - try { - suggestBadWordPager.setCurrentPageNumber(Integer.parseInt(suggestBadWordForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + suggestBadWordForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(suggestBadWordForm.searchParams, suggestBadWordPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - suggestBadWordPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (suggestBadWordForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - suggestBadWordForm.crudMode }); - } - - loadSuggestBadWord(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - suggestBadWordForm.initialize(); - suggestBadWordForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (suggestBadWordForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, - suggestBadWordForm.crudMode }); - } - - loadSuggestBadWord(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - suggestBadWordForm.crudMode = CommonConstants.EDIT_MODE; - - loadSuggestBadWord(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (suggestBadWordForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - suggestBadWordForm.crudMode }); - } - - loadSuggestBadWord(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - suggestBadWordForm.crudMode = CommonConstants.DELETE_MODE; - - loadSuggestBadWord(); - - return "confirm.jsp"; - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", suggestBadWordForm.id); - - return keys; - } - - public String getHelpLink() { - return systemHelper.getHelpLink("suggestBadWord"); - } - - protected void loadSuggestBadWord() { - - final SuggestBadWord suggestBadWord = suggestBadWordService.getSuggestBadWord(createKeyMap()); - if (suggestBadWord == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { suggestBadWordForm.id }); - } - - FessBeans.copy(suggestBadWord, suggestBadWordForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - } - - protected SuggestBadWord createSuggestBadWord() { - SuggestBadWord suggestBadWord; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (suggestBadWordForm.crudMode == CommonConstants.EDIT_MODE) { - suggestBadWord = suggestBadWordService.getSuggestBadWord(createKeyMap()); - if (suggestBadWord == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { suggestBadWordForm.id }); - } - } else { - suggestBadWord = new SuggestBadWord(); - suggestBadWord.setCreatedBy(username); - suggestBadWord.setCreatedTime(currentTime); - } - suggestBadWord.setUpdatedBy(username); - suggestBadWord.setUpdatedTime(currentTime); - FessBeans.copy(suggestBadWordForm, suggestBadWord).excludesCommonColumns().execute(); - - return suggestBadWord; - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (suggestBadWordForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - suggestBadWordForm.crudMode }); - } - - try { - final SuggestBadWord suggestBadWord = suggestBadWordService.getSuggestBadWord(createKeyMap()); - if (suggestBadWord == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { suggestBadWordForm.id }); - } - - suggestBadWordService.delete(suggestBadWord); - suggestHelper.deleteAllBadWord(); - suggestHelper.updateSolrBadwordFile(); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final SuggestBadWord suggestBadWord = createSuggestBadWord(); - suggestBadWordService.store(suggestBadWord); - suggestHelper.deleteAllBadWord(); - suggestHelper.updateSolrBadwordFile(); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final SuggestBadWord suggestBadWord = createSuggestBadWord(); - suggestBadWordService.store(suggestBadWord); - suggestHelper.deleteAllBadWord(); - suggestHelper.updateSolrBadwordFile(); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "downloadpage") - public String downloadpage() { - return "download.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = false, input = "downloadpage") - public String download() { - - final HttpServletResponse response = ResponseUtil.getResponse(); - response.setContentType("application/octet-stream"); - response.setHeader("Content-Disposition", "attachment; filename=\"" + "badword.csv" + "\""); - - try (Writer writer = - new BufferedWriter(new OutputStreamWriter(response.getOutputStream(), crawlerProperties.getProperty( - Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8)))) { - suggestBadWordService.exportCsv(writer); - } catch (final Exception e) { - logger.error("Failed to export data.", e); - throw new SSCActionMessagesException(e, "errors.failed_to_export_data"); - } - return null; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "uploadpage") - public String uploadpage() { - return "upload.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "uploadpage") - public String upload() { - BufferedInputStream is = null; - File tempFile = null; - FileOutputStream fos = null; - final byte[] b = new byte[20]; - try { - tempFile = File.createTempFile("suggestbadword-import-", ".csv"); - is = new BufferedInputStream(suggestBadWordForm.suggestBadWordFile.getInputStream()); - is.mark(20); - if (is.read(b, 0, 20) <= 0) { - throw new FessSystemException("no import data."); - } - is.reset(); - fos = new FileOutputStream(tempFile); - StreamUtil.drain(is, fos); - } catch (final Exception e) { - if (tempFile != null && !tempFile.delete()) { - logger.warn("Could not delete " + tempFile.getAbsolutePath()); - } - logger.error("Failed to import data.", e); - throw new SSCActionMessagesException(e, "errors.failed_to_import_data"); - } finally { - IOUtils.closeQuietly(is); - IOUtils.closeQuietly(fos); - } - - final File oFile = tempFile; - try { - final String head = new String(b, Constants.UTF_8); - if (!(head.startsWith("\"BadWord\"") || head.startsWith("BadWord"))) { - logger.error("Unknown file: " + suggestBadWordForm.suggestBadWordFile); - throw new SSCActionMessagesException("errors.unknown_import_file"); - } - final String enc = crawlerProperties.getProperty(Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8); - new Thread(() -> { - Reader reader = null; - try { - reader = new BufferedReader(new InputStreamReader(new FileInputStream(oFile), enc)); - suggestBadWordService.importCsv(reader); - } catch (final Exception e) { - logger.error("Failed to import data.", e); - throw new FessSystemException("Failed to import data.", e); - } finally { - if (!oFile.delete()) { - logger.warn("Could not delete " + oFile.getAbsolutePath()); - } - IOUtils.closeQuietly(reader); - suggestHelper.deleteAllBadWord(); - suggestHelper.updateSolrBadwordFile(); - } - }).start(); - } catch (final ActionMessagesException e) { - if (!oFile.delete()) { - logger.warn("Could not delete " + oFile.getAbsolutePath()); - } - throw e; - } catch (final Exception e) { - if (!oFile.delete()) { - logger.warn("Could not delete " + oFile.getAbsolutePath()); - } - logger.error("Failed to import data.", e); - throw new SSCActionMessagesException(e, "errors.failed_to_import_data"); - } - SAStrutsUtil.addSessionMessage("success.upload_suggest_bad_word"); - - return "uploadpage?redirect=true"; - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/SuggestElevateWordAction.java b/src/main/java/org/codelibs/fess/web/admin/SuggestElevateWordAction.java deleted file mode 100644 index 6a0f66ae4..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/SuggestElevateWordAction.java +++ /dev/null @@ -1,454 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.BufferedInputStream; -import java.io.BufferedReader; -import java.io.BufferedWriter; -import java.io.File; -import java.io.FileInputStream; -import java.io.FileOutputStream; -import java.io.InputStreamReader; -import java.io.OutputStreamWriter; -import java.io.Reader; -import java.io.Writer; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; -import javax.servlet.http.HttpServletResponse; - -import org.apache.commons.io.IOUtils; -import org.codelibs.core.misc.DynamicProperties; -import org.codelibs.fess.Constants; -import org.codelibs.fess.FessSystemException; -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.SuggestElevateWord; -import org.codelibs.fess.helper.SuggestHelper; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.SuggestElevateWordPager; -import org.codelibs.fess.service.SuggestElevateWordService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.robot.util.StreamUtil; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.seasar.struts.util.ResponseUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class SuggestElevateWordAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(SuggestElevateWordAction.class); - - @Resource - protected SystemHelper systemHelper; - - @Resource - protected SuggestHelper suggestHelper; - - @Resource - protected DynamicProperties crawlerProperties; - - // for list - - public List suggestElevateWordItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected SuggestElevateWordForm suggestElevateWordForm; - - @Resource - protected SuggestElevateWordService suggestElevateWordService; - - @Resource - protected SuggestElevateWordPager suggestElevateWordPager; - - protected String displayList(final boolean redirect) { - // page navi - suggestElevateWordItems = suggestElevateWordService.getSuggestElevateWordList(suggestElevateWordPager); - - // restore from pager - Beans.copy(suggestElevateWordPager, suggestElevateWordForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(suggestElevateWordForm.pageNumber)) { - try { - suggestElevateWordPager.setCurrentPageNumber(Integer.parseInt(suggestElevateWordForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + suggestElevateWordForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(suggestElevateWordForm.searchParams, suggestElevateWordPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - suggestElevateWordPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (suggestElevateWordForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - suggestElevateWordForm.crudMode }); - } - - loadSuggestElevateWord(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - suggestElevateWordForm.initialize(); - suggestElevateWordForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (suggestElevateWordForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, - suggestElevateWordForm.crudMode }); - } - - loadSuggestElevateWord(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - suggestElevateWordForm.crudMode = CommonConstants.EDIT_MODE; - - loadSuggestElevateWord(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (suggestElevateWordForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - suggestElevateWordForm.crudMode }); - } - - loadSuggestElevateWord(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - suggestElevateWordForm.crudMode = CommonConstants.DELETE_MODE; - - loadSuggestElevateWord(); - - return "confirm.jsp"; - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", suggestElevateWordForm.id); - - return keys; - } - - public String getHelpLink() { - return systemHelper.getHelpLink("suggestElevateWord"); - } - - protected void loadSuggestElevateWord() { - - final SuggestElevateWord suggestElevateWord = suggestElevateWordService.getSuggestElevateWord(createKeyMap()); - if (suggestElevateWord == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { suggestElevateWordForm.id }); - } - - FessBeans.copy(suggestElevateWord, suggestElevateWordForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - } - - protected SuggestElevateWord createSuggestElevateWord() { - SuggestElevateWord suggestElevateWord; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (suggestElevateWordForm.crudMode == CommonConstants.EDIT_MODE) { - suggestElevateWord = suggestElevateWordService.getSuggestElevateWord(createKeyMap()); - if (suggestElevateWord == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { suggestElevateWordForm.id }); - } - } else { - suggestElevateWord = new SuggestElevateWord(); - suggestElevateWord.setCreatedBy(username); - suggestElevateWord.setCreatedTime(currentTime); - } - suggestElevateWord.setUpdatedBy(username); - suggestElevateWord.setUpdatedTime(currentTime); - FessBeans.copy(suggestElevateWordForm, suggestElevateWord).excludesCommonColumns().execute(); - - return suggestElevateWord; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final SuggestElevateWord suggestElevateWord = createSuggestElevateWord(); - suggestElevateWordService.store(suggestElevateWord); - suggestHelper.storeAllElevateWords(); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final SuggestElevateWord suggestElevateWord = createSuggestElevateWord(); - suggestElevateWordService.store(suggestElevateWord); - suggestHelper.storeAllElevateWords(); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (suggestElevateWordForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - suggestElevateWordForm.crudMode }); - } - - try { - final SuggestElevateWord suggestElevateWord = suggestElevateWordService.getSuggestElevateWord(createKeyMap()); - if (suggestElevateWord == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { suggestElevateWordForm.id }); - } - - suggestElevateWordService.delete(suggestElevateWord); - suggestHelper.storeAllElevateWords(); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "downloadpage") - public String downloadpage() { - return "download.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = false, input = "downloadpage") - public String download() { - - final HttpServletResponse response = ResponseUtil.getResponse(); - response.setContentType("application/octet-stream"); - response.setHeader("Content-Disposition", "attachment; filename=\"" + "elevateword.csv" + "\""); - - try (Writer writer = - new BufferedWriter(new OutputStreamWriter(response.getOutputStream(), crawlerProperties.getProperty( - Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8)))) { - suggestElevateWordService.exportCsv(writer); - } catch (final Exception e) { - logger.error("Failed to export data.", e); - throw new SSCActionMessagesException(e, "errors.failed_to_export_data"); - } - return null; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "uploadpage") - public String uploadpage() { - return "upload.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "uploadpage") - public String upload() { - BufferedInputStream is = null; - File tempFile = null; - FileOutputStream fos = null; - final byte[] b = new byte[20]; - try { - tempFile = File.createTempFile("suggestelevateword-import-", ".csv"); - is = new BufferedInputStream(suggestElevateWordForm.suggestElevateWordFile.getInputStream()); - is.mark(20); - if (is.read(b, 0, 20) <= 0) { - throw new FessSystemException("no import data."); - } - is.reset(); - fos = new FileOutputStream(tempFile); - StreamUtil.drain(is, fos); - } catch (final Exception e) { - if (tempFile != null && !tempFile.delete()) { - logger.warn("Could not delete " + tempFile.getAbsolutePath()); - } - logger.error("Failed to import data.", e); - throw new SSCActionMessagesException(e, "errors.failed_to_import_data"); - } finally { - IOUtils.closeQuietly(is); - IOUtils.closeQuietly(fos); - } - - final File oFile = tempFile; - try { - final String head = new String(b, Constants.UTF_8); - if (!(head.startsWith("\"SuggestWord\"") || head.startsWith("SuggestWord"))) { - logger.error("Unknown file: " + suggestElevateWordForm.suggestElevateWordFile); - throw new SSCActionMessagesException("errors.unknown_import_file"); - } - final String enc = crawlerProperties.getProperty(Constants.CSV_FILE_ENCODING_PROPERTY, Constants.UTF_8); - new Thread(() -> { - Reader reader = null; - try { - reader = new BufferedReader(new InputStreamReader(new FileInputStream(oFile), enc)); - suggestElevateWordService.importCsv(reader); - } catch (final Exception e) { - logger.error("Failed to import data.", e); - throw new FessSystemException("Failed to import data.", e); - } finally { - if (!oFile.delete()) { - logger.warn("Could not delete " + oFile.getAbsolutePath()); - } - IOUtils.closeQuietly(reader); - suggestHelper.storeAllElevateWords(); - } - }).start(); - } catch (final ActionMessagesException e) { - if (!oFile.delete()) { - logger.warn("Could not delete " + oFile.getAbsolutePath()); - } - throw e; - } catch (final Exception e) { - if (!oFile.delete()) { - logger.warn("Could not delete " + oFile.getAbsolutePath()); - } - logger.error("Failed to import data.", e); - throw new SSCActionMessagesException(e, "errors.failed_to_import_data"); - } - SAStrutsUtil.addSessionMessage("success.upload_suggest_elevate_word"); - - return "uploadpage?redirect=true"; - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/SystemAction.java b/src/main/java/org/codelibs/fess/web/admin/SystemAction.java deleted file mode 100644 index 1ab876f8d..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/SystemAction.java +++ /dev/null @@ -1,133 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.Serializable; -import java.util.List; -import java.util.Set; - -import javax.annotation.Resource; -import javax.servlet.http.HttpSession; - -import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.client.FessEsClient; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.ScheduledJob; -import org.codelibs.fess.helper.JobHelper; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.service.ScheduledJobService; -import org.codelibs.sastruts.core.annotation.Token; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.util.RequestUtil; - -public class SystemAction implements Serializable { - private static final String STARTING_CRAWL_PROCESS = "startingCrawlProcess"; - - private static final long serialVersionUID = 1L; - - @ActionForm - @Resource - protected SystemForm systemForm; - - @Resource - protected FessEsClient fessEsClient; - - @Resource - protected SystemHelper systemHelper; - - @Resource - protected JobHelper jobHelper; - - @Resource - protected ScheduledJobService scheduledJobService; - - public String clusterName; - - public String clusterStatus; - - public String getHelpLink() { - return systemHelper.getHelpLink("system"); - } - - protected String showIndex(final boolean redirect) { - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Token(save = true, validate = false) - @Execute(validator = false) - public String index() { - return showIndex(false); - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "index") - public String start() { - if (!jobHelper.isCrawlProcessRunning()) { - final List scheduledJobList = scheduledJobService.getCrawloerJobList(); - for (final ScheduledJob scheduledJob : scheduledJobList) { - scheduledJob.start(); - } - SAStrutsUtil.addSessionMessage("success.start_crawl_process"); - RequestUtil.getRequest().getSession().setAttribute(STARTING_CRAWL_PROCESS, Boolean.TRUE); - } else { - SAStrutsUtil.addSessionMessage("success.failed_to_start_crawl_process"); - } - return showIndex(true); - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "index") - public String stop() { - if (jobHelper.isCrawlProcessRunning()) { - if (StringUtil.isNotBlank(systemForm.sessionId)) { - jobHelper.destroyCrawlerProcess(systemForm.sessionId); - } else { - for (final String sessionId : jobHelper.getRunningSessionIdSet()) { - jobHelper.destroyCrawlerProcess(sessionId); - } - } - SAStrutsUtil.addSessionMessage("success.stopping_crawl_process"); - } else { - SAStrutsUtil.addSessionMessage("errors.no_running_crawl_process"); - } - return showIndex(true); - } - - public boolean isCrawlerRunning() { - final HttpSession session = RequestUtil.getRequest().getSession(false); - if (session != null) { - final Object obj = session.getAttribute(STARTING_CRAWL_PROCESS); - if (obj != null) { - session.removeAttribute(STARTING_CRAWL_PROCESS); - return true; - } - } - return jobHelper.isCrawlProcessRunning(); - } - - public String[] getRunningSessionIds() { - final Set idSet = jobHelper.getRunningSessionIdSet(); - return idSet.toArray(new String[idSet.size()]); - } - -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/SystemInfoAction.java b/src/main/java/org/codelibs/fess/web/admin/SystemInfoAction.java deleted file mode 100644 index 0a3d0ea24..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/SystemInfoAction.java +++ /dev/null @@ -1,118 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.Serializable; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.core.lang.StringUtil; -import org.codelibs.core.misc.DynamicProperties; -import org.codelibs.fess.Constants; -import org.codelibs.fess.helper.SystemHelper; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; - -public class SystemInfoAction implements Serializable { - - private static final long serialVersionUID = 1L; - - @ActionForm - @Resource - protected SystemInfoForm systemInfoForm; - - @Resource - protected DynamicProperties crawlerProperties; - - public List> envItems; - - public List> propItems; - - public List> fessPropItems; - - public List> bugReportItems; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("systemInfo"); - } - - @Execute(validator = false) - public String index() { - envItems = new ArrayList>(); - propItems = new ArrayList>(); - fessPropItems = new ArrayList>(); - bugReportItems = new ArrayList>(); - - for (final Map.Entry entry : System.getenv().entrySet()) { - envItems.add(createItem(entry.getKey(), entry.getValue())); - } - - for (final Map.Entry entry : System.getProperties().entrySet()) { - propItems.add(createItem(entry.getKey(), entry.getValue())); - } - - for (final Map.Entry entry : crawlerProperties.entrySet()) { - fessPropItems.add(createItem(entry.getKey(), entry.getValue())); - } - - bugReportItems.add(createPropItem("file.separator")); - bugReportItems.add(createPropItem("file.encoding")); - bugReportItems.add(createPropItem("java.runtime.version")); - bugReportItems.add(createPropItem("java.vm.info")); - bugReportItems.add(createPropItem("java.vm.name")); - bugReportItems.add(createPropItem("java.vm.vendor")); - bugReportItems.add(createPropItem("java.vm.version")); - bugReportItems.add(createPropItem("os.arch")); - bugReportItems.add(createPropItem("os.name")); - bugReportItems.add(createPropItem("os.version")); - bugReportItems.add(createPropItem("user.country")); - bugReportItems.add(createPropItem("user.language")); - bugReportItems.add(createPropItem("user.timezone")); - for (final Map.Entry entry : crawlerProperties.entrySet()) { - if (isBugReportTarget(entry.getKey())) { - bugReportItems.add(createItem(entry.getKey(), entry.getValue())); - } - } - - return "index.jsp"; - } - - private boolean isBugReportTarget(final Object key) { - if ("snapshot.path".equals(key) || "label.value".equals(key)) { - return false; - } - return true; - } - - private Map createPropItem(final String key) { - return createItem(key, System.getProperty(key)); - } - - private Map createItem(final Object label, final Object value) { - final Map map = new HashMap(2); - map.put(Constants.ITEM_LABEL, label != null ? label.toString() : StringUtil.EMPTY); - map.put(Constants.ITEM_VALUE, value != null ? value.toString() : StringUtil.EMPTY); - return map; - } -} \ No newline at end of file diff --git a/src/main/java/org/codelibs/fess/web/admin/WebAuthenticationAction.java b/src/main/java/org/codelibs/fess/web/admin/WebAuthenticationAction.java deleted file mode 100644 index 244205930..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/WebAuthenticationAction.java +++ /dev/null @@ -1,377 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.Constants; -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.WebAuthentication; -import org.codelibs.fess.es.exentity.WebConfig; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.WebAuthenticationPager; -import org.codelibs.fess.service.WebAuthenticationService; -import org.codelibs.fess.service.WebConfigService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.seasar.struts.util.MessageResourcesUtil; -import org.seasar.struts.util.RequestUtil; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class WebAuthenticationAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(WebAuthenticationAction.class); - - // for list - - public List webAuthenticationItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected WebAuthenticationForm webAuthenticationForm; - - @Resource - protected WebAuthenticationService webAuthenticationService; - - @Resource - protected WebAuthenticationPager webAuthenticationPager; - - @Resource - protected WebConfigService webConfigService; - - @Resource - protected SystemHelper systemHelper; - - protected String displayList(final boolean redirect) { - // page navi - webAuthenticationItems = webAuthenticationService.getWebAuthenticationList(webAuthenticationPager); - - // restore from pager - Beans.copy(webAuthenticationPager, webAuthenticationForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(webAuthenticationForm.pageNumber)) { - try { - webAuthenticationPager.setCurrentPageNumber(Integer.parseInt(webAuthenticationForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + webAuthenticationForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(webAuthenticationForm.searchParams, webAuthenticationPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - webAuthenticationPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (webAuthenticationForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - webAuthenticationForm.crudMode }); - } - - loadWebAuthentication(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - webAuthenticationForm.initialize(); - webAuthenticationForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (webAuthenticationForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, - webAuthenticationForm.crudMode }); - } - - loadWebAuthentication(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - webAuthenticationForm.crudMode = CommonConstants.EDIT_MODE; - - loadWebAuthentication(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (webAuthenticationForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - webAuthenticationForm.crudMode }); - } - - loadWebAuthentication(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - webAuthenticationForm.crudMode = CommonConstants.DELETE_MODE; - - loadWebAuthentication(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final WebAuthentication webAuthentication = createWebAuthentication(); - webAuthenticationService.store(webAuthentication); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final WebAuthentication webAuthentication = createWebAuthentication(); - webAuthenticationService.store(webAuthentication); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", webAuthenticationForm.id); - - return keys; - } - - public String getHelpLink() { - return systemHelper.getHelpLink("webAuthentication"); - } - - protected void loadWebAuthentication() { - - final WebAuthentication webAuthentication = webAuthenticationService.getWebAuthentication(createKeyMap()); - if (webAuthentication == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { webAuthenticationForm.id }); - } - - FessBeans.copy(webAuthentication, webAuthenticationForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - if ("-1".equals(webAuthenticationForm.port)) { - webAuthenticationForm.port = StringUtil.EMPTY; - } - } - - protected WebAuthentication createWebAuthentication() { - WebAuthentication webAuthentication; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (webAuthenticationForm.crudMode == CommonConstants.EDIT_MODE) { - webAuthentication = webAuthenticationService.getWebAuthentication(createKeyMap()); - if (webAuthentication == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { webAuthenticationForm.id }); - } - } else { - webAuthentication = new WebAuthentication(); - webAuthentication.setCreatedBy(username); - webAuthentication.setCreatedTime(currentTime); - } - webAuthentication.setUpdatedBy(username); - webAuthentication.setUpdatedTime(currentTime); - if (StringUtil.isBlank(webAuthenticationForm.port)) { - webAuthenticationForm.port = "-1"; - } - FessBeans.copy(webAuthenticationForm, webAuthentication).excludesCommonColumns().execute(); - - return webAuthentication; - } - - @Token(save = false, validate = true) - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (webAuthenticationForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - webAuthenticationForm.crudMode }); - } - - try { - final WebAuthentication webAuthentication = webAuthenticationService.getWebAuthentication(createKeyMap()); - if (webAuthentication == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { webAuthenticationForm.id }); - } - - webAuthenticationService.delete(webAuthentication); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - public boolean isDisplayCreateLink() { - return !webConfigService.getAllWebConfigList(false, false, false, null).isEmpty(); - } - - public List> getWebConfigItems() { - final List> items = new ArrayList>(); - final List webConfigList = webConfigService.getAllWebConfigList(false, false, false, null); - for (final WebConfig webConfig : webConfigList) { - items.add(createItem(webConfig.getName(), webConfig.getId().toString())); - } - return items; - } - - public List> getProtocolSchemeItems() { - final List> items = new ArrayList>(); - items.add(createItem( - MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "labels.web_authentication_scheme_basic"), - Constants.BASIC)); - items.add(createItem( - MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "labels.web_authentication_scheme_digest"), - Constants.DIGEST)); - items.add(createItem( - MessageResourcesUtil.getMessage(RequestUtil.getRequest().getLocale(), "labels.web_authentication_scheme_ntlm"), - Constants.NTLM)); - return items; - } - - protected Map createItem(final String label, final String value) { - final Map map = new HashMap(2); - map.put("label", label); - map.put("value", value); - return map; - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/WebConfigAction.java b/src/main/java/org/codelibs/fess/web/admin/WebConfigAction.java deleted file mode 100644 index 8149e2353..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/WebConfigAction.java +++ /dev/null @@ -1,357 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.codelibs.fess.beans.FessBeans; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.es.exentity.CrawlingConfig; -import org.codelibs.fess.es.exentity.LabelType; -import org.codelibs.fess.es.exentity.RoleType; -import org.codelibs.fess.es.exentity.WebConfig; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.WebConfigPager; -import org.codelibs.fess.service.FailureUrlService; -import org.codelibs.fess.service.LabelTypeService; -import org.codelibs.fess.service.RoleTypeService; -import org.codelibs.fess.service.WebConfigService; -import org.codelibs.fess.web.base.FessAdminAction; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class WebConfigAction extends FessAdminAction { - - private static final Logger logger = LoggerFactory.getLogger(WebConfigAction.class); - - // for list - - public List webConfigItems; - - // for edit/confirm/delete - - @ActionForm - @Resource - protected WebConfigForm webConfigForm; - - @Resource - protected WebConfigService webConfigService; - - @Resource - protected WebConfigPager webConfigPager; - - @Resource - protected RoleTypeService roleTypeService; - - @Resource - protected LabelTypeService labelTypeService; - - @Resource - protected FailureUrlService failureUrlService; - - @Resource - protected SystemHelper systemHelper; - - public String getHelpLink() { - return systemHelper.getHelpLink("webConfig"); - } - - protected String displayList(final boolean redirect) { - // page navi - webConfigItems = webConfigService.getWebConfigList(webConfigPager); - - // restore from pager - Beans.copy(webConfigPager, webConfigForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - if (redirect) { - return "index?redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(webConfigForm.pageNumber)) { - try { - webConfigPager.setCurrentPageNumber(Integer.parseInt(webConfigForm.pageNumber)); - } catch (final NumberFormatException e) { - if (logger.isDebugEnabled()) { - logger.debug("Invalid value: " + webConfigForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(webConfigForm.searchParams, webConfigPager).excludes(CommonConstants.PAGER_CONVERSION_RULE) - - .execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - webConfigPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{crudMode}/{id}") - public String confirmpage() { - if (webConfigForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - webConfigForm.crudMode }); - } - - loadWebConfig(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - webConfigForm.initialize(); - webConfigForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{crudMode}/{id}") - public String editpage() { - if (webConfigForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.EDIT_MODE, webConfigForm.crudMode }); - } - - loadWebConfig(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - webConfigForm.crudMode = CommonConstants.EDIT_MODE; - - loadWebConfig(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{crudMode}/{id}") - public String deletepage() { - if (webConfigForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - webConfigForm.crudMode }); - } - - loadWebConfig(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - webConfigForm.crudMode = CommonConstants.DELETE_MODE; - - loadWebConfig(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final WebConfig webConfig = createWebConfig(); - webConfigService.store(webConfig); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final WebConfig webConfig = createWebConfig(); - webConfigService.store(webConfig); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException(e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new ActionMessagesException("errors.crud_failed_to_update_crud_table"); - } - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - - keys.put("id", webConfigForm.id); - - return keys; - } - - protected void loadWebConfig() { - - final CrawlingConfig webConfig = webConfigService.getWebConfig(createKeyMap()); - if (webConfig == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { webConfigForm.id }); - } - - FessBeans.copy(webConfig, webConfigForm).commonColumnDateConverter().excludes("searchParams", "mode").execute(); - - // normalize boost - if (webConfigForm.boost != null && webConfigForm.boost.indexOf('.') > 0) { - webConfigForm.boost = webConfigForm.boost.substring(0, webConfigForm.boost.indexOf('.')); - } - } - - protected WebConfig createWebConfig() { - WebConfig webConfig; - final String username = systemHelper.getUsername(); - final long currentTime = systemHelper.getCurrentTimeAsLong(); - if (webConfigForm.crudMode == CommonConstants.EDIT_MODE) { - webConfig = webConfigService.getWebConfig(createKeyMap()); - if (webConfig == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { webConfigForm.id }); - } - } else { - webConfig = new WebConfig(); - webConfig.setCreatedBy(username); - webConfig.setCreatedTime(currentTime); - } - webConfig.setUpdatedBy(username); - webConfig.setUpdatedTime(currentTime); - FessBeans.copy(webConfigForm, webConfig).excludesCommonColumns().execute(); - - return webConfig; - } - - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (webConfigForm.crudMode != CommonConstants.DELETE_MODE) { - throw new SSCActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.DELETE_MODE, - webConfigForm.crudMode }); - } - - try { - final WebConfig webConfig = webConfigService.getWebConfig(createKeyMap()); - if (webConfig == null) { - // throw an exception - throw new SSCActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { webConfigForm.id }); - } - - failureUrlService.deleteByConfigId(webConfig.getConfigId()); - - webConfigService.delete(webConfig); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final ActionMessagesException e) { - logger.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - logger.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - public List getRoleTypeItems() { - return roleTypeService.getRoleTypeList(); - } - - public List getLabelTypeItems() { - return labelTypeService.getLabelTypeList(); - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/WizardForm.java b/src/main/java/org/codelibs/fess/web/admin/WizardForm.java deleted file mode 100644 index f2d1ddb44..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/WizardForm.java +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin; - -import java.io.Serializable; - -import org.seasar.struts.annotation.IntRange; -import org.seasar.struts.annotation.LongRange; -import org.seasar.struts.annotation.Maxbytelength; -import org.seasar.struts.annotation.Required; - -public class WizardForm implements Serializable { - - private static final long serialVersionUID = 1L; - - @Maxbytelength(maxbytelength = 200, target = "crawlingConfig,crawlingConfigNext") - public String crawlingConfigName; - - @Required(target = "crawlingConfig,crawlingConfigNext") - @Maxbytelength(maxbytelength = 1000) - public String crawlingConfigPath; - - @LongRange(min = 0, max = Long.MAX_VALUE, target = "crawlingConfig,crawlingConfigNext") - public String maxAccessCount; - - @IntRange(min = 0, max = Integer.MAX_VALUE, target = "crawlingConfig,crawlingConfigNext") - public String depth; - - public WizardForm() { - maxAccessCount = "10000"; - depth = null; - } -} diff --git a/src/main/java/org/codelibs/fess/web/admin/dict/SynonymAction.java b/src/main/java/org/codelibs/fess/web/admin/dict/SynonymAction.java deleted file mode 100644 index 1c1111de3..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/dict/SynonymAction.java +++ /dev/null @@ -1,408 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin.dict; - -import java.io.IOException; -import java.io.InputStream; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.apache.commons.lang3.StringUtils; -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; -import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.dict.DictionaryExpiredException; -import org.codelibs.fess.dict.synonym.SynonymFile; -import org.codelibs.fess.dict.synonym.SynonymItem; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.SynonymPager; -import org.codelibs.fess.service.SynonymService; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.seasar.struts.util.ResponseUtil; - -public class SynonymAction { - - private static final Log log = LogFactory.getLog(SynonymAction.class); - - @Resource - @ActionForm - protected SynonymForm synonymForm; - - @Resource - protected SynonymService synonymService; - - @Resource - protected SynonymPager synonymPager; - - @Resource - protected SystemHelper systemHelper; - - public List synonymItemItems; - - public String filename; - - public String getHelpLink() { - return systemHelper.getHelpLink("dict"); - } - - protected String displayList(final boolean redirect) { - // page navi - synonymItemItems = synonymService.getSynonymList(synonymForm.dictId, synonymPager); - - // restore from pager - Beans.copy(synonymPager, synonymForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE).execute(); - - if (redirect) { - return "index?dictId=" + synonymForm.dictId + "&redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{dictId}/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(synonymForm.pageNumber)) { - try { - synonymPager.setCurrentPageNumber(Integer.parseInt(synonymForm.pageNumber)); - } catch (final NumberFormatException e) { - if (log.isDebugEnabled()) { - log.debug("Invalid value: " + synonymForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(synonymForm.searchParams, synonymPager).excludes(CommonConstants.PAGER_CONVERSION_RULE).execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - synonymPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{dictId}/{crudMode}/{id}") - public String confirmpage() { - if (synonymForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.CONFIRM_MODE, synonymForm.crudMode }); - } - - loadSynonym(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - synonymForm.initialize(); - synonymForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{dictId}/{crudMode}/{id}") - public String editpage() { - if (synonymForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, synonymForm.crudMode }); - } - - loadSynonym(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - synonymForm.crudMode = CommonConstants.EDIT_MODE; - - loadSynonym(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{dictId}/{crudMode}/{id}") - public String deletepage() { - if (synonymForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.DELETE_MODE, synonymForm.crudMode }); - } - - loadSynonym(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - synonymForm.crudMode = CommonConstants.DELETE_MODE; - - loadSynonym(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final SynonymItem synonymItem = createSynonym(); - synonymService.store(synonymForm.dictId, synonymItem); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final DictionaryExpiredException e) { - throw e; - } catch (final ActionMessagesException e) { - log.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final SynonymItem synonymItem = createSynonym(); - synonymService.store(synonymForm.dictId, synonymItem); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final DictionaryExpiredException e) { - throw e; - } catch (final ActionMessagesException e) { - log.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_update_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (synonymForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.DELETE_MODE, synonymForm.crudMode }); - } - - try { - final SynonymItem synonymItem = synonymService.getSynonym(synonymForm.dictId, createKeyMap()); - if (synonymItem == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { synonymForm.id }); - - } - - synonymService.delete(synonymForm.dictId, synonymItem); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final DictionaryExpiredException e) { - throw e; - } catch (final ActionMessagesException e) { - log.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "downloadpage") - public String downloadpage() { - final SynonymFile synonymFile = synonymService.getSynonymFile(synonymForm.dictId); - if (synonymFile == null) { - throw new SSCActionMessagesException("errors.synonym_file_is_not_found"); - } - filename = synonymFile.getSimpleName(); - return "download.jsp"; - } - - @Token(save = true, validate = true) - @Execute(validator = false, input = "downloadpage") - public String download() { - final SynonymFile synonymFile = synonymService.getSynonymFile(synonymForm.dictId); - if (synonymFile == null) { - throw new SSCActionMessagesException("errors.synonym_file_is_not_found"); - } - try (InputStream in = synonymFile.getInputStream()) { - ResponseUtil.download(synonymFile.getSimpleName(), in); - } catch (final IOException e) { - throw new SSCActionMessagesException("errors.failed_to_download_synonym_file"); - } - - return null; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "uploadpage") - public String uploadpage() { - final SynonymFile synonymFile = synonymService.getSynonymFile(synonymForm.dictId); - if (synonymFile == null) { - throw new SSCActionMessagesException("errors.synonym_file_is_not_found"); - } - filename = synonymFile.getName(); - return "upload.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "uploadpage") - public String upload() { - final SynonymFile synonymFile = synonymService.getSynonymFile(synonymForm.dictId); - if (synonymFile == null) { - throw new SSCActionMessagesException("errors.synonym_file_is_not_found"); - } - try (InputStream in = synonymForm.synonymFile.getInputStream()) { - synonymFile.update(in); - } catch (final IOException e) { - throw new SSCActionMessagesException("errors.failed_to_upload_synonym_file"); - } - - SAStrutsUtil.addSessionMessage("success.upload_synonym_file"); - - return "uploadpage?dictId=" + synonymForm.dictId + "&redirect=true"; - } - - protected void loadSynonym() { - - final SynonymItem synonymItem = synonymService.getSynonym(synonymForm.dictId, createKeyMap()); - if (synonymItem == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { synonymForm.id }); - - } - - synonymForm.id = Long.toString(synonymItem.getId()); - synonymForm.inputs = StringUtils.join(synonymItem.getInputs(), "\n"); - synonymForm.outputs = StringUtils.join(synonymItem.getOutputs(), "\n"); - } - - protected SynonymItem createSynonym() { - SynonymItem synonymItem; - if (synonymForm.crudMode == CommonConstants.EDIT_MODE) { - synonymItem = synonymService.getSynonym(synonymForm.dictId, createKeyMap()); - if (synonymItem == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { synonymForm.id }); - - } - } else { - synonymItem = new SynonymItem(0, StringUtil.EMPTY_STRINGS, StringUtil.EMPTY_STRINGS); - } - - final String[] newInputs = splitLine(synonymForm.inputs); - synonymItem.setNewInputs(newInputs); - final String[] newOutputs = splitLine(synonymForm.outputs); - synonymItem.setNewOutputs(newOutputs); - - return synonymItem; - } - - private String[] splitLine(final String value) { - if (StringUtil.isBlank(value)) { - return StringUtil.EMPTY_STRINGS; - } - final String[] values = value.split("[\r\n]"); - final List list = new ArrayList(values.length); - for (final String line : values) { - if (StringUtil.isNotBlank(line)) { - list.add(line.trim()); - } - } - return list.toArray(new String[list.size()]); - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - keys.put("id", synonymForm.id); - return keys; - } - -} diff --git a/src/main/java/org/codelibs/fess/web/admin/dict/UserDictAction.java b/src/main/java/org/codelibs/fess/web/admin/dict/UserDictAction.java deleted file mode 100644 index a03ba1158..000000000 --- a/src/main/java/org/codelibs/fess/web/admin/dict/UserDictAction.java +++ /dev/null @@ -1,394 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ - -package org.codelibs.fess.web.admin.dict; - -import java.io.IOException; -import java.io.InputStream; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.annotation.Resource; - -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; -import org.codelibs.core.lang.StringUtil; -import org.codelibs.fess.crud.CommonConstants; -import org.codelibs.fess.crud.CrudMessageException; -import org.codelibs.fess.crud.util.SAStrutsUtil; -import org.codelibs.fess.dict.DictionaryExpiredException; -import org.codelibs.fess.dict.userdict.UserDictFile; -import org.codelibs.fess.dict.userdict.UserDictItem; -import org.codelibs.fess.helper.SystemHelper; -import org.codelibs.fess.pager.UserDictPager; -import org.codelibs.fess.service.UserDictService; -import org.codelibs.sastruts.core.annotation.Token; -import org.codelibs.sastruts.core.exception.SSCActionMessagesException; -import org.seasar.framework.beans.util.Beans; -import org.seasar.struts.annotation.ActionForm; -import org.seasar.struts.annotation.Execute; -import org.seasar.struts.exception.ActionMessagesException; -import org.seasar.struts.util.ResponseUtil; - -public class UserDictAction { - - private static final Log log = LogFactory.getLog(UserDictAction.class); - - @Resource - @ActionForm - protected UserDictForm userDictForm; - - @Resource - protected UserDictService userDictService; - - @Resource - protected UserDictPager userDictPager; - - @Resource - protected SystemHelper systemHelper; - - public List userDictItemItems; - - public String filename; - - public String getHelpLink() { - return systemHelper.getHelpLink("dict"); - } - - protected String displayList(final boolean redirect) { - // page navi - userDictItemItems = userDictService.getUserDictList(userDictForm.dictId, userDictPager); - - // restore from pager - Beans.copy(userDictPager, userDictForm.searchParams).excludes(CommonConstants.PAGER_CONVERSION_RULE).execute(); - - if (redirect) { - return "index?dictId=" + userDictForm.dictId + "&redirect=true"; - } else { - return "index.jsp"; - } - } - - @Execute(validator = false, input = "error.jsp") - public String index() { - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "list/{dictId}/{pageNumber}") - public String list() { - // page navi - if (StringUtil.isNotBlank(userDictForm.pageNumber)) { - try { - userDictPager.setCurrentPageNumber(Integer.parseInt(userDictForm.pageNumber)); - } catch (final NumberFormatException e) { - if (log.isDebugEnabled()) { - log.debug("Invalid value: " + userDictForm.pageNumber, e); - } - } - } - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String search() { - Beans.copy(userDictForm.searchParams, userDictPager).excludes(CommonConstants.PAGER_CONVERSION_RULE).execute(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String reset() { - userDictPager.clear(); - - return displayList(false); - } - - @Execute(validator = false, input = "error.jsp") - public String back() { - return displayList(false); - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editagain() { - return "edit.jsp"; - } - - @Execute(validator = false, input = "error.jsp", urlPattern = "confirmpage/{dictId}/{crudMode}/{id}") - public String confirmpage() { - if (userDictForm.crudMode != CommonConstants.CONFIRM_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.CONFIRM_MODE, - userDictForm.crudMode }); - } - - loadUserDict(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String createpage() { - // page navi - userDictForm.initialize(); - userDictForm.crudMode = CommonConstants.CREATE_MODE; - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "editpage/{dictId}/{crudMode}/{id}") - public String editpage() { - if (userDictForm.crudMode != CommonConstants.EDIT_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", new Object[] { CommonConstants.EDIT_MODE, userDictForm.crudMode }); - } - - loadUserDict(); - - return "edit.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String editfromconfirm() { - userDictForm.crudMode = CommonConstants.EDIT_MODE; - - loadUserDict(); - - return "edit.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromcreate() { - return "confirm.jsp"; - } - - @Token(save = false, validate = true, keep = true) - @Execute(validator = true, input = "edit.jsp") - public String confirmfromupdate() { - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp", urlPattern = "deletepage/{dictId}/{crudMode}/{id}") - public String deletepage() { - if (userDictForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.DELETE_MODE, userDictForm.crudMode }); - } - - loadUserDict(); - - return "confirm.jsp"; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "error.jsp") - public String deletefromconfirm() { - userDictForm.crudMode = CommonConstants.DELETE_MODE; - - loadUserDict(); - - return "confirm.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String create() { - try { - final UserDictItem userDictItem = createUserDict(); - userDictService.store(userDictForm.dictId, userDictItem); - SAStrutsUtil.addSessionMessage("success.crud_create_crud_table"); - - return displayList(true); - } catch (final DictionaryExpiredException e) { - throw e; - } catch (final ActionMessagesException e) { - log.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_create_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "edit.jsp") - public String update() { - try { - final UserDictItem userDictItem = createUserDict(); - userDictService.store(userDictForm.dictId, userDictItem); - SAStrutsUtil.addSessionMessage("success.crud_update_crud_table"); - - return displayList(true); - } catch (final DictionaryExpiredException e) { - throw e; - } catch (final ActionMessagesException e) { - log.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_update_crud_table"); - } - } - - @Token(save = false, validate = true) - @Execute(validator = false, input = "error.jsp") - public String delete() { - if (userDictForm.crudMode != CommonConstants.DELETE_MODE) { - throw new ActionMessagesException("errors.crud_invalid_mode", - new Object[] { CommonConstants.DELETE_MODE, userDictForm.crudMode }); - } - - try { - final UserDictItem userDictItem = userDictService.getUserDict(userDictForm.dictId, createKeyMap()); - if (userDictItem == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { userDictForm.id }); - - } - - userDictService.delete(userDictForm.dictId, userDictItem); - SAStrutsUtil.addSessionMessage("success.crud_delete_crud_table"); - - return displayList(true); - } catch (final DictionaryExpiredException e) { - throw e; - } catch (final ActionMessagesException e) { - log.error(e.getMessage(), e); - throw e; - } catch (final CrudMessageException e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, e.getMessageId(), e.getArgs()); - } catch (final Exception e) { - log.error(e.getMessage(), e); - throw new SSCActionMessagesException(e, "errors.crud_failed_to_delete_crud_table"); - } - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "downloadpage") - public String downloadpage() { - final UserDictFile userdictFile = userDictService.getUserDictFile(userDictForm.dictId); - if (userdictFile == null) { - throw new SSCActionMessagesException("errors.userdict_file_is_not_found"); - } - filename = userdictFile.getSimpleName(); - return "download.jsp"; - } - - @Token(save = true, validate = true) - @Execute(validator = false, input = "downloadpage") - public String download() { - final UserDictFile userdictFile = userDictService.getUserDictFile(userDictForm.dictId); - if (userdictFile == null) { - throw new SSCActionMessagesException("errors.userdict_file_is_not_found"); - } - try (InputStream in = userdictFile.getInputStream()) { - ResponseUtil.download(userdictFile.getSimpleName(), in); - } catch (final IOException e) { - throw new SSCActionMessagesException("errors.failed_to_download_userdict_file"); - } - - return null; - } - - @Token(save = true, validate = false) - @Execute(validator = false, input = "uploadpage") - public String uploadpage() { - final UserDictFile userdictFile = userDictService.getUserDictFile(userDictForm.dictId); - if (userdictFile == null) { - throw new SSCActionMessagesException("errors.userdict_file_is_not_found"); - } - filename = userdictFile.getName(); - return "upload.jsp"; - } - - @Token(save = false, validate = true) - @Execute(validator = true, input = "uploadpage") - public String upload() { - final UserDictFile userdictFile = userDictService.getUserDictFile(userDictForm.dictId); - if (userdictFile == null) { - throw new SSCActionMessagesException("errors.userdict_file_is_not_found"); - } - try (InputStream in = userDictForm.userDictFile.getInputStream()) { - userdictFile.update(in); - } catch (final IOException e) { - throw new SSCActionMessagesException("errors.failed_to_upload_userdict_file"); - } - - SAStrutsUtil.addSessionMessage("success.upload_userdict_file"); - - return "uploadpage?dictId=" + userDictForm.dictId + "&redirect=true"; - } - - protected void loadUserDict() { - - final UserDictItem userDictItem = userDictService.getUserDict(userDictForm.dictId, createKeyMap()); - if (userDictItem == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", new Object[] { userDictForm.id }); - - } - - userDictForm.id = Long.toString(userDictItem.getId()); - userDictForm.token = userDictItem.getToken(); - userDictForm.segmentation = userDictItem.getSegmentation(); - userDictForm.reading = userDictItem.getReading(); - userDictForm.pos = userDictItem.getPos(); - } - - protected UserDictItem createUserDict() { - UserDictItem userDictItem; - if (userDictForm.crudMode == CommonConstants.EDIT_MODE) { - userDictItem = userDictService.getUserDict(userDictForm.dictId, createKeyMap()); - if (userDictItem == null) { - // throw an exception - throw new ActionMessagesException("errors.crud_could_not_find_crud_table", - - new Object[] { userDictForm.id }); - - } - } else { - userDictItem = new UserDictItem(0, StringUtil.EMPTY, StringUtil.EMPTY, StringUtil.EMPTY, StringUtil.EMPTY); - } - - userDictItem.setNewToken(userDictForm.token); - userDictItem.setNewSegmentation(userDictForm.segmentation); - userDictItem.setNewReading(userDictForm.reading); - userDictItem.setNewPos(userDictForm.pos); - - return userDictItem; - } - - protected Map createKeyMap() { - final Map keys = new HashMap(); - keys.put("id", userDictForm.id); - return keys; - } - -} diff --git a/src/main/java/org/codelibs/fess/web/base/FessAdminAction.java b/src/main/java/org/codelibs/fess/web/base/FessAdminAction.java deleted file mode 100644 index c7315b27f..000000000 --- a/src/main/java/org/codelibs/fess/web/base/FessAdminAction.java +++ /dev/null @@ -1,20 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.web.base; - -public abstract class FessAdminAction extends FessBaseAction { - -} diff --git a/src/main/java/org/codelibs/fess/web/base/FessBaseAction.java b/src/main/java/org/codelibs/fess/web/base/FessBaseAction.java deleted file mode 100644 index 7a8944cec..000000000 --- a/src/main/java/org/codelibs/fess/web/base/FessBaseAction.java +++ /dev/null @@ -1,838 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -/* - - * Copyright 2014-2015 the original author or authors. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.web.base; - -import java.lang.reflect.Method; -import java.time.LocalDate; -import java.time.LocalDateTime; -import java.util.List; -import java.util.Map; -import java.util.TimeZone; -import java.util.function.Function; -import java.util.stream.Collector; -import java.util.stream.Collectors; - -import javax.annotation.Resource; - -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; -import org.apache.struts.action.ActionMessages; -import org.codelibs.fess.entity.LoginInfo; -import org.codelibs.fess.lasta.core.direction.FessConfig; -import org.codelibs.fess.lasta.web.action.FessJspPath; -import org.codelibs.fess.lasta.web.action.FessMessages; -import org.codelibs.robot.dbflute.optional.OptionalObject; -import org.codelibs.sastruts.core.SSCConstants; -import org.dbflute.bhv.proposal.callback.ExecutedSqlCounter; -import org.dbflute.bhv.proposal.callback.TraceableSqlAdditionalInfoProvider; -import org.dbflute.exception.EntityAlreadyDeletedException; -import org.dbflute.exception.EntityAlreadyExistsException; -import org.dbflute.exception.EntityAlreadyUpdatedException; -import org.dbflute.helper.HandyDate; -import org.dbflute.hook.AccessContext; -import org.dbflute.hook.CallbackContext; -import org.dbflute.hook.SqlFireHook; -import org.dbflute.hook.SqlStringFilter; -import org.dbflute.saflute.core.exception.ApplicationBaseException; -import org.dbflute.saflute.core.exception.ExceptionTranslator; -import org.dbflute.saflute.core.magic.ThreadCacheContext; -import org.dbflute.saflute.core.time.TimeManager; -import org.dbflute.saflute.db.dbflute.accesscontext.AccessContextArranger; -import org.dbflute.saflute.db.dbflute.accesscontext.AccessContextResource; -import org.dbflute.saflute.db.dbflute.accesscontext.PreparedAccessContext; -import org.dbflute.saflute.db.dbflute.callbackcontext.RomanticTraceableSqlFireHook; -import org.dbflute.saflute.db.dbflute.callbackcontext.RomanticTraceableSqlStringFilter; -import org.dbflute.saflute.web.action.RootAction; -import org.dbflute.saflute.web.action.api.ApiManager; -import org.dbflute.saflute.web.action.api.ApiResult; -import org.dbflute.saflute.web.action.callback.ActionCallback; -import org.dbflute.saflute.web.action.callback.ActionExecuteMeta; -import org.dbflute.saflute.web.action.exception.ForcedIllegalTransitionApplicationException; -import org.dbflute.saflute.web.action.exception.ForcedRequest404NotFoundException; -import org.dbflute.saflute.web.action.exception.GetParameterNotFoundException; -import org.dbflute.saflute.web.action.exception.MessageKeyApplicationException; -import org.dbflute.saflute.web.servlet.request.RequestManager; -import org.dbflute.saflute.web.servlet.session.SessionManager; -import org.dbflute.saflute.web.servlet.taglib.MyErrorsTag; -import org.dbflute.saflute.web.servlet.taglib.MyHtmlMessagesTag; -import org.dbflute.util.DfTypeUtil; - -/** - * @author jflute - */ -public abstract class FessBaseAction extends RootAction implements ActionCallback, FessJspPath { - - // =================================================================================== - // Definition - // ========== - private static final Log LOG = LogFactory.getLog(FessBaseAction.class); - - // =================================================================================== - // Attribute - // ========= - @Resource - protected FessConfig fessConfig; - - /** The manager of time. (NotNull) */ - @Resource - protected TimeManager timeManager; - - /** The manager of session. (NotNull) */ - @Resource - protected SessionManager sessionManager; - - /** The translator of exception. (NotNull) */ - @Resource - protected ExceptionTranslator exceptionTranslator; - - /** The manager of API. (NotNull) */ - @Resource - protected ApiManager apiManager; - - // =================================================================================== - // Login - // ======= - protected OptionalObject getLoginInfo() { - return OptionalObject.of(sessionManager.getAttribute(SSCConstants.USER_INFO)); - } - - // =================================================================================== - // Message - // ======= - /** - * Create the action messages basically for session global errors or messages. - * @return The new-created action messages provided from Struts. (NotNull) - */ - protected ActionMessages createActionMessages() { // should be overridden as type-safe properties - return new ActionMessages(); - } - - // ----------------------------------------------------- - // Errors - // ------ - /** - * Save message as (global) action errors. (after deleting existing messages)
    - * This message will be deleted immediately after display if you use {@link MyErrorsTag}. - * @param messageKey The message key to be saved. (NotNull) - * @param args The varying array of arguments for the message. (NullAllowed, EmptyAllowed) - */ - protected void saveErrors(String messageKey, Object... args) { - sessionManager.saveErrors(messageKey, args); - } - - /** - * Save message as (global) action errors. (after deleting existing messages)
    - * This message will be deleted immediately after display if you use {@link MyErrorsTag}. - * @param errors The action message for errors. (NotNull, EmptyAllowed: removes existing errors) - */ - protected void saveErrors(ActionMessages errors) { - sessionManager.saveErrors(errors); - } - - /** - * Add message as (global) action errors to rear of existing messages.
    - * This message will be deleted immediately after display if you use {@link MyErrorsTag}. - * @param messageKey The message key to be added. (NotNull) - * @param args The varying array of arguments for the message. (NullAllowed, EmptyAllowed) - */ - protected void addErrors(String messageKey, Object... args) { - sessionManager.addErrors(messageKey, args); - } - - /** - * Does it have messages as (global or specified property) action errors at least one? - * @return The determination, true or false. - */ - protected boolean hasErrors() { - return sessionManager.hasErrors(); - } - - /** - * Get action message from (global) action errors. - * @return The object for action message. (NullAllowed: if no errors in session) - */ - protected ActionMessages getErrors() { - return sessionManager.getErrors(); - } - - /** - * Clear (global) action errors from session. - */ - protected void clearErrors() { - sessionManager.clearErrors(); - } - - // ----------------------------------------------------- - // Messages - // -------- - /** - * Save message as (global) action messages. (after deleting existing messages)
    - * This message will be deleted immediately after display if you use {@link MyHtmlMessagesTag}. - * @param messageKey The message key to be saved. (NotNull) - * @param args The varying array of arguments for the message. (NullAllowed, EmptyAllowed) - */ - protected void saveMessages(String messageKey, Object... args) { - sessionManager.saveMessages(messageKey, args); - } - - /** - * Save message as (global) action messages. (after deleting existing messages)
    - * This message will be deleted immediately after display if you use {@link MyHtmlMessagesTag}. - * @param messages The action message for messages. (NotNull, EmptyAllowed: removes existing messages) - */ - protected void saveMessages(ActionMessages messages) { - sessionManager.saveMessages(messages); - } - - /** - * Add message as (global) action messages to rear of existing messages.
    - * This message will be deleted immediately after display if you use {@link MyHtmlMessagesTag}. - * @param messageKey The message key to be added. (NotNull) - * @param args The varying array of arguments for the message. (NullAllowed, EmptyAllowed) - */ - protected void addMessages(String messageKey, Object... args) { - sessionManager.addMessages(messageKey, args); - } - - /** - * Does it have messages as (global or specified property) action messages at least one? - * @return The determination, true or false. - */ - protected boolean hasMessages() { - return sessionManager.hasMessages(); - } - - /** - * Get action message from (global) action errors. - * @return The object for action message. (NullAllowed: if no messages in session) - */ - protected ActionMessages getMessages() { - return sessionManager.getMessages(); - } - - /** - * Clear (global) action messages from session. - */ - protected void clearMessages() { - sessionManager.clearMessages(); - } - - // =================================================================================== - // Callback - // ======== - // [typical callback process] - // read the source code for the details - // (because of no comment here) - // ----------------------------------------------------- - // Before - // ------ - @Override - public final String godHandActionPrologue(final ActionExecuteMeta executeMeta) { // fixed process - arrangeThreadCacheContextBasicItem(executeMeta); - arrangePreparedAccessContext(executeMeta); - arrangeCallbackContext(executeMeta); // should be after access-context (using access context's info) - arrangeThreadCacheContextLoginItem(executeMeta); - return null; - } - - protected void arrangeThreadCacheContextBasicItem(ActionExecuteMeta executeMeta) { - if (ThreadCacheContext.exists()) { // basically true, just in case - ThreadCacheContext.registerRequestPath(requestManager.getRoutingOriginRequestPathAndQuery()); - ThreadCacheContext.registerEntryMethod(executeMeta.getActionMethod()); - } - } - - protected void arrangeThreadCacheContextLoginItem(ActionExecuteMeta executeMeta) { - if (ThreadCacheContext.exists()) { // basically true, just in case - ThreadCacheContext.registerUserBean(getLoginInfo().orElse(null)); // basically for asynchronous - } - } - - @Override - public String godHandBefore(ActionExecuteMeta executeMeta) { // you can override - return null; - } - - @Override - public String callbackBefore(ActionExecuteMeta executeMeta) { // you can override - return null; - } - - // ----------------------------------------------------- - // on Success - // ---------- - @Override - public String godHandSuccessMonologue(ActionExecuteMeta executeMeta) { - return null; - } - - // ----------------------------------------------------- - // on Failure - // ---------- - @Override - public String godHandExceptionMonologue(ActionExecuteMeta executeMeta) { // fixed process - return handleActionException(executeMeta); - } - - protected String handleActionException(ActionExecuteMeta executeMeta) { - final RuntimeException cause = executeMeta.getFailureCause(); - RuntimeException translated = null; - try { - translateException(cause); - } catch (final RuntimeException e) { - translated = e; - } - final RuntimeException handlingEx = translated != null ? translated : cause; - final String nextPath = handleApplicationException(executeMeta, handlingEx); - if (nextPath != null) { - return nextPath; - } - if (translated != null) { - throw translated; - } - return null; - } - - protected void translateException(RuntimeException cause) { - exceptionTranslator.translateException(cause); - } - - // ----------------------------------------------------- - // Finally - // ------- - @Override - public void callbackFinally(ActionExecuteMeta executeMeta) { // you can override - } - - @Override - public void godHandFinally(ActionExecuteMeta executeMeta) { // you can override - } - - @Override - public final void godHandActionEpilogue(ActionExecuteMeta executeMeta) { // fixed process - if (executeMeta.isForwardToJsp()) { - arrangeNoCacheResponseWhenJsp(executeMeta); - } - handleSqlCount(executeMeta); - clearCallbackContext(); - clearPreparedAccessContext(); - } - - protected void arrangeNoCacheResponseWhenJsp(ActionExecuteMeta executeMeta) { - responseManager.addNoCache(); - } - - // ----------------------------------------------------- - // Adjustment - // ---------- - @Override - protected String movedPermanently(String redirectUrl) { - // e.g. godHandBefore() needs dummy to stop execution - super.movedPermanently(redirectUrl); - return responseResolved(); - } - - /** - * Return as response resolved.
    - * Basically used in action callback or action execute.
    - * You should use this to stop execution in callback. - *
    -     * ... // resolve response by other way
    -     * return responseResolved(); // stop execution after here
    -     * 
    - * @return The dummy value that means resolved. (NotNull) - */ - protected String responseResolved() { - return ActionCallback.RESPONSE_RESOLVED_DUMMY_FORWARD; - } - - // =================================================================================== - // Access Context - // ============== - /** - * Arrange prepared access context for DBFlute, which is used for common columns setup.
    - * This is called by callback process so you should NOT call this directly in your action. - * @param executeMeta The meta of action execute. (NotNull) - */ - protected void arrangePreparedAccessContext(ActionExecuteMeta executeMeta) { // called by callback - final AccessContextArranger arranger = createAccessContextArranger(); - final AccessContextResource resource = createAccessContextResource(executeMeta); - final AccessContext accessContext = arranger.arrangePreparedAccessContext(resource); - PreparedAccessContext.setAccessContextOnThread(accessContext); - } - - /** - * Create the arranger of access context. - * @return The instance of arranger. (NotNull) - */ - protected AccessContextArranger createAccessContextArranger() { - return new AccessContextArranger() { - @Override - public AccessContext arrangePreparedAccessContext(final AccessContextResource resource) { - final AccessContext context = new AccessContext(); - // uses provider to synchronize it with transaction time - context.setAccessLocalDateTimeProvider(() -> { - return timeManager.getCurrentLocalDateTime(); - }); - // uses provider to synchronize it with login status in session - context.setAccessUserProvider(() -> { - return buildAccessUserTrace(resource); - }); - return context; - } - - private String buildAccessUserTrace(AccessContextResource resource) { - return getLoginInfo().map(info -> info.getUsername()).orElse("system"); - } - }; - } - - /** - * Create the resource of access context. - * @param executeMeta The meta of action execute. (NotNull) - * @return The new-created resource of access context. (NotNull) - */ - protected AccessContextResource createAccessContextResource(ActionExecuteMeta executeMeta) { - final Method method = executeMeta.getActionMethod(); - final String classTitle = DfTypeUtil.toClassTitle(method.getDeclaringClass()); - return new AccessContextResource(classTitle, method); - } - - /** - * Clear prepared access context.
    - * This is called by callback process so you should NOT call this directly in your action. - */ - protected void clearPreparedAccessContext() { // called by callback - PreparedAccessContext.clearAccessContextOnThread(); - } - - // =================================================================================== - // Callback Context - // ================ - /** - * Arrange callback context for DBFlute, which is used for several purpose.
    - * This is called by callback process so you should NOT call this directly in your action. - * @param executeMeta The meta of action execute. (NotNull) - */ - protected void arrangeCallbackContext(final ActionExecuteMeta executeMeta) { - final SqlFireHook sqlFireHook = createSqlFireHook(executeMeta); - CallbackContext.setSqlFireHookOnThread(sqlFireHook); - final SqlStringFilter filter = createSqlStringFilter(executeMeta); - CallbackContext.setSqlStringFilterOnThread(filter); - } - - /** - * Create the filter of SQL string for DBFlute. - * @param executeMeta The meta of action execute. (NotNull) - * @return The hook of SQL fire. (NullAllowed: if null, no hook) - */ - protected SqlFireHook createSqlFireHook(ActionExecuteMeta executeMeta) { - return newRomanticTraceableSqlFireHook(); - } - - protected RomanticTraceableSqlFireHook newRomanticTraceableSqlFireHook() { - return new RomanticTraceableSqlFireHook(); - } - - /** - * Create the filter of SQL string for DBFlute. - * @param executeMeta The meta of action execute. (NotNull) - * @return The filter of SQL string. (NullAllowed: if null, no filter) - */ - protected SqlStringFilter createSqlStringFilter(final ActionExecuteMeta executeMeta) { - final Method actionMethod = executeMeta.getActionMethod(); - return newRomanticTraceableSqlStringFilter(actionMethod, () -> buildSqlMarkingAdditionalInfo()); - } - - protected RomanticTraceableSqlStringFilter newRomanticTraceableSqlStringFilter(Method actionMethod, - TraceableSqlAdditionalInfoProvider additionalInfoProvider) { - return new RomanticTraceableSqlStringFilter(actionMethod, additionalInfoProvider); - } - - /** - * Build string for additional info of SQL marking. - * @return The string expression of additional info. (NullAllowed: if null, no additional info) - */ - protected String buildSqlMarkingAdditionalInfo() { - return "{" + getLoginInfo().map(info -> String.valueOf(info.isAdministrator())).orElse("*No login") + "}"; - // it doesn't contain user ID for SQL cache in DBMS - } - - /** - * Handle count of SQL execution in the request. - * @param executeMeta The meta of action execute. (NotNull) - */ - protected void handleSqlCount(final ActionExecuteMeta executeMeta) { - final CallbackContext context = CallbackContext.getCallbackContextOnThread(); - if (context == null) { - return; - } - final SqlStringFilter filter = context.getSqlStringFilter(); - if (filter == null || !(filter instanceof ExecutedSqlCounter)) { - return; - } - final ExecutedSqlCounter counter = ((ExecutedSqlCounter) filter); - final int limitCountOfSql = getLimitCountOfSql(executeMeta); - if (limitCountOfSql >= 0 && counter.getTotalCountOfSql() > limitCountOfSql) { - handleTooManySqlExecution(executeMeta, counter); - } - final String exp = counter.toLineDisp(); - requestManager.setAttribute(RequestManager.KEY_DBFLUTE_SQL_COUNT, exp); // logged by logging filter - } - - /** - * Handle too many SQL executions. - * @param executeMeta The meta of action execute. (NotNull) - * @param sqlCounter The counter object for SQL executions. (NotNull) - */ - protected void handleTooManySqlExecution(final ActionExecuteMeta executeMeta, final ExecutedSqlCounter sqlCounter) { - final String actionDisp = buildActionDisp(executeMeta); - LOG.warn("*Too many SQL executions: " + sqlCounter.getTotalCountOfSql() + " in " + actionDisp); - } - - protected String buildActionDisp(ActionExecuteMeta executeMeta) { - final Method method = executeMeta.getActionMethod(); - final Class declaringClass = method.getDeclaringClass(); - return declaringClass.getSimpleName() + "." + method.getName() + "()"; - } - - /** - * Get the limit count of SQL execution.
    - * You can override if you need. - * @param executeMeta The meta of action execute. (NotNull) - * @return The max count allowed for SQL executions. (MinusAllowed: if minus, no check) - */ - protected int getLimitCountOfSql(ActionExecuteMeta executeMeta) { - return 30; // as default - } - - /** - * Clear callback context.
    - * This is called by callback process so you should NOT call this directly in your action. - */ - protected void clearCallbackContext() { - CallbackContext.clearSqlStringFilterOnThread(); - CallbackContext.clearSqlFireHookOnThread(); - } - - // =================================================================================== - // Application Exception - // ===================== - /** - * Handle the application exception thrown by (basically) action execute.
    - * Though this is same as global-exceptions settings of Struts, - * There is more flexibility than the function so you can set it here.
    - * This is called by callback process so you should NOT call this directly in your action. - * @param executeMeta The meta of action execute. (NotNull) - * @param cause The exception thrown by (basically) action execute, might be translated. (NotNull) - * @return The forward path. (NullAllowed: if not null, it goes to the path) - */ - protected String handleApplicationException(ActionExecuteMeta executeMeta, RuntimeException cause) { // called by callback - final String forwardTo = doHandleApplicationException(executeMeta, cause); - if (forwardTo != null && executeMeta.isApiAction()) { - return dispatchApiApplicationException(executeMeta, cause); - } - return forwardTo; - } - - protected String doHandleApplicationException(ActionExecuteMeta executeMeta, RuntimeException cause) { - String forwardTo = null; - if (cause instanceof ApplicationBaseException) { - final ApplicationBaseException appEx = (ApplicationBaseException) cause; - if (appEx instanceof GetParameterNotFoundException) { - forwardTo = handleGetParameterNotFoundException((GetParameterNotFoundException) appEx); - } else if (appEx instanceof MessageKeyApplicationException) { - forwardTo = handleErrorsApplicationException((MessageKeyApplicationException) appEx); - } else { - forwardTo = handleSpecialApplicationException(appEx); - } - if (forwardTo == null) { - forwardTo = handleUnknownApplicationException(appEx); - } - reflectEmbeddedApplicationMessagesIfExists(appEx); // override existing messages if exists - } else { - if (cause instanceof EntityAlreadyDeletedException) { - forwardTo = handleEntityAlreadyDeletedException((EntityAlreadyDeletedException) cause); - } else if (cause instanceof EntityAlreadyUpdatedException) { - forwardTo = handleEntityAlreadyUpdatedException((EntityAlreadyUpdatedException) cause); - } else if (cause instanceof EntityAlreadyExistsException) { - forwardTo = handleEntityAlreadyExistsException((EntityAlreadyExistsException) cause); - } - } - if (forwardTo != null) { - showApplicationExceptionHandling(cause, forwardTo); - } - return forwardTo; - } - - protected void showApplicationExceptionHandling(RuntimeException cause, String forwardTo) { - if (LOG.isDebugEnabled()) { - // not show forwardTo because of forwarding log later - final StringBuilder sb = new StringBuilder(); - sb.append("...Handling application exception:"); - sb.append("\n_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/"); - sb.append("\n[Application Exception]"); - sb.append("\n").append(cause.getMessage()); - final ActionMessages errors = getErrors(); - if (errors != null) { - sb.append("\n").append(errors.toString()); - } - buildApplicationExceptionStackTrace(cause, sb); - sb.append("\n_/_/_/_/_/_/_/_/_/_/"); - LOG.debug(sb.toString()); - } - } - - protected void buildApplicationExceptionStackTrace(RuntimeException cause, StringBuilder sb) { - final StackTraceElement[] stackTrace = cause.getStackTrace(); - if (stackTrace == null) { // just in case - return; - } - int index = 0; - for (final StackTraceElement element : stackTrace) { - if (index > 10) { // not all because it's not error - break; - } - final String className = element.getClassName(); - final String fileName = element.getFileName(); // might be null - final int lineNumber = element.getLineNumber(); - final String methodName = element.getMethodName(); - sb.append("\n at ").append(className).append(".").append(methodName); - sb.append("(").append(fileName); - if (lineNumber >= 0) { - sb.append(":").append(lineNumber); - } - sb.append(")"); - ++index; - } - } - - protected void reflectEmbeddedApplicationMessagesIfExists(ApplicationBaseException appEx) { - final String errorsKey = appEx.getErrorKey(); - if (errorsKey != null) { - if (LOG.isDebugEnabled()) { - LOG.debug("...Saving embedded application message as action error: " + errorsKey); - } - saveErrors(errorsKey, appEx.getErrorArgs()); - } - } - - protected String dispatchApiApplicationException(ActionExecuteMeta executeMeta, RuntimeException cause) { - final ActionMessages errors = getErrors(); // might be null in minor case - final ApiResult result = apiManager.prepareApplicationExceptionResult(errors, executeMeta, cause); - apiManager.writeJsonResponse(result); - return apiManager.forwardToApiResolvedDummy(); - } - - // ----------------------------------------------------- - // DBFlute Entity - // -------------- - protected String handleEntityAlreadyDeletedException(EntityAlreadyDeletedException cause) { - saveErrors(getErrorsAppAlreadyDeletedKey()); - return getErrorMessageAlreadyDeletedJsp(); - } - - protected String getErrorsAppAlreadyDeletedKey() { - return FessMessages.ERRORS_APP_ALREADY_DELETED; - } - - protected String getErrorMessageAlreadyDeletedJsp() { - return getErrorMessageJsp(); // as default - } - - protected String handleEntityAlreadyUpdatedException(EntityAlreadyUpdatedException cause) { - saveErrors(getErrorsAppAlreadyUpdatedKey()); - return getErrorMessageAlreadyUpdatedJsp(); - } - - protected String getErrorsAppAlreadyUpdatedKey() { - return FessMessages.ERRORS_APP_ALREADY_UPDATED; - } - - protected String getErrorMessageAlreadyUpdatedJsp() { - return getErrorMessageJsp(); // as default - } - - protected String handleEntityAlreadyExistsException(EntityAlreadyExistsException cause) { - saveErrors(getErrorsAppAlreadyExistsKey()); - return getErrorMessageAlreadyExistsJsp(); - } - - protected String getErrorsAppAlreadyExistsKey() { - return FessMessages.ERRORS_APP_ALREADY_EXISTS; - } - - protected String getErrorMessageAlreadyExistsJsp() { - return getErrorMessageJsp(); // as default - } - - // ----------------------------------------------------- - // Get Parameter - // ------------- - protected String handleGetParameterNotFoundException(GetParameterNotFoundException appEx) { - saveErrors(getErrorsAppIllegalTransitionKey()); - return getErrorMessageJsp(); - } - - protected String getErrorsAppIllegalTransitionKey() { - return FessMessages.ERRORS_APP_ILLEGAL_TRANSITION; - } - - protected String getErrorMessageJsp() { - return path_Error_ErrorMessageJsp; - } - - // ----------------------------------------------------- - // Message Key - // ----------- - protected String handleErrorsApplicationException(MessageKeyApplicationException appEx) { - // no save here because of saved later - //saveErrors(appEx.getErrors()); - return getErrorMessageJsp(); - } - - // ----------------------------------------------------- - // Special - // ------- - protected String handleSpecialApplicationException(ApplicationBaseException appEx) { // you can override - return null; - } - - // ----------------------------------------------------- - // Unknown - // ------- - protected String handleUnknownApplicationException(ApplicationBaseException appEx) { - return null; // basically no way - } - - // =================================================================================== - // Assert Helper - // ============= - /** - * Assert the condition is true or it throws illegal transition forcedly.
    - * You can use this in your action process against strange request parameters. - * @param condition Your determination, true or false. (false: illegal transition) - */ - protected void assertTrueOrForcedIllegalTransition(boolean condition) { - if (!condition) { - throw new ForcedIllegalTransitionApplicationException(getErrorsAppIllegalTransitionKey()); - } - } - - /** - * Assert the condition is true or it throws 404 not found forcedly.
    - * You can use this in your action process against invalid URL parameters. - * @param condition Your determination, true or false. (false: 404 not found) - */ - protected void assertTrueOrForcedRequest404NotFound(boolean condition) { - if (!condition) { - final String msg = "from Forced 404 NotFound assertion"; // debug message - throw new ForcedRequest404NotFoundException(msg); - } - } - - // =================================================================================== - // Conversion Helper - // ================= - // ----------------------------------------------------- - // Collectors - // ---------- - protected Collector> toList() { - return Collectors.toList(); - } - - protected Collector> toMap(Function keyMapper, - Function valueMapper) { - return Collectors.toMap(keyMapper, valueMapper); - } - - // ----------------------------------------------------- - // String Date - // ----------- - protected String toStringDate(LocalDate localDate) { - return localDate != null ? doConvertToDisp(localDate) : null; - } - - protected String toStringDate(LocalDateTime localDateTime) { - return localDateTime != null ? doConvertToStringDate(localDateTime) : null; - } - - private String doConvertToDisp(LocalDate localDate) { - return new HandyDate(localDate, getConversionTimeZone()).toDisp(getStringDatePattern()); - } - - private String doConvertToStringDate(LocalDateTime localDateTime) { - return new HandyDate(localDateTime, getConversionTimeZone()).toDisp(getStringDatePattern()); - } - - protected String toStringDateTime(LocalDateTime localDateTime) { - return localDateTime != null ? doConvertToStringDateTime(localDateTime) : null; - } - - private String doConvertToStringDateTime(LocalDateTime localDateTime) { - return new HandyDate(localDateTime, getConversionTimeZone()).toDisp(getStringDateTimePattern()); - } - - // ----------------------------------------------------- - // Local Date - // ---------- - protected LocalDate toLocalDate(String dateExp) { - if (dateExp == null || dateExp.isEmpty()) { - return null; - } - final TimeZone userTimeZone = getConversionTimeZone(); - return new HandyDate(dateExp, userTimeZone).getLocalDate(); - } - - protected LocalDateTime toLocalDateTime(String dateTimeExp) { - if (dateTimeExp == null || dateTimeExp.isEmpty()) { - return null; - } - final TimeZone userTimeZone = getConversionTimeZone(); - return new HandyDate(dateTimeExp, userTimeZone).getLocalDateTime(); - } - - // ----------------------------------------------------- - // Conversion Resource - // ------------------- - protected String getStringDatePattern() { - return "yyyy/MM/dd"; - } - - protected String getStringDateTimePattern() { - return "yyyy/MM/dd HH:mm:ss"; - } - - protected TimeZone getConversionTimeZone() { - return requestManager.getUserTimeZone(); - } -} diff --git a/src/main/java/org/codelibs/fess/web/base/FessSearchAction.java b/src/main/java/org/codelibs/fess/web/base/FessSearchAction.java deleted file mode 100644 index ab3eb7474..000000000 --- a/src/main/java/org/codelibs/fess/web/base/FessSearchAction.java +++ /dev/null @@ -1,20 +0,0 @@ -/* - * Copyright 2009-2015 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.fess.web.base; - -public abstract class FessSearchAction extends FessBaseAction { - -} diff --git a/src/main/java/org/codelibs/sastruts/core/SSCConstants.java b/src/main/java/org/codelibs/sastruts/core/SSCConstants.java deleted file mode 100644 index 6e313bf9d..000000000 --- a/src/main/java/org/codelibs/sastruts/core/SSCConstants.java +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Copyright 2012 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core; - -import org.codelibs.core.CoreLibConstants; - -public class SSCConstants extends CoreLibConstants { - - public static final String USER_INFO = "LoginInfo"; - - public static final String RETURN_PATH = "ReturnPath"; - - protected SSCConstants() { - } -} diff --git a/src/main/java/org/codelibs/sastruts/core/action/AbstractLoginAction.java b/src/main/java/org/codelibs/sastruts/core/action/AbstractLoginAction.java deleted file mode 100644 index 0c84a7899..000000000 --- a/src/main/java/org/codelibs/sastruts/core/action/AbstractLoginAction.java +++ /dev/null @@ -1,178 +0,0 @@ -/* - * Copyright 2012 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core.action; - -import java.io.IOException; -import java.io.Serializable; -import java.util.Enumeration; -import java.util.HashMap; -import java.util.Map; - -import javax.annotation.Resource; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; -import javax.servlet.http.HttpSession; - -import org.apache.struts.Globals; -import org.codelibs.core.crypto.CachedCipher; -import org.codelibs.sastruts.core.SSCConstants; -import org.codelibs.sastruts.core.entity.UserInfo; -import org.codelibs.sastruts.core.exception.LoginException; -import org.codelibs.sastruts.core.form.AbstractLoginForm; -import org.codelibs.sastruts.core.util.ActivityUtil; -import org.seasar.framework.log.Logger; -import org.seasar.framework.util.StringUtil; -import org.seasar.struts.util.ResponseUtil; - -public abstract class AbstractLoginAction implements Serializable { - private static final Logger logger = Logger.getLogger(AbstractLoginAction.class); - - private static final long serialVersionUID = 1L; - - @Resource - protected HttpServletRequest request; - - @Resource - protected CachedCipher authCipher; - - protected String doIndex(final AbstractLoginForm form) { - HttpSession session = request.getSession(false); - // check login session - final Object obj = session == null ? null : session.getAttribute(SSCConstants.USER_INFO); - if (obj instanceof UserInfo) { - redirect(getAuthRootPath()); - return null; - } - - String params = null; - if ("forbidden".equals(form.type)) { - // invalid user - if (logger.isInfoEnabled()) { - logger.log("ISSC0001", new Object[] { request.getRemoteUser() }); - } - if (session != null) { - session = invalidateSession(session); - } - params = "msgs=error.login_error"; - } - - if (session == null) { - session = request.getSession(); - } - - String path; - if (StringUtil.isNotBlank(form.returnPath)) { - final String value = authCipher.decryptoText(form.returnPath); - final int idx = value.indexOf('|'); - if (idx >= 0) { - path = value.substring(idx + 1); - session.setAttribute(SSCConstants.RETURN_PATH, path); - } else { - // invalid returnPathName - session.removeAttribute(SSCConstants.RETURN_PATH); - } - } else { - session.removeAttribute(SSCConstants.RETURN_PATH); - } - - return getLoginPath(params); - } - - protected String doLogin(final AbstractLoginForm form) { - final HttpSession oldSession = request.getSession(); - - final HttpSession session = invalidateSession(oldSession); - - session.removeAttribute(Globals.MESSAGE_KEY); - - // create user info - final UserInfo loginInfo = new UserInfo(); - loginInfo.setUsername(request.getRemoteUser()); - session.setAttribute(SSCConstants.USER_INFO, loginInfo); - - String returnPath = (String) session.getAttribute(SSCConstants.RETURN_PATH); - if (returnPath != null) { - session.removeAttribute(SSCConstants.RETURN_PATH); - } else { - // admin page - returnPath = getAuthRootPath(); - } - - ActivityUtil.login(loginInfo.getUsername(), request); - - redirect(returnPath); - - return null; - } - - private HttpSession invalidateSession(final HttpSession oldSession) { - final Map sessionObjMap = new HashMap(); - @SuppressWarnings("unchecked") - final Enumeration e = oldSession.getAttributeNames(); - while (e.hasMoreElements()) { - final String name = e.nextElement(); - sessionObjMap.put(name, oldSession.getAttribute(name)); - } - oldSession.invalidate(); - - final HttpSession session = request.getSession(); - for (final Map.Entry entry : sessionObjMap.entrySet()) { - session.setAttribute(entry.getKey(), entry.getValue()); - } - return session; - } - - protected String doLogout(final AbstractLoginForm form) { - ActivityUtil.login(request.getRemoteUser(), request); - - final HttpSession session = request.getSession(); - session.invalidate(); - - return getLoginPath(null); - } - - protected String getDefaultPath() { - return "/index?redirect=true"; - } - - protected String getLoginPath(final String params) { - final StringBuilder buf = new StringBuilder(); - buf.append("login?"); - if (params != null && params.length() > 0) { - buf.append(params).append('&'); - } - buf.append("redirect=true"); - return buf.toString(); - } - - protected String getAuthRootPath() { - final String contextPath = request.getContextPath(); - if (StringUtil.isEmpty(contextPath) || "/".equals(contextPath)) { - return "/admin/"; - } else { - return contextPath + "/admin/"; - } - } - - protected void redirect(final String returnPath) { - final HttpServletResponse response = ResponseUtil.getResponse(); - try { - response.sendRedirect(response.encodeURL(returnPath)); - } catch (final IOException e) { - throw new LoginException("ESSC0002", new Object[] { returnPath }, e); - } - } -} diff --git a/src/main/java/org/codelibs/sastruts/core/exception/LoginException.java b/src/main/java/org/codelibs/sastruts/core/exception/LoginException.java deleted file mode 100644 index f7bb08051..000000000 --- a/src/main/java/org/codelibs/sastruts/core/exception/LoginException.java +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright 2012 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core.exception; - -/** - * @author shinsuke - * - */ -public class LoginException extends SSCRuntimeException { - - /** - * - */ - private static final long serialVersionUID = 1L; - - public LoginException(final String messageCode, final Object[] args, final Throwable cause) { - super(messageCode, args, cause); - } - - public LoginException(final String messageCode, final Object[] args) { - super(messageCode, args); - } - - public LoginException(final String messageCode, final Throwable cause) { - super(messageCode, cause); - } - - public LoginException(final String messageCode) { - super(messageCode); - } - -} diff --git a/src/main/java/org/codelibs/sastruts/core/exception/SSCActionMessagesException.java b/src/main/java/org/codelibs/sastruts/core/exception/SSCActionMessagesException.java deleted file mode 100644 index 4c2bf4323..000000000 --- a/src/main/java/org/codelibs/sastruts/core/exception/SSCActionMessagesException.java +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Copyright 2004-2010 the Seasar Foundation and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core.exception; - -import org.seasar.struts.exception.ActionMessagesException; - -/** - * SSCActionMessagesException allows you to pass a root cause. - * - * @author shinsuke - * - */ -public class SSCActionMessagesException extends ActionMessagesException { - - /** - * A default serial version uid. - */ - private static final long serialVersionUID = 1L; - - public SSCActionMessagesException(final String key, final boolean resource) { - super(key, resource); - } - - public SSCActionMessagesException(final String key, final Object... values) { - super(key, values); - } - - public SSCActionMessagesException(final Throwable cause, final String key, final boolean resource) { - super(key, resource); - initCause(cause); - } - - public SSCActionMessagesException(final Throwable cause, final String key, final Object... values) { - super(key, values); - initCause(cause); - } - -} diff --git a/src/main/java/org/codelibs/sastruts/core/exception/SSCRuntimeException.java b/src/main/java/org/codelibs/sastruts/core/exception/SSCRuntimeException.java deleted file mode 100644 index 4e25dd106..000000000 --- a/src/main/java/org/codelibs/sastruts/core/exception/SSCRuntimeException.java +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright 2012 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core.exception; - -import org.codelibs.core.exception.ClRuntimeException; - -/** - * Base exception class for SAStruts Core. - * - * @author shinsuke - * - */ -public class SSCRuntimeException extends ClRuntimeException { - - private static final long serialVersionUID = 1L; - - public SSCRuntimeException(final String messageCode, final Object[] args, final Throwable cause) { - super(messageCode, args, cause); - } - - public SSCRuntimeException(final String messageCode, final Object[] args) { - super(messageCode, args); - } - - public SSCRuntimeException(final String messageCode, final Throwable cause) { - super(messageCode, new Object[] {}, cause); - } - - public SSCRuntimeException(final String messageCode) { - super(messageCode); - } -} diff --git a/src/main/java/org/codelibs/sastruts/core/form/AbstractLoginForm.java b/src/main/java/org/codelibs/sastruts/core/form/AbstractLoginForm.java deleted file mode 100644 index b029d2857..000000000 --- a/src/main/java/org/codelibs/sastruts/core/form/AbstractLoginForm.java +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright 2012 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core.form; - -import java.io.Serializable; - -/** - * @author shinsuke - * - */ -public abstract class AbstractLoginForm implements Serializable { - - private static final long serialVersionUID = 1L; - - public String returnPath; - - public String type; - - public String[] msgs; -} diff --git a/src/main/java/org/codelibs/sastruts/core/interceptor/TokenInterceptor.java b/src/main/java/org/codelibs/sastruts/core/interceptor/TokenInterceptor.java deleted file mode 100644 index 4c5a75340..000000000 --- a/src/main/java/org/codelibs/sastruts/core/interceptor/TokenInterceptor.java +++ /dev/null @@ -1,61 +0,0 @@ -/* - * Copyright 2012 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core.interceptor; - -import javax.servlet.http.HttpServletRequest; - -import org.aopalliance.intercept.MethodInvocation; -import org.apache.struts.util.TokenProcessor; -import org.codelibs.sastruts.core.annotation.Token; -import org.seasar.framework.aop.interceptors.AbstractInterceptor; -import org.seasar.struts.exception.ActionMessagesException; -import org.seasar.struts.util.RequestUtil; - -/** - * @author shinsuke - * - */ -public class TokenInterceptor extends AbstractInterceptor { - - /** - * - */ - private static final long serialVersionUID = 1L; - - /* - * (non-Javadoc) - * - * @see - * org.aopalliance.intercept.MethodInterceptor#invoke(org.aopalliance.intercept - * .MethodInvocation) - */ - @Override - public Object invoke(final MethodInvocation invocation) throws Throwable { - final Token token = invocation.getMethod().getAnnotation(Token.class); - if (token != null) { - final TokenProcessor processor = TokenProcessor.getInstance(); - final HttpServletRequest request = RequestUtil.getRequest(); - if (token.save()) { - processor.saveToken(request); - } else if (token.validate() && !processor.isTokenValid(request, !token.keep())) { - processor.resetToken(request); - throw new ActionMessagesException("errors.token", new Object[0]); - } - } - - return invocation.proceed(); - } -} diff --git a/src/main/java/org/codelibs/sastruts/core/interceptor/UserInfoInterceptor.java b/src/main/java/org/codelibs/sastruts/core/interceptor/UserInfoInterceptor.java deleted file mode 100644 index 428693db9..000000000 --- a/src/main/java/org/codelibs/sastruts/core/interceptor/UserInfoInterceptor.java +++ /dev/null @@ -1,83 +0,0 @@ -/* - * Copyright 2012 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core.interceptor; - -import java.lang.reflect.Field; -import java.lang.reflect.Method; - -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpSession; - -import org.aopalliance.intercept.MethodInvocation; -import org.codelibs.sastruts.core.SSCConstants; -import org.codelibs.sastruts.core.annotation.User; -import org.seasar.framework.aop.S2MethodInvocation; -import org.seasar.framework.aop.interceptors.AbstractInterceptor; -import org.seasar.framework.beans.BeanDesc; -import org.seasar.framework.beans.PropertyDesc; -import org.seasar.framework.beans.factory.BeanDescFactory; -import org.seasar.framework.util.FieldUtil; -import org.seasar.struts.util.RequestUtil; - -/** - * - * @author shinsuke - * - */ -public class UserInfoInterceptor extends AbstractInterceptor { - - private static final long serialVersionUID = 1L; - - /* - * (non-Javadoc) - * - * @see - * org.aopalliance.intercept.MethodInterceptor#invoke(org.aopalliance.intercept - * .MethodInvocation) - */ - @Override - public Object invoke(final MethodInvocation invocation) throws Throwable { - final HttpServletRequest request = RequestUtil.getRequest(); - final HttpSession session = request.getSession(false); - if (session == null) { - return invocation.proceed(); - } - final Object userInfoObj = session.getAttribute(SSCConstants.USER_INFO); - if (userInfoObj == null) { - return invocation.proceed(); - } - - final Object target = invocation.getThis(); - final Class clazz = ((S2MethodInvocation) invocation).getTargetClass(); - final BeanDesc beanDesc = BeanDescFactory.getBeanDesc(clazz); - final int size = beanDesc.getPropertyDescSize(); - for (int i = 0; i < size; i++) { - final PropertyDesc propertyDesc = beanDesc.getPropertyDesc(i); - final Method readMethod = propertyDesc.getReadMethod(); - if (readMethod != null && readMethod.isAnnotationPresent(User.class)) { - propertyDesc.setValue(target, userInfoObj); - break; - } - final Field field = propertyDesc.getField(); - if (field != null && field.isAnnotationPresent(User.class)) { - FieldUtil.set(field, target, userInfoObj); - break; - } - } - return invocation.proceed(); - } - -} diff --git a/src/main/java/org/codelibs/sastruts/core/servlet/SSCActionServlet.java b/src/main/java/org/codelibs/sastruts/core/servlet/SSCActionServlet.java deleted file mode 100644 index 7ccb763c5..000000000 --- a/src/main/java/org/codelibs/sastruts/core/servlet/SSCActionServlet.java +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright 2012 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core.servlet; - -import java.io.IOException; - -import javax.servlet.ServletException; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; - -import org.apache.struts.action.ActionServlet; - -/** - * PUT and DELETE supported ActionServlet. - * - * @author shinsuke - * - */ -public class SSCActionServlet extends ActionServlet { - - private static final long serialVersionUID = 1L; - - @Override - protected void doDelete(final HttpServletRequest request, final HttpServletResponse response) throws ServletException, IOException { - process(request, response); - } - - @Override - protected void doPut(final HttpServletRequest request, final HttpServletResponse response) throws ServletException, IOException { - process(request, response); - } - -} diff --git a/src/main/java/org/codelibs/sastruts/core/struts/action/SSCRequestProcessor.java b/src/main/java/org/codelibs/sastruts/core/struts/action/SSCRequestProcessor.java deleted file mode 100644 index 758f199a3..000000000 --- a/src/main/java/org/codelibs/sastruts/core/struts/action/SSCRequestProcessor.java +++ /dev/null @@ -1,82 +0,0 @@ -/* - * Copyright 2004-2010 the Seasar Foundation and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core.struts.action; - -import javax.servlet.ServletException; - -import org.apache.struts.action.ActionServlet; -import org.apache.struts.config.ModuleConfig; -import org.seasar.framework.util.ArrayUtil; -import org.seasar.struts.action.S2RequestProcessor; - -/** - * @author shinsuke - * - */ -public class SSCRequestProcessor extends S2RequestProcessor { - protected static final char NESTED_DELIM = '.'; - - protected static final char INDEXED_DELIM = '['; - - protected static final char INDEXED_DELIM2 = ']'; - - protected int maxReqParamSize = 100; - - @Override - public void init(ActionServlet servlet, ModuleConfig moduleConfig) throws ServletException { - super.init(servlet, moduleConfig); - final Object value = servlet.getServletContext().getAttribute("sastruts.MAX_REQUEST_PARAMETER_SIZE"); - if (value != null) { - maxReqParamSize = Integer.parseInt(value.toString()); - } - } - - @Override - protected IndexParsedResult parseIndex(String name) { - final IndexParsedResult result = new SSCIndexParsedResult(); - while (true) { - final int index = name.indexOf(INDEXED_DELIM2); - if (index < 0) { - throw new IllegalArgumentException(INDEXED_DELIM2 + " is not found in " + name); - } - final int size = Integer.valueOf(name.substring(0, index)).intValue(); - if (size > maxReqParamSize) { - throw new IllegalArgumentException("The array size exceeds " + maxReqParamSize); - } - result.indexes = ArrayUtil.add(result.indexes, size); - name = name.substring(index + 1); - if (name.length() == 0) { - break; - } else if (name.charAt(0) == INDEXED_DELIM) { - name = name.substring(1); - } else if (name.charAt(0) == NESTED_DELIM) { - name = name.substring(1); - break; - } else { - throw new IllegalArgumentException(name); - } - } - result.name = name; - return result; - } - - /** - * - */ - protected static class SSCIndexParsedResult extends IndexParsedResult { - } - -} diff --git a/src/main/java/org/codelibs/sastruts/core/upload/SSCMultipartRequestHandler.java b/src/main/java/org/codelibs/sastruts/core/upload/SSCMultipartRequestHandler.java deleted file mode 100644 index e02b8055c..000000000 --- a/src/main/java/org/codelibs/sastruts/core/upload/SSCMultipartRequestHandler.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * Copyright 2012 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core.upload; - -import java.io.File; -import java.io.InputStream; -import java.util.Hashtable; -import java.util.Iterator; -import java.util.List; - -import javax.servlet.ServletException; -import javax.servlet.http.HttpServletRequest; - -import org.apache.commons.fileupload.FileItem; -import org.apache.commons.fileupload.FileUploadBase.SizeLimitExceededException; -import org.apache.commons.fileupload.FileUploadException; -import org.apache.commons.fileupload.disk.DiskFileItemFactory; -import org.apache.commons.fileupload.servlet.FileCleanerCleanup; -import org.apache.commons.fileupload.servlet.ServletFileUpload; -import org.apache.commons.io.FileCleaningTracker; -import org.apache.struts.Globals; -import org.apache.struts.config.ModuleConfig; -import org.apache.struts.upload.MultipartRequestHandler; -import org.seasar.struts.upload.S2MultipartRequestHandler; -import org.seasar.struts.util.ServletContextUtil; - -/** - * This class supports a multipart request handler to support commons-fileupload - * 1.2.2. - * - * @author shinsuke - * - */ -public class SSCMultipartRequestHandler extends S2MultipartRequestHandler { - - @SuppressWarnings("rawtypes") - @Override - public void handleRequest(final HttpServletRequest request) throws ServletException { - final ModuleConfig ac = (ModuleConfig) request.getAttribute(Globals.MODULE_KEY); - final FileCleaningTracker fileCleaningTracker = FileCleanerCleanup.getFileCleaningTracker(ServletContextUtil.getServletContext()); - final DiskFileItemFactory fileItemFactory = new DiskFileItemFactory((int) getSizeThreshold(ac), new File(getRepositoryPath(ac))); - request.setAttribute("fileItemFactory", fileItemFactory); - fileItemFactory.setFileCleaningTracker(fileCleaningTracker); - final ServletFileUpload upload = new ServletFileUpload(fileItemFactory); - upload.setHeaderEncoding(request.getCharacterEncoding()); - upload.setSizeMax(getSizeMax(ac)); - elementsText = new Hashtable(); - elementsFile = new Hashtable(); - elementsAll = new Hashtable(); - List items = null; - try { - items = upload.parseRequest(request); - } catch (final SizeLimitExceededException e) { - request.setAttribute(MultipartRequestHandler.ATTRIBUTE_MAX_LENGTH_EXCEEDED, Boolean.TRUE); - request.setAttribute(SIZE_EXCEPTION_KEY, e); - try { - final InputStream is = request.getInputStream(); - try { - final byte[] buf = new byte[1024]; - while ((is.read(buf)) != -1) { // NOPMD - } - } catch (final Exception ignore) {} finally { - try { - is.close(); - } catch (final Exception ignore) {} - } - } catch (final Exception ignore) {} - return; - } catch (final FileUploadException e) { - log.error("Failed to parse multipart request", e); - throw new ServletException(e); - } - - // Partition the items into form fields and files. - final Iterator iter = items.iterator(); - while (iter.hasNext()) { - final FileItem item = (FileItem) iter.next(); - - if (item.isFormField()) { - addTextParameter(request, item); - } else { - addFileParameter(item); - } - } - } -} diff --git a/src/main/java/org/codelibs/sastruts/core/util/ActionMessagesUtil.java b/src/main/java/org/codelibs/sastruts/core/util/ActionMessagesUtil.java deleted file mode 100644 index b005b890f..000000000 --- a/src/main/java/org/codelibs/sastruts/core/util/ActionMessagesUtil.java +++ /dev/null @@ -1,297 +0,0 @@ -/* - * Copyright 2012 the CodeLibs Project and the Others. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, - * either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ -package org.codelibs.sastruts.core.util; - -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpSession; - -import org.apache.struts.Globals; -import org.apache.struts.action.ActionMessage; -import org.apache.struts.action.ActionMessages; - -/** - * ActionMessages Utility. - * - * @author shinsuke - * - */ -public final class ActionMessagesUtil { - - private ActionMessagesUtil() { - } - - /** - * Add a message by a message key to a request. - * - * @param request - * @param key - */ - public static void addMessage(final HttpServletRequest request, final String key) { - addMessage(request, key, new Object[0]); - } - - /** - * Add a message by a message key to a request. - * - * @param request - * @param key - * @param values - */ - public static void addMessage(final HttpServletRequest request, final String key, final Object... values) { - final ActionMessages msgs = new ActionMessages(); - msgs.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(key, values)); - addMessages(request, msgs); - } - - /** - * Add a message by a message key to a session. - * - * @param session - * @param key - */ - public static void addMessage(final HttpSession session, final String key) { - addMessage(session, key, new Object[0]); - } - - /** - * Add a message by a message key to a session. - * - * @param session - * @param key - * @param values - */ - public static void addMessage(final HttpSession session, final String key, final Object... values) { - final ActionMessages msgs = new ActionMessages(); - msgs.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(key, values)); - addMessages(session, msgs); - } - - /** - * Add an error message by a message key to a request. - * - * @param request - * @param key - */ - public static void addError(final HttpServletRequest request, final String key) { - addError(request, key, new Object[0]); - } - - /** - * Add an error message by a message key to a request. - * - * @param request - * @param key - * @param values - */ - public static void addError(final HttpServletRequest request, final String key, final Object... values) { - final ActionMessages msgs = new ActionMessages(); - msgs.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(key, values)); - addErrors(request, msgs); - } - - /** - * Add an error message by a message key to a session. - * - * @param session - * @param key - */ - public static void addError(final HttpSession session, final String key) { - addError(session, key, new Object[0]); - } - - /** - * Add an error message by a message key to a session. - * - * @param session - * @param key - * @param values - */ - public static void addError(final HttpSession session, final String key, final Object... values) { - final ActionMessages msgs = new ActionMessages(); - msgs.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(key, values)); - addErrors(session, msgs); - } - - // From SAStruts - - /** - * エラーメッセージをリクエストに保存します。 - * - * @param request - * リクエスト - * @param errors - * エラーメッセージ - * - */ - public static void saveErrors(final HttpServletRequest request, final ActionMessages errors) { - if (errors == null || errors.isEmpty()) { - request.removeAttribute(Globals.ERROR_KEY); - return; - } - request.setAttribute(Globals.ERROR_KEY, errors); - } - - /** - * エラーメッセージをセッションに保存します。 - * - * @param session - * セッション - * @param errors - * エラーメッセージ - * - */ - public static void saveErrors(final HttpSession session, final ActionMessages errors) { - if (errors == null || errors.isEmpty()) { - session.removeAttribute(Globals.ERROR_KEY); - return; - } - session.setAttribute(Globals.ERROR_KEY, errors); - } - - /** - * メッセージをリクエストに保存します。 - * - * @param request - * リクエスト - * @param messages - * メッセージ - * - */ - public static void saveMessages(final HttpServletRequest request, final ActionMessages messages) { - if (messages == null || messages.isEmpty()) { - request.removeAttribute(Globals.MESSAGE_KEY); - return; - } - request.setAttribute(Globals.MESSAGE_KEY, messages); - } - - /** - * メッセージをセッションに保存します。 - * - * @param session - * セッション - * @param messages - * メッセージ - * - */ - public static void saveMessages(final HttpSession session, final ActionMessages messages) { - if (messages == null || messages.isEmpty()) { - session.removeAttribute(Globals.MESSAGE_KEY); - return; - } - session.setAttribute(Globals.MESSAGE_KEY, messages); - } - - /** - * エラーメッセージをリクエストに追加します。 - * - * @param request - * リクエスト - * @param errors - * エラーメッセージ - * - */ - public static void addErrors(final HttpServletRequest request, final ActionMessages errors) { - if (errors == null) { - return; - } - ActionMessages requestErrors = (ActionMessages) request.getAttribute(Globals.ERROR_KEY); - if (requestErrors == null) { - requestErrors = new ActionMessages(); - } - requestErrors.add(errors); - saveErrors(request, requestErrors); - } - - /** - * エラーメッセージをセッションに追加します。 - * - * @param session - * セッション - * @param errors - * エラーメッセージ - * - */ - public static void addErrors(final HttpSession session, final ActionMessages errors) { - if (errors == null) { - return; - } - ActionMessages sessionErrors = (ActionMessages) session.getAttribute(Globals.ERROR_KEY); - if (sessionErrors == null) { - sessionErrors = new ActionMessages(); - } - sessionErrors.add(errors); - saveErrors(session, sessionErrors); - } - - /** - * エラーメッセージがあるかどうかを返します。 - * - * @param request - * リクエスト - * @return エラーメッセージがあるかどうか - * @since 1.0.4 - */ - public static boolean hasErrors(final HttpServletRequest request) { - final ActionMessages errors = (ActionMessages) request.getAttribute(Globals.ERROR_KEY); - if (errors != null && !errors.isEmpty()) { - return true; - } - return false; - } - - /** - * メッセージをリクエストに追加します。 - * - * @param request - * リクエスト - * @param messages - * メッセージ - * - */ - public static void addMessages(final HttpServletRequest request, final ActionMessages messages) { - if (messages == null) { - return; - } - ActionMessages requestMessages = (ActionMessages) request.getAttribute(Globals.MESSAGE_KEY); - if (requestMessages == null) { - requestMessages = new ActionMessages(); - } - requestMessages.add(messages); - saveMessages(request, requestMessages); - } - - /** - * メッセージをセッションに追加します。 - * - * @param session - * セッション - * @param messages - * メッセージ - * - */ - public static void addMessages(final HttpSession session, final ActionMessages messages) { - if (messages == null) { - return; - } - ActionMessages sessionMessages = (ActionMessages) session.getAttribute(Globals.MESSAGE_KEY); - if (sessionMessages == null) { - sessionMessages = new ActionMessages(); - } - sessionMessages.add(messages); - saveMessages(session, sessionMessages); - } -} diff --git a/src/main/resources/app.dicon b/src/main/resources/app.xml similarity index 52% rename from src/main/resources/app.dicon rename to src/main/resources/app.xml index 9f980f0bb..05731e342 100644 --- a/src/main/resources/app.dicon +++ b/src/main/resources/app.xml @@ -1,21 +1,17 @@ - + - - - - + + - - - - + + + + - - - - + + @@ -29,57 +25,57 @@ 1 - new String[] {"label"} - new String[] { - "lastModified:[NOW/DAY-1DAY TO NOW]", - "lastModified:[NOW/DAY-7DAYS TO NOW]", - "lastModified:[NOW/DAY-1MONTH TO NOW]", - "lastModified:[NOW/DAY-1YEAR TO NOW]", - "contentLength:[0 TO 9999]", - "contentLength:[10000 TO 99999]", - "contentLength:[100000 TO 499999]", - "contentLength:[500000 TO 999999]", - "contentLength:[1000000 TO *]", - "filetype_s:html", - "filetype_s:word", - "filetype_s:excel", - "filetype_s:powerpoint", - "filetype_s:pdf", - "filetype_s:others" - } + ["label"] + [ + "last_modified:[now/d-1d TO now]", + "last_modified:[now/d-7d TO now]", + "last_modified:[now/d-1M TO now]", + "last_modified:[now/d-1y TO now]", + "content_length:[0 TO 9999]", + "content_length:[10000 TO 99999]", + "content_length:[100000 TO 499999]", + "content_length:[500000 TO 999999]", + "content_length:[1000000 TO *]", + "filetype:html", + "filetype:word", + "filetype:excel", + "filetype:powerpoint", + "filetype:pdf", + "filetype:others" + ] - + "zh" "cjk" - - + + "zh_CN" "cjk" - - + + "zh_TW" "cjk" - - + + "ko" "cjk" - - - new String[]{"id", "docId", "score", "boost", + + + (String[])["id", "docId", "score", "boost", "contentLength", "host", "site", "lastModified", "mimetype", "filetype_s", - "created", "title", "digest", "url", "urlLink", "contentDescription"} - - + "created", "title", "digest", "url", "urlLink", "contentDescription"] + + "title" - - + + "content" - - + + "label" "0.0" - + - + "label.facet_lastModified_title" - + "label.facet_lastModified_1day" - "lastModified:[NOW/DAY-1DAY TO NOW]" - - + "last_modified:[now/d-1d TO now]" + + "label.facet_lastModified_1week" - "lastModified:[NOW/DAY-7DAYS TO NOW]" - - + "last_modified:[now/d-7d TO now]" + + "label.facet_lastModified_1month" - "lastModified:[NOW/DAY-1MONTH TO NOW]" - - + "last_modified:[now/d-1M TO now]" + + "label.facet_lastModified_1year" - "lastModified:[NOW/DAY-1YEAR TO NOW]" - + "last_modified:[now/d-1y TO now]" + - - + + "label.facet_contentLength_title" - + "label.facet_contentLength_10k" - "contentLength:[0 TO 9999]" - - + "content_length:[0 TO 9999]" + + "label.facet_contentLength_10kto100k" - "contentLength:[10000 TO 99999]" - - + "content_length:[10000 TO 99999]" + + "label.facet_contentLength_100kto500k" - "contentLength:[100000 TO 499999]" - - + "content_length:[100000 TO 499999]" + + "label.facet_contentLength_500kto1m" - "contentLength:[500000 TO 999999]" - - + "content_length:[500000 TO 999999]" + + "label.facet_contentLength_1m" - "contentLength:[1000000 TO *]" - + "content_length:[1000000 TO *]" + - - + + "label.facet_filetype_title" - + "label.facet_filetype_html" - "filetype_s:html" - - + "filetype:html" + + "label.facet_filetype_word" - "filetype_s:word" - - + "filetype:word" + + "label.facet_filetype_excel" - "filetype_s:excel" - - + "filetype:excel" + + "label.facet_filetype_powerpoint" - "filetype_s:powerpoint" - - + "filetype:powerpoint" + + "label.facet_filetype_pdf" - "filetype_s:pdf" - - + "filetype:pdf" + + "label.facet_filetype_others" - "filetype_s:others" - + "filetype:others" + - + - - - - - "solrServer1" - "http://localhost:8080/manager/text/" - "/solr" - "manager" - "manager" - - - - - @java.util.regex.Pattern@compile(".*[a-zA-Z0-9_]+:.*") + java.util.regex.Pattern.compile(".*[a-zA-Z0-9_]+:.*") @@ -252,53 +235,95 @@ - "Mozilla/5.0 (compatible; Fess/" + @org.codelibs.fess.Constants@FESS_VERSION + "; +http://fess.codelibs.org/bot.html)" + "Mozilla/5.0 (compatible; Fess/" + org.codelibs.fess.Constants.FESS_VERSION + "; +http://fess.codelibs.org/bot.html)" - - @javax.naming.Context@INITIAL_CONTEXT_FACTORY + + "java.naming.factory.initial" "com.sun.jndi.ldap.LdapCtxFactory" - - - @javax.naming.directory.DirContext@PROVIDER_URL + + + "java.naming.provider.url" "ldap://[host]:[port]" - - - @javax.naming.directory.DirContext@SECURITY_PRINCIPAL + + + "java.naming.security.principal" "[loginId]@[domain]" - - - @javax.naming.directory.DirContext@SECURITY_CREDENTIALS + + + "java.naming.security.credentials" "password" - - + + "com.sun.jndi.ldap.connect.timeout" "10000" - - + + "com.sun.jndi.ldap.connect.pool" "true" - - + + "com.sun.jndi.connect.pool.timeout" "30000" - - + + "com.sun.jndi.connect.pool.debug" "all" - + - + adProperties - + - - + + + + + + + + diff --git a/src/main/resources/convention.dicon b/src/main/resources/convention.dicon deleted file mode 100644 index 3542cbb1f..000000000 --- a/src/main/resources/convention.dicon +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - "org.codelibs.fess" - - - "org.codelibs.sastruts.core" - - - - diff --git a/src/main/resources/creator.dicon b/src/main/resources/creator.dicon deleted file mode 100644 index c4c5f4b5f..000000000 --- a/src/main/resources/creator.dicon +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - - - - - diff --git a/src/main/resources/customizer.dicon b/src/main/resources/customizer.dicon deleted file mode 100644 index f9704f3da..000000000 --- a/src/main/resources/customizer.dicon +++ /dev/null @@ -1,46 +0,0 @@ - - - - - - - - "aop.traceInterceptor" - - - "actionMessagesThrowsInterceptor" - - - "tokenInterceptor" - - - - - - - - - - - - - - "aop.traceInterceptor" - - - - - - - - - - - - diff --git a/src/main/resources/dbflute.dicon b/src/main/resources/dbflute.dicon deleted file mode 100644 index e43a5b0c3..000000000 --- a/src/main/resources/dbflute.dicon +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - diff --git a/src/main/resources/device/README b/src/main/resources/device/README deleted file mode 100644 index 19ab102b4..000000000 --- a/src/main/resources/device/README +++ /dev/null @@ -1,8 +0,0 @@ -Please put profile data into this directory. -You can get them from http://valueengine.jp/ -and then rename files: - - ProfileData_YYYY-MM-DD.csv -> ProfileData.csv - UserAgent_YYYY-MM-DD.csv -> UserAgent.csv - DisplayInfo_YYYY-MM-DD.csv -> DisplayInfo.csv - diff --git a/src/main/resources/env.txt b/src/main/resources/env.txt deleted file mode 100644 index 8954caacc..000000000 --- a/src/main/resources/env.txt +++ /dev/null @@ -1 +0,0 @@ -product diff --git a/src/main/resources/esclient.dicon b/src/main/resources/esclient.dicon deleted file mode 100644 index c66c67a24..000000000 --- a/src/main/resources/esclient.dicon +++ /dev/null @@ -1,118 +0,0 @@ - - - - - - #{"http.cors.enabled" : "true"} - - - "fess/doc" - - - "fess" - "ja/mapping.txt" - - - "fess" - "ja/synonym.txt" - - - "fess" - "ja/kuromoji.txt" - - - ".fess_config/boost_document_rule" - - - ".fess_config/click_log" - - - ".fess_config/crawling_session" - - - ".fess_config/crawling_session_info" - - - ".fess_config/data_config" - - - ".fess_config/data_config_to_label" - - - ".fess_config/data_config_to_role" - - - ".fess_config/failure_url" - - - ".fess_config/favorite_log" - - - ".fess_config/file_authentication" - - - ".fess_config/file_config" - - - ".fess_config/file_config_to_label" - - - ".fess_config/file_config_to_role" - - - ".fess_config/job_log" - - - ".fess_config/key_match" - - - ".fess_config/label_to_role" - - - ".fess_config/label_type" - - - ".fess_config/overlapping_host" - - - ".fess_config/path_mapping" - - - ".fess_config/request_header" - - - ".fess_config/role_type" - - - ".fess_config/scheduled_job" - - - ".fess_config/search_field_log" - - - ".fess_config/search_log" - - - ".fess_config/suggest_bad_word" - - - ".fess_config/suggest_elevate_word" - - - ".fess_config/user_info" - - - ".fess_config/web_authentication" - - - ".fess_config/web_config" - - - ".fess_config/web_config_to_label" - - - ".fess_config/web_config_to_role" - - - diff --git a/src/main/resources/esclient.xml b/src/main/resources/esclient.xml new file mode 100644 index 000000000..15fff5ab0 --- /dev/null +++ b/src/main/resources/esclient.xml @@ -0,0 +1,135 @@ + + + + + + {"http.cors.enabled":"true", "index.number_of_replicas":"0"} + + + + "fess" + "synonym.txt" + + + "fess" + "ja/mapping.txt" + + + "fess" + "ja/kuromoji.txt" + + + + "fess/doc" + + + + ".fess_config/boost_document_rule" + + + ".fess_config/crawling_session" + + + ".fess_config/crawling_session_info" + + + ".fess_config/data_config" + + + ".fess_config/data_config_to_label" + + + ".fess_config/data_config_to_role" + + + ".fess_config/failure_url" + + + ".fess_config/file_authentication" + + + ".fess_config/file_config" + + + ".fess_config/file_config_to_label" + + + ".fess_config/file_config_to_role" + + + ".fess_config/job_log" + + + ".fess_config/key_match" + + + ".fess_config/label_to_role" + + + ".fess_config/label_type" + + + ".fess_config/overlapping_host" + + + ".fess_config/path_mapping" + + + ".fess_config/request_header" + + + ".fess_config/role_type" + + + ".fess_config/scheduled_job" + + + ".fess_config/suggest_bad_word" + + + ".fess_config/suggest_elevate_word" + + + ".fess_config/web_authentication" + + + ".fess_config/web_config" + + + ".fess_config/web_config_to_label" + + + ".fess_config/web_config_to_role" + + + + ".fess_user/user" + + + ".fess_user/role" + + + ".fess_user/group" + + + + "fess_log/event_log" + + + "fess_log/click_log" + + + "fess_log/favorite_log" + + + "fess_log/search_field_log" + + + "fess_log/search_log" + + + "fess_log/user_info" + + + diff --git a/src/main/resources/fess.dicon b/src/main/resources/fess.xml similarity index 59% rename from src/main/resources/fess.dicon rename to src/main/resources/fess.xml index 8da2f2ca4..4a1871c1f 100644 --- a/src/main/resources/fess.dicon +++ b/src/main/resources/fess.xml @@ -1,13 +1,13 @@ - + - - + + - @org.codelibs.fess.util.ResourceUtil@getConfPath("crawler.properties") + org.codelibs.fess.util.ResourceUtil.getConfPath("crawler.properties") @@ -37,12 +37,12 @@ "ro", "ru", "sv", "th", "tr", "zh_CN", "zh_TW", "zh" } --> - @System@getProperty("fess.log.file") == null ? - @System@getProperty("java.io.tmpdir") + "/fess_crawler.out" : - @System@getProperty("fess.log.file").replaceAll(".out", "_crawler.out") + java.lang.System.getProperty("fess.log.file") == null ? + java.lang.System.getProperty("java.io.tmpdir") + "/fess_crawler.out" : + java.lang.System.getProperty("fess.log.file").replaceAll(".out", "_crawler.out") -new String[] { +[ "-Djava.awt.headless=true", "-server", "-Xmx256m", @@ -54,83 +54,83 @@ new String[] { "-XX:+UseParNewGC", "-XX:+UseTLAB", "-XX:+DisableExplicitGC" -} +] - - {"fess"} - - + + ["fess"] + + "index" "index.jsp" - - + + "header" "header.jsp" - - + + "footer" "footer.jsp" - - + + "search" "search.jsp" - - + + "searchResults" "searchResults.jsp" - - + + "searchNoResult" "searchNoResult.jsp" - - + + "help" "help.jsp" - - + + "error" "error.jsp" - - + + "errorHeader" "error/header.jsp" - - + + "errorFooter" "error/footer.jsp" - - + + "errorNotFound" "error/notFound.jsp" - - + + "errorSystem" "error/system.jsp" - - + + "errorRedirect" "error/redirect.jsp" - - + + "errorBadRequest" "error/badRequest.jsp" - - + + "cache" "cache.hbs" - + - + "mail.smtp.host" "localhost" - + @@ -156,43 +156,4 @@ new String[] { "," --> - - diff --git a/src/main/resources/fess_api.dicon b/src/main/resources/fess_api.xml similarity index 68% rename from src/main/resources/fess_api.dicon rename to src/main/resources/fess_api.xml index 63b219eb0..6af6d8267 100644 --- a/src/main/resources/fess_api.dicon +++ b/src/main/resources/fess_api.xml @@ -1,14 +1,14 @@ - + - + xmlApiManager - - + + jsonApiManager - + diff --git a/src/main/resources/fess_config.properties b/src/main/resources/fess_config.properties index 8786b0f4e..745ca8914 100644 --- a/src/main/resources/fess_config.properties +++ b/src/main/resources/fess_config.properties @@ -10,13 +10,16 @@ domain.title = Fess # ======================================================================================== -# DB -# ====== +# DB +# ==== # ======================================================================================== -# Web -# ======= +# Web +# ===== +# ---------------------------------------------------------- +# Cookie +# ------ # The default path of cookie (basically '/' if no context path) cookie.default.path = / @@ -25,3 +28,18 @@ cookie.default.expire = 31556926 # The eternal expire of cookie in seconds e.g. 315360000: ten year, 86400: one day cookie.eternal.expire = 315360000 + +# The cookie key of remember-me for Fess +cookie.remember.me.harbor.key = FES + +# ---------------------------------------------------------- +# Paging +# ------ +# The size of one page for paging +paging.page.size = 4 + +# The size of page range for paging +paging.page.range.size = 3 + +# The option 'fillLimit' of page range for paging +paging.page.range.fill.limit = true diff --git a/src/main/resources/fess_dict.dicon b/src/main/resources/fess_dict.dicon deleted file mode 100644 index 78647dabf..000000000 --- a/src/main/resources/fess_dict.dicon +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - userDictLocator - - - synonymLocator - - - - - {"data", "txlog", - "lib", "bin", "contrib"} - - "${solr.solr.home}" - - - - - {"data", "txlog", - "lib", "bin", "contrib"} - - "${solr.solr.home}" - - - - diff --git a/src/main/resources/fess_dict.xml b/src/main/resources/fess_dict.xml new file mode 100644 index 000000000..f259f7b80 --- /dev/null +++ b/src/main/resources/fess_dict.xml @@ -0,0 +1,30 @@ + + + + + + userDictLocator + + + synonymLocator + + + + + ["data", "txlog", + "lib", "bin", "contrib"] + + "${solr.solr.home}" + + + + + ["data", "txlog", + "lib", "bin", "contrib"] + + "${solr.solr.home}" + + + + diff --git a/src/main/resources/fess_ds.dicon b/src/main/resources/fess_ds.xml similarity index 79% rename from src/main/resources/fess_ds.dicon rename to src/main/resources/fess_ds.xml index 8d23f2300..5bbb7a444 100644 --- a/src/main/resources/fess_ds.dicon +++ b/src/main/resources/fess_ds.xml @@ -1,20 +1,20 @@ - + - + "DatabaseDataStore" databaseDataStore - - + + "CsvDataStore" csvDataStore - - + + "FileListDataStore" fileListDataStore - + diff --git a/src/main/resources/fess_env.properties b/src/main/resources/fess_env.properties index dd538109d..7b68f7850 100644 --- a/src/main/resources/fess_env.properties +++ b/src/main/resources/fess_env.properties @@ -4,6 +4,9 @@ # ======================================================================================== # Core # ====== +# The mode of Lasta Di's smart-deploy, should be cool in production (e.g. hot, cool, warm) +lasta_di.smart.deploy.mode = hot + # Is development environment here? (used for various purpose, you should set false if unknown) development.here = true @@ -18,28 +21,27 @@ framework.debug = false # The milliseconds for (relative or absolute) adjust time (set only when test) @LongType *dynamic in development time.adjust.time.millis = 0 - -# ======================================================================================== -# Mail -# ==== +# ---------------------------------------------------------- +# Mail +# ------ # Does it send mock mail? (true: no send actually, logging only) mail.send.mock = true -# SMTP server settings for default: host:port -mail.smtp.server.default.host.and.port = localhost:25 +# SMTP server settings for main: host:port +mail.smtp.server.main.host.and.port = localhost:25 + +# The prefix of subject to show test environment or not +mail.subject.test.prefix = [Test] + +# The common return path of all mail +mail.return.path = root@localhost # ======================================================================================== -# JDBC +# DB # ==== -# The URL of database connection for JDBC -jdbc.url = jdbc:mysql://localhost:3306/maihamadb -# The user of database connection for JDBC -jdbc.user = maihamauser -# @Secure The password of database connection for JDBC -jdbc.password = maihamaword - -# The (max) pooling size of Seasar's connection pool -jdbc.connection.pooling.size = 10 +# ======================================================================================== +# Web +# ===== diff --git a/src/main/resources/fess_env_production.properties b/src/main/resources/fess_env_production.properties new file mode 100644 index 000000000..2c2c3c788 --- /dev/null +++ b/src/main/resources/fess_env_production.properties @@ -0,0 +1,47 @@ +# _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ +# Fess environment configuration for Local Development +# _/_/_/_/_/_/_/_/_/_/ +# ======================================================================================== +# Core +# ====== +# The mode of Lasta Di's smart-deploy, should be cool in production (e.g. hot, cool, warm) +lasta_di.smart.deploy.mode = cool + +# Is development environment here? (used for various purpose, you should set false if unknown) +development.here = false + +# The title of environment (e.g. local or integartion or production) +environment.title = Production + +# Does it enable the Framework internal debug? (true only when emergency) +framework.debug = false + +# one day: 86400000, three days: 259200000, five days: 432000000, one week: 604800000, one year: 31556926000 +# special script :: absolute mode: $(2014/07/10), relative mode: addDay(3).addMonth(4) +# The milliseconds for (relative or absolute) adjust time (set only when test) @LongType *dynamic in development +time.adjust.time.millis = 0 + +# ---------------------------------------------------------- +# Mail +# ------ +# Does it send mock mail? (true: no send actually, logging only) +mail.send.mock = true + +# SMTP server settings for main: host:port +mail.smtp.server.main.host.and.port = localhost:25 + +# The prefix of subject to show test environment or not +mail.subject.test.prefix = + +# The common return path of all mail +mail.return.path = root@localhost + + +# ======================================================================================== +# DB +# ==== + + +# ======================================================================================== +# Web +# ===== diff --git a/src/main/resources/fess_es.dicon b/src/main/resources/fess_es.xml similarity index 89% rename from src/main/resources/fess_es.dicon rename to src/main/resources/fess_es.xml index 9222eb1e5..a5701f4db 100644 --- a/src/main/resources/fess_es.dicon +++ b/src/main/resources/fess_es.xml @@ -1,8 +1,8 @@ - + - + @@ -37,4 +37,8 @@ + + + + diff --git a/src/main/resources/fess_indices/.fess_config.json b/src/main/resources/fess_indices/.fess_config.json index 095b0fe6a..def7bad83 100644 --- a/src/main/resources/fess_indices/.fess_config.json +++ b/src/main/resources/fess_indices/.fess_config.json @@ -2,7 +2,7 @@ "settings": { "index": { "refresh_interval": "1s", - "number_of_shards": 5, + "number_of_shards": 2, "number_of_replicas": 0 } } diff --git a/src/main/resources/fess_indices/.fess_config/scheduled_job.bulk b/src/main/resources/fess_indices/.fess_config/scheduled_job.bulk new file mode 100644 index 000000000..187b55a00 --- /dev/null +++ b/src/main/resources/fess_indices/.fess_config/scheduled_job.bulk @@ -0,0 +1,8 @@ +{"index":{"_index":".fess_config","_type":"scheduled_job","_id":"1"}} +{"name":"Crawler","target":"all","cronExpression":"0 0 0 * * ?","scriptType":"groovy","scriptData":"return container.getComponent(\"crawlJob\").execute(executor);","jobLogging":true,"crawler":true,"available":true,"sortOrder":0,"createdBy":"system","createdTime":0,"updatedBy":"system","updatedTime":0} +{"index":{"_index":".fess_config","_type":"scheduled_job","_id":"2"}} +{"name":"Minutely Tasks","target":"all","cronExpression":"0 * * * * ?","scriptType":"groovy","scriptData":"return container.getComponent(\"aggregateLogJob\").execute();","jobLogging":false,"crawler":false,"available":true,"sortOrder":0,"createdBy":"system","createdTime":0,"updatedBy":"system","updatedTime":0} +{"index":{"_index":".fess_config","_type":"scheduled_job","_id":"3"}} +{"name":"Hourly Tasks","target":"all","cronExpression":"0 0 * * * ?","scriptType":"groovy","scriptData":"return container.getComponent(\"updateHotWordJob\").execute();","jobLogging":false,"crawler":false,"available":true,"sortOrder":0,"createdBy":"system","createdTime":0,"updatedBy":"system","updatedTime":0} +{"index":{"_index":".fess_config","_type":"scheduled_job","_id":"4"}} +{"name":"Daily Tasks","target":"all","cronExpression":"0 0 0 * * ?","scriptType":"groovy","scriptData":"return container.getComponent(\"purgeLogJob\").execute();","jobLogging":false,"crawler":false,"available":true,"sortOrder":0,"createdBy":"system","createdTime":0,"updatedBy":"system","updatedTime":0} diff --git a/src/main/resources/fess_indices/.fess_user.json b/src/main/resources/fess_indices/.fess_user.json new file mode 100644 index 000000000..7bc5f92a2 --- /dev/null +++ b/src/main/resources/fess_indices/.fess_user.json @@ -0,0 +1,21 @@ +{ + "settings": { + "index": { + "refresh_interval": "1s", + "number_of_shards": 5, + "number_of_replicas": 0 + }, + "dbflute": { + "user": { + "properties": { + "groups": { + "array": true + }, + "roles": { + "array": true + } + } + } + } + } +} diff --git a/src/main/resources/fess_indices/.fess_user/group.json b/src/main/resources/fess_indices/.fess_user/group.json new file mode 100644 index 000000000..205abd287 --- /dev/null +++ b/src/main/resources/fess_indices/.fess_user/group.json @@ -0,0 +1,23 @@ +{ + "group": { + "_source": { + "enabled": true + }, + "_all": { + "enabled": false + }, + "_id": { + "path": "id" + }, + "properties": { + "id": { + "type": "string", + "index": "not_analyzed" + }, + "name": { + "type": "string", + "index": "not_analyzed" + } + } + } +} diff --git a/src/main/resources/fess_indices/.fess_user/role.bulk b/src/main/resources/fess_indices/.fess_user/role.bulk new file mode 100644 index 000000000..72b534122 --- /dev/null +++ b/src/main/resources/fess_indices/.fess_user/role.bulk @@ -0,0 +1,2 @@ +{"index":{"_index":".fess_user","_type":"role","_id":"YWRtaW4="}} +{"name":"admin","id":"YWRtaW4="} diff --git a/src/main/resources/fess_indices/.fess_user/role.json b/src/main/resources/fess_indices/.fess_user/role.json new file mode 100644 index 000000000..fc5097dc4 --- /dev/null +++ b/src/main/resources/fess_indices/.fess_user/role.json @@ -0,0 +1,23 @@ +{ + "role": { + "_source": { + "enabled": true + }, + "_all": { + "enabled": false + }, + "_id": { + "path": "id" + }, + "properties": { + "id": { + "type": "string", + "index": "not_analyzed" + }, + "name": { + "type": "string", + "index": "not_analyzed" + } + } + } +} diff --git a/src/main/resources/fess_indices/.fess_user/user.bulk b/src/main/resources/fess_indices/.fess_user/user.bulk new file mode 100644 index 000000000..5f8d1cec5 --- /dev/null +++ b/src/main/resources/fess_indices/.fess_user/user.bulk @@ -0,0 +1,2 @@ +{"index":{"_index":".fess_user","_type":"user","_id":"YWRtaW4="}} +{"password":"8c6976e5b5410415bde908bd4dee15dfb167a9c873fc4bb8a81f6f2ab448a918","roles":["YWRtaW4="],"name":"admin","id":"YWRtaW4="} diff --git a/src/main/resources/fess_indices/.fess_user/user.json b/src/main/resources/fess_indices/.fess_user/user.json new file mode 100644 index 000000000..c0869f61d --- /dev/null +++ b/src/main/resources/fess_indices/.fess_user/user.json @@ -0,0 +1,35 @@ +{ + "user": { + "_source": { + "enabled": true + }, + "_all": { + "enabled": false + }, + "_id": { + "path": "id" + }, + "properties": { + "id": { + "type": "string", + "index": "not_analyzed" + }, + "name": { + "type": "string", + "index": "not_analyzed" + }, + "password": { + "type": "string", + "index": "not_analyzed" + }, + "groups": { + "type": "string", + "index": "not_analyzed" + }, + "roles": { + "type": "string", + "index": "not_analyzed" + } + } + } +} diff --git a/src/main/resources/fess_indices/fess.json b/src/main/resources/fess_indices/fess.json index 095b0fe6a..cc93f103d 100644 --- a/src/main/resources/fess_indices/fess.json +++ b/src/main/resources/fess_indices/fess.json @@ -4,6 +4,65 @@ "refresh_interval": "1s", "number_of_shards": 5, "number_of_replicas": 0 + }, + "analysis": { + "char_filter": { + "mapping_ja_cfilter": { + "type": "mapping", + "mappings_path": "ja/mapping.txt" + } + }, + "filter": { + "stemmer_en_tfilter": { + "type": "stemmer", + "name": "english" + } + }, + "tokenizer": { + "kuromoji_neologd_tokenizer": { + "type": "reloadable_kuromoji_neologd_tokenizer", + "mode": "normal", + "user_dictionary": "ja/kuromoji.txt", + "discard_punctuation": false, + "reload_interval":"1m" + }, + "2gram_synonym_tokenizer": { + "type": "ngram_synonym", + "n": "2", + "synonyms_path": "synonym.txt", + "dynamic_reload":true, + "reload_interval":"1m" + } + }, + "analyzer": { + "japanese_analyzer": { + "type": "custom", + "char_filter": [ + "mapping_ja_cfilter", + "kuromoji_neologd_iteration_mark" + ], + "tokenizer": "kuromoji_neologd_tokenizer", + "filter": [ + "kuromoji_neologd_baseform", + "kuromoji_neologd_stemmer", + "kuromoji_neologd_part_of_speech" + ] + }, + "english_analyzer": { + "type": "custom", + "tokenizer": "standard", + "filter": [ + "stemmer_en_tfilter" + ] + }, + "standard_analyzer": { + "type": "custom", + "char_filter": [ + "mapping_ja_cfilter" + ], + "tokenizer": "2gram_synonym_tokenizer" + } + } } } } diff --git a/src/main/resources/fess_indices/fess/doc.json b/src/main/resources/fess_indices/fess/doc.json index c92b29e65..a0e3ff6ce 100644 --- a/src/main/resources/fess_indices/fess/doc.json +++ b/src/main/resources/fess_indices/fess/doc.json @@ -1,18 +1,520 @@ { "doc": { - "_source": { - "enabled": true - }, "_all": { "enabled": false }, - "_id" : { - "path" : "id" + "_source": { + "enabled": true }, + "_id": { + "path": "id" + }, + "dynamic_templates": [ + { + "lang_ar": { + "match": "*_ar", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_bg": { + "match": "*_bg", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_bn": { + "match": "*_bn", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_ca": { + "match": "*_ca", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_cs": { + "match": "*_cs", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_da": { + "match": "*_da", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_de": { + "match": "*_de", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_el": { + "match": "*_el", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_en": { + "match": "*_en", + "mapping": { + "type": "string", + "analyzer": "english_analyzer" + } + } + }, + { + "lang_es": { + "match": "*_es", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_et": { + "match": "*_et", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_fa": { + "match": "*_fa", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_fi": { + "match": "*_fi", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_fr": { + "match": "*_fr", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_gu": { + "match": "*_gu", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_he": { + "match": "*_he", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_hi": { + "match": "*_hi", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_hr": { + "match": "*_hr", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_hu": { + "match": "*_hu", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_id": { + "match": "*_id", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_it": { + "match": "*_it", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_ja": { + "match": "*_ja", + "mapping": { + "type": "string", + "analyzer": "japanese_analyzer" + } + } + }, + { + "lang_ko": { + "match": "*_ko", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_lt": { + "match": "*_lt", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_lv": { + "match": "*_lv", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_mk": { + "match": "*_mk", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_ml": { + "match": "*_ml", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_nl": { + "match": "*_nl", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_no": { + "match": "*_no", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_pa": { + "match": "*_pa", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_pl": { + "match": "*_pl", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_pt": { + "match": "*_pt", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_ro": { + "match": "*_ro", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_ru": { + "match": "*_ru", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_si": { + "match": "*_si", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_sq": { + "match": "*_sq", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_sv": { + "match": "*_sv", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_ta": { + "match": "*_ta", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_te": { + "match": "*_te", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_th": { + "match": "*_th", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_tl": { + "match": "*_tl", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_tr": { + "match": "*_tr", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_uk": { + "match": "*_uk", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_ur": { + "match": "*_ur", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_vi": { + "match": "*_vi", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_zh-cn": { + "match": "*_zh-cn", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + }, + { + "lang_zh-tw": { + "match": "*_zh-tw", + "mapping": { + "type": "string", + "analyzer": "standard_analyzer" + } + } + } + ], "properties": { + "anchor": { + "type": "string", + "index": "not_analyzed" + }, + "boost": { + "type": "float" + }, + "click_count": { + "type": "long" + }, + "config_id": { + "type": "string", + "index": "not_analyzed" + }, + "content": { + "type": "langstring", + "analyzer": "standard_analyzer", + "term_vector": "with_positions_offsets" + }, + "content_length": { + "type": "long" + }, + "created": { + "type": "date", + "format": "date_optional_time" + }, + "digest": { + "type": "string" + }, + "doc_id": { + "type": "string", + "index": "not_analyzed" + }, + "favorite_count": { + "type": "long" + }, + "filetype": { + "type": "string", + "index": "not_analyzed" + }, + "host": { + "type": "string", + "index": "not_analyzed" + }, "id": { "type": "string", "index": "not_analyzed" + }, + "lang": { + "type": "string", + "index": "not_analyzed" + }, + "last_modified": { + "type": "date", + "format": "date_optional_time" + }, + "mimetype": { + "type": "string", + "index": "not_analyzed" + }, + "parent_id": { + "type": "string", + "index": "not_analyzed" + }, + "segment": { + "type": "string", + "index": "not_analyzed" + }, + "site": { + "type": "string", + "index": "not_analyzed" + }, + "title": { + "type": "langstring", + "analyzer": "standard_analyzer", + "term_vector": "with_positions_offsets" + }, + "url": { + "type": "string", + "index": "not_analyzed" } } } diff --git a/src/main/resources/fess_indices/fess/ja/synonym.txt b/src/main/resources/fess_indices/fess/synonym.txt similarity index 100% rename from src/main/resources/fess_indices/fess/ja/synonym.txt rename to src/main/resources/fess_indices/fess/synonym.txt diff --git a/src/main/resources/fess_indices/fess_log.json b/src/main/resources/fess_indices/fess_log.json new file mode 100644 index 000000000..4000a8acb --- /dev/null +++ b/src/main/resources/fess_indices/fess_log.json @@ -0,0 +1,9 @@ +{ + "settings": { + "index": { + "refresh_interval": "60s", + "number_of_shards": 10, + "number_of_replicas": 0 + } + } +} diff --git a/src/main/resources/fess_indices/.fess_config/click_log.json b/src/main/resources/fess_indices/fess_log/click_log.json similarity index 100% rename from src/main/resources/fess_indices/.fess_config/click_log.json rename to src/main/resources/fess_indices/fess_log/click_log.json diff --git a/src/main/resources/fess_indices/fess_log/event_log.json b/src/main/resources/fess_indices/fess_log/event_log.json new file mode 100644 index 000000000..f2e827b2d --- /dev/null +++ b/src/main/resources/fess_indices/fess_log/event_log.json @@ -0,0 +1,37 @@ +{ + "event_log": { + "_source": { + "enabled": true + }, + "_all": { + "enabled": false + }, + "_id": { + "path": "id" + }, + "properties": { + "id": { + "type": "string", + "index": "not_analyzed" + }, + "eventType": { + "type": "string", + "index": "not_analyzed" + }, + "path": { + "type": "string", + "index": "not_analyzed" + }, + "message": { + "type": "string" + }, + "createdBy": { + "type": "string", + "index": "not_analyzed" + }, + "createdAt": { + "type": "date" + } + } + } +} diff --git a/src/main/resources/fess_indices/.fess_config/favorite_log.json b/src/main/resources/fess_indices/fess_log/favorite_log.json similarity index 100% rename from src/main/resources/fess_indices/.fess_config/favorite_log.json rename to src/main/resources/fess_indices/fess_log/favorite_log.json diff --git a/src/main/resources/fess_indices/.fess_config/search_field_log.json b/src/main/resources/fess_indices/fess_log/search_field_log.json similarity index 100% rename from src/main/resources/fess_indices/.fess_config/search_field_log.json rename to src/main/resources/fess_indices/fess_log/search_field_log.json diff --git a/src/main/resources/fess_indices/.fess_config/search_log.json b/src/main/resources/fess_indices/fess_log/search_log.json similarity index 93% rename from src/main/resources/fess_indices/.fess_config/search_log.json rename to src/main/resources/fess_indices/fess_log/search_log.json index 249912d06..9408bb8d0 100644 --- a/src/main/resources/fess_indices/.fess_config/search_log.json +++ b/src/main/resources/fess_indices/fess_log/search_log.json @@ -53,8 +53,9 @@ "type": "string", "index": "not_analyzed" }, - "userId": { - "type": "long" + "userInfoId": { + "type": "string", + "index": "not_analyzed" } } } diff --git a/src/main/resources/fess_indices/.fess_config/user_info.json b/src/main/resources/fess_indices/fess_log/user_info.json similarity index 100% rename from src/main/resources/fess_indices/.fess_config/user_info.json rename to src/main/resources/fess_indices/fess_log/user_info.json diff --git a/src/main/resources/fess_job.dicon b/src/main/resources/fess_job.xml similarity index 84% rename from src/main/resources/fess_job.dicon rename to src/main/resources/fess_job.xml index c506d7248..9adae234f 100644 --- a/src/main/resources/fess_job.dicon +++ b/src/main/resources/fess_job.xml @@ -1,6 +1,6 @@ - + diff --git a/src/main/resources/application.properties b/src/main/resources/fess_label.properties similarity index 80% rename from src/main/resources/application.properties rename to src/main/resources/fess_label.properties index ea7c45e5d..591b2a880 100644 --- a/src/main/resources/application.properties +++ b/src/main/resources/fess_label.properties @@ -1,124 +1,3 @@ -errors.front_header=
    -errors.front_footer=
    -errors.front_prefix=
    -errors.front_suffix=
    -errors.header=
    -errors.footer=
    -errors.prefix=

    -errors.suffix=

    -errors.invalid={0} is invalid. -errors.maxlength={0} can not be greater than {1} characters. -errors.minlength={0} can not be less than {1} characters. -errors.maxbytelength={0} can not be greater than {1} bytes. -errors.minbytelength={0} can not be less than {1} bytes. -errors.range={0} is not in the range {1} through {2}. -errors.required={0} is required. -errors.byte={0} must be an byte. -errors.date={0} is not a date. -errors.double={0} must be an double. -errors.float={0} must be an float. -errors.integer={0} must be an integer. -errors.long={0} must be an long. -errors.short={0} must be an short. -errors.creditcard={0} is not a valid credit card number. -errors.email={0} is an invalid e-mail address. -errors.url={0} is an invalid url (web address). -errors.cronexpression={0} is a invalid format. -errors.uritype={0} is a invalid uri. -errors.alphaDigitOnly={0} must be alphabet or digit only. -errors.alphaDigitSpaceOnly={0} must be alphabet, digit, or space only. -errors.token=Invalid request. - -errors.failed_to_update_crawler_params=Failed to update parameters. Please contact to a site administrator. -errors.failed_to_update_web_crawler_params=Failed to update parameters. Please contact to a site administrator. -errors.failed_to_update_solr_params=Failed to update parameters. Please contact to a site administrator. -error.login_error=Username or Password is not correct. -errors.failed_to_commit_solr_index=Failed to commit index. -errors.failed_to_optimize_solr_index=Failed to optimize index. -errors.failed_to_delete_solr_index=Failed to delete index. -errors.failed_to_start_solr_process_because_of_running=Failed to start a process because of running solr process. -errors.failed_to_import_data=Failed to restore data. -errors.unknown_import_file=Unknown file type. -errors.failed_to_export_data=Failed to backup data. -errors.could_not_find_log_file=Could not find {0}. -errors.no_running_crawl_process=No running crawl process. -errors.failed_to_start_crawl_process=Failed to start a crawl process. -errors.invalid_design_jsp_file_name=Invalid JSP file. -errors.design_jsp_file_does_not_exist=JSP file does not exist. -errors.design_file_name_is_not_found=The file name is not specified. -errors.failed_to_write_design_image_file=Failed to upload an image file. -errors.failed_to_update_jsp_file=Failed to update a jsp file. -errors.design_file_name_is_invalid=The file name is invalid. -errors.design_file_is_unsupported_type=The kind of file is unsupported. -errors.failed_to_start_solr_instance=Failed to start a solr instance. -errors.failed_to_stop_solr_instance=Failed to stop a solr instance. -errors.failed_to_reload_solr_instance=Failed to reload a solr instance. -errors.failed_to_update_crawler_schedule=Failed to update a crawling schedule. -errors.failed_to_create_crawling_config_at_wizard=Failed to create a crawling config. -errors.design_editor_disabled=This feature is disabled. -errors.could_not_create_search_log_csv=Could not create a search log csv file. -errors.not_found_on_file_system=Not Found: {0} -errors.could_not_open_on_system=Could not open {0}.
    Please check if the file is associated with an application. -errors.process_time_is_exceeded=The limit of a search time was exceeded. The partial result was displayed. -errors.result_size_exceeded=No more results could be displayed. -errors.target_file_does_not_exist={0} file does not exist. -errors.failed_to_download_file=Failed to download {0} file. -errors.failed_to_delete_file=Failed to delete {0} file. -errors.failed_to_redirect=Failed to redirect {0}. -errors.unsupported_encoding={0} is not supported as encoding. -errors.docid_not_found=Not found Doc ID:{0} -errors.document_not_found=Not found URL of Doc ID:{0} -errors.not_load_from_server=Could not load from this server: {0} -errors.failed_to_start_job=Failed to start job {0}. -errors.failed_to_stop_job=Failed to stop job {0}. -errors.expired_dict_id=Expired dictionary information. Please reload it. -errors.failed_to_create_cache=Failed to create a cache reponse for ID:{0}. -errors.synonym_file_is_not_found=Synonym file is not found -errors.failed_to_download_synonym_file=Failed to download the Synonym file. -errors.failed_to_upload_synonym_file=Failed to upload the Synonym file. -errors.userdict_file_is_not_found=Synonym file is not found -errors.failed_to_download_userdict_file=Failed to download the UserDict file. -errors.failed_to_upload_userdict_file=Failed to upload the UserDict file. - -errors.invalid_query_unknown=The given query is invalid. -errors.invalid_query_quoted=An invalid quote character is used. -errors.invalid_query_curly_bracket=An invalid curly bracket character is used. -errors.invalid_query_square_bracket=An invalid square bracket character is used. -errors.invalid_query_parenthesis=An invalid parenthesis character is used. -errors.invalid_query_num_range=An invalid range is used. The example of the range format is "field:[20020101 TO 20030101]". -errors.invalid_query_str_range=An invalid range is used. The example of the range format is "field:'{'Aida TO Carmen'}'". - -success.update_crawler_params=Updated parameters. -success.update_web_crawler_params=Updated parameters. -success.update_solr_params=Updated parameters. -success.commit_solr_index=Started a process to commit index. -success.optimize_solr_index=Started a process to optimize index. -success.delete_solr_index=Started a process to optimize index. -success.importing_data=Started to restore data from the uploaded file. -success.crawling_session_delete_all=Deleted session data. -success.start_crawl_process=Started a crawl process. -success.stopping_crawl_process=Stopping a crawl process. -success.upload_design_file=Uploaded {0}. -success.update_design_jsp_file=Updated {0}. -success.starting_solr_instance=Starting a solr instance. -success.stopping_solr_instance=Stopping a solr instance. -success.reloading_solr_instance=Reloading a solr instance. -success.update_crawler_schedule=Updated a crawling schedule. -success.create_crawling_config_at_wizard=Created a crawling config ({0}). -success.search_log_delete_all=Deleted search logs. -success.failure_url_delete_all=Deleted failure urls. -success.delete_file=Deleted {0} file. -success.user_info_delete_all=Deleted user information. -success.favorite_log_delete_all=Deleted popular urls -success.job_started=Started job {0}. -success.job_stopped=Stopped job {0}. -success.joblog_delete_all=Deleted job logs. -success.upload_synonym_file=Uploaded Synonym file. -success.upload_userdict_file=Uploaded UserDict file. -success.upload_suggest_elevate_word=Uploaded Additional Word file. -success.upload_suggest_bad_word=Uploaded Bad Word file. - -# labels labels.authRealm=Realm labels.available=Status labels.createdBy=Created by @@ -288,12 +167,6 @@ labels.synonymFile=Synonym File labels.userDictFile=UserDict File labels.suggestElevateWordFile=Additional Word File labels.suggestBadWordFile=Bad Word File - -# view/common/common.jsp - -# view/common/admin/layout.jsp - -# view/common/admin/menu.jsp labels.menu_system=System labels.menu.wizard=» Wizard labels.menu.crawl_config=» General @@ -303,7 +176,6 @@ labels.menu.document_config=» Index labels.menu.design=» Design labels.menu.dict=» Dictionary labels.menu.data=» Backup/Restore - labels.menu_crawl=Crawler labels.menu.web=» Web labels.menu.file_system=» File System @@ -317,11 +189,13 @@ labels.menu.file_authentication=» File Authentication labels.menu.request_header=» Request Header labels.menu.overlapping_host=» Overlapping Host labels.menu.role_type=» Role - +labels.menu_user=User +labels.menu.user=User +labels.menu.role=Role +labels.menu.group=Group labels.menu_suggest=Suggest labels.menu.suggest_elevate_word=» Additional Word labels.menu.suggest_bad_word=» Bad Word - labels.menu_system_log=System Info labels.menu.system_info=» Config Info labels.menu.session_info=» Session Info @@ -329,24 +203,15 @@ labels.menu.log=» Log Files labels.menu.jobLog=» Job Log labels.menu.failure_url=» Failure URL labels.menu.search_list=» Search - labels.menu_user_log=User Info labels.menu.search_log=» Search Log labels.menu.stats=» Statistics -labels.menu.user=» Users labels.menu.favoriteLog=» Popular URL - labels.menu.logout=Logout - -# view/common/admin/header.jsp labels.header.logo_alt=Fess labels.header.home=Home labels.header.help=Help - -# view/common/admin/footer.jsp labels.footer.copyright=Copyright(C) 2009-2015 CodeLibs Project. All Rights Reserved. - -# view/search.jsp labels.search=Search labels.search_result_status=Results {2} - {3} of {1} pages for {0} labels.search_result_time=({0} sec) @@ -372,34 +237,12 @@ labels.search_result_sort_favoriteCount_asc=Favorite (ascending) labels.search_result_sort_favoriteCount_desc=Favorite (descending) labels.search_result_size={0} bytes labels.search_result_created=Registered: -labels.search_result_lastModified=Last Modified: +labels.search_result_last_modified=Last Modified: labels.search_result_favorite=Vote it labels.search_result_favorited=Voted labels.search_click_count=Click: {0} labels.search_result_more=more.. labels.search_result_cache=Cache - -label.facet_label_title=Label -label.facet_lastModified_title=Term -label.facet_lastModified_1day=Past 24 Hours -label.facet_lastModified_1week=Past Week -label.facet_lastModified_1month=Past Month -label.facet_lastModified_1year=Past Year -label.facet_contentLength_title=Size -label.facet_contentLength_10k=  - 10kb -label.facet_contentLength_10kto100k=10kb - 100kb -label.facet_contentLength_100kto500k=100kb - 500kb -label.facet_contentLength_500kto1m=500kb - 1mb -label.facet_contentLength_1m=1mb -   -label.facet_filetype_title=File Type -label.facet_filetype_html=HTML -label.facet_filetype_word=Word -label.facet_filetype_excel=Excel -label.facet_filetype_powerpoint=PowerPoint -label.facet_filetype_pdf=PDF -label.facet_filetype_others=PDF -label.facet_label_reset=Reset - labels.searchoptions_all=All labels.searchoptions_score=Score labels.searchoptions_menu_sort=Sort: @@ -408,21 +251,13 @@ labels.searchoptions_num={0} results labels.searchoptions_menu_lang=Language: labels.searchoptions_menu_labels=Labels: labels.searchheader_username=Username: {0} - -# view/error.jsp labels.error_title=Error - -# view/error/system.jsp labels.system_error_title=System Error labels.contact_site_admin=Contact the Site Administrator. labels.request_error_title=Bad Request labels.bad_request=Invalid request for the url. - -# view/error/notFound.jsp labels.page_not_found_title=Page Not Found labels.check_url=Check the url. - -# view/login/index.jsp labels.home=Home labels.user_name=User Name labels.login=Login @@ -432,14 +267,10 @@ labels.index_label=Labels labels.index_lang=Languages labels.index_sort=Sort labels.index_num=Results per page - -# view/login/logout.jsp labels.logout_title=Logout labels.logout=Logout labels.do_you_want_to_logout=Do you want to logout? labels.logout_button=Logout - -# view/index.jsp labels.top.search=Search labels.search_top_logo_alt=Fess labels.index_title=Fess @@ -458,15 +289,9 @@ labels.search_options_close=Close labels.search_options_clear=Clear labels.search_cache_msg=This is a cache of {0}. It is a snapshot of the page at {1}. labels.search_unknown=Unknown - -# view/footer.jsp labels.footer_back_to_top=Back to top - -# view/header.jsp labels.header_brand_name=Fess labels.header_form_option_btn=Options - -# view/admin/fileConfig/edit.jsp labels.file_crawling_configuration=File Crawling Configuration labels.file_crawling_title_details=File Crawling Configuration labels.included_paths=Included Paths For Crawling @@ -483,16 +308,10 @@ labels.label_type=Label labels.file_crawling_button_create=Create labels.file_crawling_button_back=Back labels.file_crawling_button_confirm=Confirm - -# view/admin/fileConfig/confirm.jsp labels.file_crawling_title_confirm=Confirm File Crawling Configuration labels.file_crawling_button_update=Update labels.file_crawling_button_delete=Delete labels.file_crawling_button_edit=Edit - -# view/admin/fileConfig/error.jsp - -# view/admin/fileConfig/index.jsp labels.file_crawling_link_create_new=Create New labels.file_crawling_link_list=List labels.file_crawling_link_create=Create New @@ -504,8 +323,6 @@ labels.file_crawling_link_edit=Edit labels.file_crawling_link_delete=Delete labels.file_crawling_link_prev_page=Prev labels.file_crawling_link_next_page=Next - -# view/admin/webConfig/edit.jsp labels.web_crawling_configuration=Web Crawling Configuration labels.web_crawling_title_details=Web Crawling Configuration labels.included_urls=Included URLs For Crawling @@ -516,16 +333,10 @@ labels.user_agent=User Agent labels.web_crawling_button_create=Create labels.web_crawling_button_back=Back labels.web_crawling_button_confirm=Confirm - -# view/admin/webConfig/confirm.jsp labels.web_crawling_title_confirm=Confirm Web Crawling Configuration labels.web_crawling_button_update=Update labels.web_crawling_button_delete=Delete labels.web_crawling_button_edit=Edit - -# view/admin/webConfig/error.jsp - -# view/admin/webConfig/index.jsp labels.web_crawling_link_create_new=Create New labels.web_crawling_link_list=List labels.web_crawling_link_create=Create New @@ -537,8 +348,6 @@ labels.web_crawling_link_edit=Edit labels.web_crawling_link_delete=Delete labels.web_crawling_link_prev_page=Prev labels.web_crawling_link_next_page=Next - -# view/admin/crawl/index.jsp labels.crawler_configuration=General Configuration labels.crawler_title_edit=General Configuration labels.schedule=Schedule @@ -576,8 +385,6 @@ labels.purge_user_info_day=Purge User Before labels.purge_by_bots=Bots Name For Purge labels.csv_file_encoding=Encoding for CSV labels.notification_to=Notification Email - -# view/admin/filePathMapping/edit.jsp labels.path_mapping_configuration=Path Mapping Configuration labels.path_mapping_title_details=Path Mapping labels.path_mapping_button_create=Create @@ -587,8 +394,6 @@ labels.disabled=Disabled labels.path_mapping_pt_crawling=Crawling labels.path_mapping_pt_displaying=Displaying labels.path_mapping_pt_both=Crawling/Displaying - -# view/admin/filePathMapping/confirm.jsp labels.path_mapping_title_confirm=Confirm Path Mapping labels.regular_name=Regular Name labels.overlapping_name=Overlapping Name @@ -597,10 +402,6 @@ labels.path_mapping_button_back=Back labels.path_mapping_button_update=Update labels.path_mapping_button_delete=Delete labels.path_mapping_button_edit=Edit - -# view/admin/filePathMapping/error.jsp - -# view/admin/filePathMapping/index.jsp labels.path_mapping_link_create_new=Create New labels.path_mapping_link_list=List labels.path_mapping_link_create=Create New @@ -612,25 +413,17 @@ labels.path_mapping_link_edit=Edit labels.path_mapping_link_delete=Delete labels.path_mapping_link_prev_page=Prev labels.path_mapping_link_next_page=Next - -# view/admin/overlappingHost/edit.jsp labels.overlapping_host_configuration=Overlapping Host Configuration labels.overlapping_host_title_details=Overlapping Host labels.overlapping_host_button_create=Create labels.overlapping_host_button_back=Back labels.overlapping_host_button_confirm=Confirm - -# view/admin/overlappingHost/confirm.jsp labels.overlapping_host_title_confirm=Confirm Overlapping Host labels.overlapping_host_button_create=Create labels.overlapping_host_button_back=Back labels.overlapping_host_button_update=Update labels.overlapping_host_button_delete=Delete labels.overlapping_host_button_edit=Edit - -# view/admin/overlappingHost/error.jsp - -# view/admin/overlappingHost/index.jsp labels.overlapping_host_link_create_new=Create New labels.overlapping_host_link_list=List labels.overlapping_host_link_create=Create New @@ -642,8 +435,6 @@ labels.overlapping_host_link_edit=Edit labels.overlapping_host_link_delete=Delete labels.overlapping_host_link_prev_page=Prev labels.overlapping_host_link_next_page=Next - -# view/admin/solr/index.jsp labels.system_title_configuration=System Configuration labels.system_title_system_status=System Status labels.es_button_update=Update @@ -694,19 +485,14 @@ labels.suggest_type_content=content labels.suggest_type_searchlog=search words labels.suggest_search_log_enabled=Suggest by Search Words labels.purge_suggest_search_log_day=Purge Suggest Docs by Search Words - -# view/admin/crawlingSession/confirm.jsp labels.crawling_session_title=Session Information labels.crawling_session_title_confirm=Crawling Information labels.crawling_session_button_back=Back labels.crawling_session_button_delete=Delete - -# view/admin/crawlingSession/error.jsp - -# view/admin/crawlingSession/index.jsp labels.crawling_session_configuration=Crawling Session labels.crawling_session_search=Search labels.crawling_session_reset=Reset +labels.crawling_session_link_list=List labels.crawling_session_link_details=Details labels.crawling_session_link_delete=Delete labels.crawling_session_prev_page=Prev @@ -718,7 +504,6 @@ labels.crawling_session_created_time=Created labels.crawling_session_expired_time=Expired labels.crawling_session_delete_all_link=Delete All labels.crawling_session_delete_all_confirmation=Do you want to delete all? - labels.crawling_session_CrawlerStatus=Crawling Status labels.crawling_session_CrawlerStartTime=Start Time (Crawling) labels.crawling_session_CrawlerEndTime=End Time (Crawling) @@ -743,8 +528,6 @@ labels.crawling_session_ReplicationStatus=Replication Status labels.crawling_session_ReplicationStartTime=Start Time (Replication) labels.crawling_session_ReplicationEndTime=End Time (Replication) labels.crawling_session_ReplicationExecTime=Exec Time (Replication) - -# view/admin/data/index.jsp labels.data_configuration=Backup/Restore Configuration labels.backup_title_edit=Backup labels.backup=Backup @@ -757,8 +540,6 @@ labels.backup_config=Confinguration labels.backup_session_info=Session Info labels.backup_search_log=Search Log labels.backup_click_log=Click Long - -# view/admin/webAuthentication/index.jsp labels.web_authentication_configuration=Web Authentication labels.web_authentication_link_create_new=Create New labels.web_authentication_link_list=List @@ -776,8 +557,6 @@ labels.web_authentication_list_realm=Realm labels.web_authentication_list_web_crawling_config=Config Name labels.web_authentication_any=Any labels.web_authentication_create_web_config=Create New Web Config - -# view/admin/webAuthentication/edit.jsp labels.web_authentication_title_details=Web Authentication labels.web_authentication_button_create=Create labels.web_authentication_button_back=Back @@ -793,20 +572,14 @@ labels.web_authentication_web_crawling_config=Web Config labels.web_authentication_scheme_basic=Basic labels.web_authentication_scheme_digest=Digest labels.web_authentication_scheme_ntlm=NTLM - -# view/admin/webAuthentication/confirm.jsp labels.web_authentication_title_confirm=Web Authentication labels.web_authentication_button_update=Update labels.web_authentication_button_delete=Delete labels.web_authentication_button_edit=Edit - -# view/admin/log/confirm.jsp labels.log_configuration=Log Files labels.log_file_download_title=Log Files labels.log_file_name=File Name labels.log_file_date=Timestamp - -# view/admin/labelType/edit.jsp labels.labeltype_configuration=Label labels.labeltype_title_details=Label labels.labeltype_button_create=Create @@ -814,8 +587,6 @@ labels.labeltype_button_back=Back labels.labeltype_button_confirm=Confirm labels.labeltype_name=Name labels.labeltype_value=Value - -# view/admin/labelType/confirm.jsp labels.labeltype_title_confirm=Confirm Label labels.labeltype_button_create=Create labels.labeltype_button_back=Back @@ -824,8 +595,6 @@ labels.labeltype_button_delete=Delete labels.labeltype_button_edit=Edit labels.labeltype_included_paths=Included Paths labels.labeltype_excluded_paths=Excluded Paths - -# view/admin/labeltype/index.jsp labels.labeltype_link_create_new=Create New labels.labeltype_link_list=List labels.labeltype_link_create=Create New @@ -837,8 +606,6 @@ labels.labeltype_link_edit=Edit labels.labeltype_link_delete=Delete labels.labeltype_link_prev_page=Prev labels.labeltype_link_next_page=Next - -# view/admin/roleType/edit.jsp labels.roletype_configuration=Role labels.roletype_title_details=Role labels.roletype_button_create=Create @@ -846,16 +613,12 @@ labels.roletype_button_back=Back labels.roletype_button_confirm=Confirm labels.roletype_name=Name labels.roletype_value=Value - -# view/admin/roleType/confirm.jsp labels.roletype_title_confirm=Confirm Role labels.roletype_button_create=Create labels.roletype_button_back=Back labels.roletype_button_update=Update labels.roletype_button_delete=Delete labels.roletype_button_edit=Edit - -# view/admin/roletype/index.jsp labels.roletype_link_create_new=Create New labels.roletype_link_list=List labels.roletype_link_create=Create New @@ -867,8 +630,6 @@ labels.roletype_link_edit=Edit labels.roletype_link_delete=Delete labels.roletype_link_prev_page=Prev labels.roletype_link_next_page=Next - -# view/admin/requestHeader/index.jsp labels.request_header_configuration=Request Header labels.request_header_link_create_new=Create New labels.request_header_link_list=List @@ -884,8 +645,6 @@ labels.request_header_link_next_page=Next labels.request_header_list_name=Name labels.request_header_list_web_crawling_config=Config Name labels.request_header_create_web_config=Create New Web Config - -# view/admin/requestHeader/edit.jsp labels.request_header_title_details=Request Header labels.request_header_button_create=Create labels.request_header_button_back=Back @@ -893,14 +652,10 @@ labels.request_header_button_confirm=Confirm labels.request_header_name=Name labels.request_header_value=Value labels.request_header_web_crawling_config=Web Config - -# view/admin/requestHeader/confirm.jsp labels.request_header_title_confirm=Request Header labels.request_header_button_update=Update labels.request_header_button_delete=Delete labels.request_header_button_edit=Edit - -# view/admin/keyMatch/index.jsp labels.key_match_configuration=Key Match labels.key_match_link_create_new=Create New labels.key_match_link_list=List @@ -919,22 +674,16 @@ labels.key_match_term=Term labels.key_match_query=Query labels.key_match_size=Size labels.key_match_boost=Boost - -# view/admin/keyMatch/edit.jsp labels.key_match_title_details=Key Match labels.key_match_button_create=Create labels.key_match_button_back=Back labels.key_match_button_confirm=Confirm labels.key_match_name=Name labels.key_match_value=Value - -# view/admin/keyMatch/confirm.jsp labels.key_match_title_confirm=Confirm Key Match labels.key_match_button_update=Update labels.key_match_button_delete=Delete labels.key_match_button_edit=Edit - -# view/admin/design/index.jsp labels.design_configuration=Design labels.design_title_file_upload=File Upload labels.design_title_file=File Manager @@ -962,13 +711,9 @@ labels.design_file_errorSystem=Error Page (System Error) labels.design_file_errorRedirect=Error Page (Redirect) labels.design_file_errorBadRequest=Error Page (BadRequest) labels.design_delete_confirmation=Do you want to delete it? - -# view/admin/design/edit.jsp labels.design_title_edit_content=Edit Page View File labels.design_button_update=Update labels.design_button_back=Back - -# view/admin/dataConfig/edit.jsp labels.data_crawling_configuration=Data Crawling Configuration labels.data_crawling_title_details=Data Crawling Configuration labels.handler_name=Handler Name @@ -979,16 +724,10 @@ labels.label_type=Label labels.data_crawling_button_create=Create labels.data_crawling_button_back=Back labels.data_crawling_button_confirm=Confirm - -# view/admin/dataConfig/confirm.jsp labels.data_crawling_title_confirm=Confirm Data Crawling Configuration labels.data_crawling_button_update=Update labels.data_crawling_button_delete=Delete labels.data_crawling_button_edit=Edit - -# view/admin/dataConfig/error.jsp - -# view/admin/dataConfig/index.jsp labels.data_crawling_link_create_new=Create New labels.data_crawling_link_list=List labels.data_crawling_link_create=Create New @@ -1000,14 +739,10 @@ labels.data_crawling_link_edit=Edit labels.data_crawling_link_delete=Delete labels.data_crawling_link_prev_page=Prev labels.data_crawling_link_next_page=Next - -# view/admin/wizard/index.jsp labels.wizard_title_configuration=Configuration Wizard labels.wizard_start_title=Configuration Wizard labels.wizard_start_desc=Using Configuration Wizard, you can create crawling settings easily. labels.wizard_start_button=Start - -# view/admin/wizard/schduleForm.jsp labels.wizard_schedule_title=Crawling Schedule labels.wizard_schedule_enabled=Use Schedule labels.wizard_schedule=Schedule @@ -1023,8 +758,6 @@ labels.wizard_button_next=Next labels.wizard_button_skip=Skip labels.wizard_button_cancel=Cancel labels.wizard_button_back=Back - -# view/admin/wizard/schduleForm.jsp labels.wizard_crawling_config_title=Crawling Configuration labels.wizard_crawling_config_name=Name labels.wizard_crawling_config_path=Crawling Path @@ -1040,23 +773,15 @@ labels.wizard_schedule_day_sat=Sat labels.wizard_schedule_day_m_f=Mon-Fri labels.wizard_schedule_day_mwf=Mon,Wed,Fri labels.wizard_schedule_day_tt=Tue,Thu - -# view/admin/wizard/startCrawling.jsp labels.wizard_start_crawling_title=Start Crawling labels.wizard_start_crawling_desc=To click "Start Crawling" button, you can start a crawling now. labels.wizard_button_start_crawling=Start Crawling labels.wizard_button_finish=Finish - -# view/admin/searchList/index.jsp labels.search_list_configuration=Search Result labels.search_list_index_page=Type a search query. - -# view/admin/searchList/confirmDelete.jsp labels.search_list_title_confirm_delete=Delete Confirmation labels.search_list_url=URL labels.search_list_delete_link=Delete - -# view/admin/searchLog/index.jsp labels.search_log_configuration=Search Log labels.search_log_search_word_search=Search Word labels.search_log_user_code_search=User ID @@ -1079,8 +804,6 @@ labels.search_log_search_start_page=First Query Only labels.search_log_search_term=Term labels.search_log_search_term_from=From: labels.search_log_search_term_to=To: - -# view/admin/searchLog/confirm.jsp labels.search_log_title=Search Log labels.search_log_title_confirm=Details labels.search_log_id=ID @@ -1095,8 +818,6 @@ labels.search_log_click_log_title=Click Logs labels.search_log_click_log_url=URL labels.search_log_click_log_requestedTime=Requested Time labels.search_log_access_type=Access Type - -# view/admin/failureUrl/index.jsp labels.failure_url_configuration=Failure URL labels.failure_url_search_url=URL labels.failure_url_search_error_count=Error Count @@ -1106,8 +827,6 @@ labels.failure_url_last_access_time=Last Access labels.failure_url_link_confirm=Confirm labels.failure_url_delete_all_confirmation=Do you want to delete all? labels.failure_url_error_count=Error Count - -# view/admin/failureUrl/confirm.jsp labels.failure_url_title_confirm=Failure URL Details labels.failure_url_id=ID labels.failure_url_thread_name=Thread Name @@ -1116,8 +835,6 @@ labels.failure_url_error_log=Log labels.failure_url_url=URL labels.failure_url_web_config_name=Web Crawling Configuration labels.failure_url_file_config_name=File Crawling Configuration - -# view/admin/stats/index.jsp labels.stats_configuration=Statistics labels.stats_search_report_type=Report Type labels.stats_search_term=Term @@ -1134,16 +851,12 @@ labels.stats_client_ip=Client IP labels.stats_count=Count labels.stats_click_url=Clicked URL labels.stats_favorite_url=Voted URL - -# view/admin/systemInfo/index.jsp labels.system_info_configuration=System Info labels.system_info_env_title=Env Properties labels.system_info_prop_title=System Properties labels.system_info_fess_prop_title=Fess Properties labels.system_info_bug_report_title=Properties for Bug Report labels.system_info_crawler_properties_does_not_exist=crawler.properties does not exist. Default values are applied. - -# view/admin/fileAuthentication/index.jsp labels.file_authentication_configuration=File Authentication labels.file_authentication_link_create_new=Create New labels.file_authentication_link_list=List @@ -1160,8 +873,6 @@ labels.file_authentication_list_hostname=Hostname labels.file_authentication_list_file_crawling_config=Config Name labels.file_authentication_any=Any labels.file_authentication_create_file_config=Create New File Config - -# view/admin/fileAuthentication/edit.jsp labels.file_authentication_title_details=File Authentication labels.file_authentication_button_create=Create labels.file_authentication_button_back=Back @@ -1174,17 +885,12 @@ labels.file_authentication_password=Password labels.file_authentication_parameters=Parameters labels.file_authentication_file_crawling_config=FS Config labels.file_authentication_scheme_samba=Samba - -# view/admin/fileAuthentication/confirm.jsp labels.file_authentication_title_confirm=File Authentication labels.file_authentication_button_update=Update labels.file_authentication_button_delete=Delete labels.file_authentication_button_edit=Edit - labels.pagination_page_guide_msg={0}/{1} ({2} items) labels.list_could_not_find_crud_table=No data. - -# view/admin/userInfo/index.jsp labels.user_info_configuration=User Info labels.user_info_title=User Info labels.user_info_title_confirm=Details @@ -1198,8 +904,6 @@ labels.user_info_edit_createddate=Created labels.user_info_edit_lastupdated=Last Accessed labels.user_info_delete_all_link=Delete All labels.user_info_delete_all_confirmation=Do you want to delete all? - -# view/admin/favoriteLog/index.jsp labels.favorite_log_title=Popular URL labels.favorite_log_configuration=Popular URL labels.favorite_log_user_code_search=User ID @@ -1215,8 +919,6 @@ labels.favorite_log_download_csv=Download (CSV) labels.favorite_log_search_term=Term labels.favorite_log_title_confirm=Details labels.favorite_log_id=ID - -# view/admin/ScheduledJob/edit.jsp labels.scheduledjob_configuration=Managed Jobs labels.scheduledjob_title_details=Jobs labels.scheduledjob_button_create=Create @@ -1233,8 +935,6 @@ labels.scheduledjob_crawler=Crawler Job labels.scheduledjob_running=Running labels.scheduledjob_active=Active labels.scheduledjob_nojob=- - -# view/admin/ScheduledJob/confirm.jsp labels.scheduledjob_title_confirm=Confirm Job labels.scheduledjob_button_create=Create labels.scheduledjob_button_back=Back @@ -1243,8 +943,6 @@ labels.scheduledjob_button_delete=Delete labels.scheduledjob_button_edit=Edit labels.scheduledjob_button_start=Start labels.scheduledjob_button_stop=Stop - -# view/admin/scheduledjob/index.jsp labels.scheduledjob_link_create_new=Create New labels.scheduledjob_link_list=List labels.scheduledjob_link_create=Create New @@ -1256,8 +954,6 @@ labels.scheduledjob_link_edit=Edit labels.scheduledjob_link_delete=Delete labels.scheduledjob_link_prev_page=Prev labels.scheduledjob_link_next_page=Next - -# jobLog labels.joblog_button_back=Back labels.joblog_button_create=Create labels.joblog_button_delete=Delete @@ -1287,8 +983,6 @@ labels.joblog_title_details=Job Log Details labels.joblog_title_list=Job Log List labels.joblog_delete_all_link=Delete All labels.joblog_delete_all_confirmation=Do you want to delete all? - -# dict labels.dict_configuration=Dictionary List labels.dict_list_title=Dictionary List labels.dict_list_link=Dictionaries @@ -1300,8 +994,6 @@ labels.dict_link_delete=Delete labels.dict_link_prev_page=Prev labels.dict_link_next_page=Next labels.dict_button_back=Back - -# synonym labels.dict_synonym_configuration=Synonym List labels.dict_synonym_title=Synonym List labels.dict_synonym_list_link=List @@ -1322,8 +1014,6 @@ labels.dict_synonym_button_update=Update labels.dict_synonym_button_download=Download labels.dict_synonym_button_upload=Upload labels.dict_synonym_file=Synonym File - -# userdict labels.dict_userdict_configuration=UserDict List labels.dict_userdict_title=UserDict List labels.dict_userdict_list_link=List @@ -1346,8 +1036,6 @@ labels.dict_userdict_button_update=Update labels.dict_userdict_button_download=Download labels.dict_userdict_button_upload=Upload labels.dict_userdict_file=UserDict File - -# boost document rule labels.boost_document_rule_configuration=Doc Boost labels.boost_document_rule_title_list=Doc Boost labels.boost_document_rule_title_confirm=Confirm Doc Boost @@ -1373,8 +1061,6 @@ labels.boost_document_rule_list_url_expr=Condition labels.boost_document_rule_url_expr=Condition labels.boost_document_rule_boost_expr=Boost Expr labels.boost_document_rule_sort_order=Sort Order - -# suggest\u3000elevate\u3000word labels.suggest_elevate_word_configuration=Additional Word labels.suggest_elevate_word_title_list=Additional Word labels.suggest_elevate_word_title_confirm=Confirm Additional Word @@ -1407,8 +1093,6 @@ labels.suggest_elevate_word_target_role=Role labels.suggest_elevate_word_target_label=Label labels.suggest_elevate_word_boost=Boost labels.suggest_elevate_word_file=Additional Word File - -# suggest bad word labels.suggest_bad_word_configuration=Bad Word labels.suggest_bad_word_title_list=Bad Word labels.suggest_bad_word_title_confirm=Confirm Bad Word @@ -1439,18 +1123,78 @@ labels.suggest_bad_word_suggest_word=Bad Word labels.suggest_bad_word_target_role=Role labels.suggest_bad_word_target_label=Label labels.suggest_bad_word_file=Bad Word File - -# CRUD PROPERTIES: BEGIN -errors.crud_invalid_mode=Invalid mode(expected value is {0}, but it's {1}). -errors.crud_failed_to_create_crud_table=Failed to create a new data. -errors.crud_failed_to_update_crud_table=Failed to update the data. -errors.crud_failed_to_delete_crud_table=Failed to delete the data. -errors.crud_could_not_find_crud_table=Could not find the data({0}). - -success.crud_create_crud_table=Created data. -success.crud_update_crud_table=Updated data. -success.crud_delete_crud_table=Deleted data. - +labels.user_configuration=User +labels.user_link_create_new=Create New +labels.user_link_list=List +labels.user_link_create=Create New +labels.user_link_update=Edit +labels.user_link_delete=Delete +labels.user_link_confirm=Details +labels.user_link_details=Details +labels.user_link_edit=Edit +labels.user_link_delete=Delete +labels.user_link_prev_page=Prev +labels.user_link_next_page=Next +labels.user_list_name=Name +labels.user_name=Name +labels.user_password=Password +labels.user_confirm_password=Confirm +labels.user_role=Role +labels.user_group=Group +labels.user_title_details=User +labels.user_button_create=Create +labels.user_button_back=Back +labels.user_button_confirm=Confirm +labels.user_title_confirm=Confirm User +labels.user_button_update=Update +labels.user_button_delete=Delete +labels.user_button_edit=Edit +labels.role_configuration=Role +labels.role_link_create_new=Create New +labels.role_link_list=List +labels.role_link_create=Create New +labels.role_link_update=Edit +labels.role_link_delete=Delete +labels.role_link_confirm=Details +labels.role_link_details=Details +labels.role_link_edit=Edit +labels.role_link_delete=Delete +labels.role_link_prev_page=Prev +labels.role_link_next_page=Next +labels.role_list_name=Name +labels.role_name=Name +labels.role_title_details=Role +labels.role_button_create=Create +labels.role_button_back=Back +labels.role_button_confirm=Confirm +labels.role_title_confirm=Confirm Role +labels.role_button_update=Update +labels.role_button_delete=Delete +labels.role_button_edit=Edit +labels.group_configuration=group +labels.group_link_create_new=Create New +labels.group_link_list=List +labels.group_link_create=Create New +labels.group_link_update=Edit +labels.group_link_delete=Delete +labels.group_link_confirm=Details +labels.group_link_details=Details +labels.group_link_edit=Edit +labels.group_link_delete=Delete +labels.group_link_prev_page=Prev +labels.group_link_next_page=Next +labels.group_list_name=Name +labels.group_name=Name +labels.group_title_details=Group +labels.group_button_create=Create +labels.group_button_back=Back +labels.group_button_confirm=Confirm +labels.group_title_confirm=Confirm Group +labels.group_button_update=Update +labels.group_button_delete=Delete +labels.group_button_edit=Edit +labels.roles=Roles +labels.groups=Groups labels.crud_button_create=Create labels.crud_button_update=Update labels.crud_button_delete=Delete @@ -1459,14 +1203,11 @@ labels.crud_button_edit=Edit labels.crud_button_confirm=Confirm labels.crud_button_search=Search labels.crud_button_reset=Reset - labels.crud_link_create_new=Create New labels.crud_link_delete=Delete labels.crud_link_back=Back labels.crud_link_edit=Edit labels.crud_link_next_page=Next labels.crud_link_prev_page=Back - labels.crud_title_details=Details labels.crud_title_confirm=Confirmation -# CRUD PROPERTIES: END diff --git a/src/main/resources/application_en.properties b/src/main/resources/fess_label_en.properties similarity index 80% rename from src/main/resources/application_en.properties rename to src/main/resources/fess_label_en.properties index 20b0e73c9..b48a29ccd 100644 --- a/src/main/resources/application_en.properties +++ b/src/main/resources/fess_label_en.properties @@ -1,124 +1,3 @@ -errors.front_header=
    -errors.front_footer=
    -errors.front_prefix=
    -errors.front_suffix=
    -errors.header=
    -errors.footer=
    -errors.prefix=

    -errors.suffix=

    -errors.invalid={0} is invalid. -errors.maxlength={0} can not be greater than {1} characters. -errors.minlength={0} can not be less than {1} characters. -errors.maxbytelength={0} can not be greater than {1} bytes. -errors.minbytelength={0} can not be less than {1} bytes. -errors.range={0} is not in the range {1} through {2}. -errors.required={0} is required. -errors.byte={0} must be an byte. -errors.date={0} is not a date. -errors.double={0} must be an double. -errors.float={0} must be an float. -errors.integer={0} must be an integer. -errors.long={0} must be an long. -errors.short={0} must be an short. -errors.creditcard={0} is not a valid credit card number. -errors.email={0} is an invalid e-mail address. -errors.url={0} is an invalid url (web address). -errors.cronexpression={0} is a invalid format. -errors.uritype={0} is a invalid uri. -errors.alphaDigitOnly={0} must be alphabet or digit only. -errors.alphaDigitSpaceOnly={0} must be alphabet, digit, or space only. -errors.token=Invalid request. - -errors.failed_to_update_crawler_params=Failed to update parameters. Please contact to a site administrator. -errors.failed_to_update_web_crawler_params=Failed to update parameters. Please contact to a site administrator. -errors.failed_to_update_solr_params=Failed to update parameters. Please contact to a site administrator. -error.login_error=Username or Password is not correct. -errors.failed_to_commit_solr_index=Failed to commit index. -errors.failed_to_optimize_solr_index=Failed to optimize index. -errors.failed_to_delete_solr_index=Failed to delete index. -errors.failed_to_start_solr_process_because_of_running=Failed to start a process because of running solr process. -errors.failed_to_import_data=Failed to restore data. -errors.unknown_import_file=Unknown file type. -errors.failed_to_export_data=Failed to backup data. -errors.could_not_find_log_file=Could not find {0}. -errors.no_running_crawl_process=No running crawl process. -errors.failed_to_start_crawl_process=Failed to start a crawl process. -errors.invalid_design_jsp_file_name=Invalid JSP file. -errors.design_jsp_file_does_not_exist=JSP file does not exist. -errors.design_file_name_is_not_found=The file name is not specified. -errors.failed_to_write_design_image_file=Failed to upload an image file. -errors.failed_to_update_jsp_file=Failed to update a jsp file. -errors.design_file_name_is_invalid=The file name is invalid. -errors.design_file_is_unsupported_type=The kind of file is unsupported. -errors.failed_to_start_solr_instance=Failed to start a solr instance. -errors.failed_to_stop_solr_instance=Failed to stop a solr instance. -errors.failed_to_reload_solr_instance=Failed to reload a solr instance. -errors.failed_to_update_crawler_schedule=Failed to update a crawling schedule. -errors.failed_to_create_crawling_config_at_wizard=Failed to create a crawling config. -errors.design_editor_disabled=This feature is disabled. -errors.could_not_create_search_log_csv=Could not create a search log csv file. -errors.not_found_on_file_system=Not Found: {0} -errors.could_not_open_on_system=Could not open {0}.
    Please check if the file is associated with an application. -errors.process_time_is_exceeded=The limit of a search time was exceeded. The partial result was displayed. -errors.result_size_exceeded=No more results could be displayed. -errors.target_file_does_not_exist={0} file does not exist. -errors.failed_to_download_file=Failed to download {0} file. -errors.failed_to_delete_file=Failed to delete {0} file. -errors.failed_to_redirect=Failed to redirect {0}. -errors.unsupported_encoding={0} is not supported as encoding. -errors.docid_not_found=Not found Doc ID:{0} -errors.document_not_found=Not found URL of Doc ID:{0} -errors.not_load_from_server=Could not load from this server: {0} -errors.failed_to_start_job=Failed to start job {0}. -errors.failed_to_stop_job=Failed to stop job {0}. -errors.expired_dict_id=Expired dictionary information. Please reload it. -errors.failed_to_create_cache=Failed to create a cache reponse for ID:{0}. -errors.synonym_file_is_not_found=Synonym file is not found -errors.failed_to_download_synonym_file=Failed to download the Synonym file. -errors.failed_to_upload_synonym_file=Failed to upload the Synonym file. -errors.userdict_file_is_not_found=Synonym file is not found -errors.failed_to_download_userdict_file=Failed to download the UserDict file. -errors.failed_to_upload_userdict_file=Failed to upload the UserDict file. - -errors.invalid_query_unknown=The given query is invalid. -errors.invalid_query_quoted=An invalid quote character is used. -errors.invalid_query_curly_bracket=An invalid curly bracket character is used. -errors.invalid_query_square_bracket=An invalid square bracket character is used. -errors.invalid_query_parenthesis=An invalid parenthesis character is used. -errors.invalid_query_num_range=An invalid range is used. The example of the range format is "field:[20020101 TO 20030101]". -errors.invalid_query_str_range=An invalid range is used. The example of the range format is "field:'{'Aida TO Carmen'}'". - -success.update_crawler_params=Updated parameters. -success.update_web_crawler_params=Updated parameters. -success.update_solr_params=Updated parameters. -success.commit_solr_index=Started a process to commit index. -success.optimize_solr_index=Started a process to optimize index. -success.delete_solr_index=Started a process to optimize index. -success.importing_data=Started to restore data from the uploaded file. -success.crawling_session_delete_all=Deleted session data. -success.start_crawl_process=Started a crawl process. -success.stopping_crawl_process=Stopping a crawl process. -success.upload_design_file=Uploaded {0}. -success.update_design_jsp_file=Updated {0}. -success.starting_solr_instance=Starting a solr instance. -success.stopping_solr_instance=Stopping a solr instance. -success.reloading_solr_instance=Reloading a solr instance. -success.update_crawler_schedule=Updated a crawling schedule. -success.create_crawling_config_at_wizard=Created a crawling config ({0}). -success.search_log_delete_all=Deleted search logs. -success.failure_url_delete_all=Deleted failure urls. -success.delete_file=Deleted {0} file. -success.user_info_delete_all=Deleted user information. -success.favorite_log_delete_all=Deleted popular urls -success.job_started=Started job {0}. -success.job_stopped=Stopped job {0}. -success.joblog_delete_all=Deleted job logs. -success.upload_synonym_file=Uploaded Synonym file. -success.upload_userdict_file=Uploaded UserDict file. -success.upload_suggest_elevate_word=Uploaded Additional Word file. -success.upload_suggest_bad_word=Uploaded Bad Word file. - -# labels labels.authRealm=Realm labels.available=Status labels.createdBy=Created by @@ -288,12 +167,6 @@ labels.synonymFile=Synonym File labels.userDictFile=UserDict File labels.suggestElevateWordFile=Additional Word File labels.suggestBadWordFile=Bad Word File - -# view/common/common.jsp - -# view/common/admin/layout.jsp - -# view/common/admin/menu.jsp labels.menu_system=System labels.menu.wizard=Wizard labels.menu.crawl_config=General @@ -303,7 +176,6 @@ labels.menu.document_config=Index labels.menu.design=Design labels.menu.dict=Dictionary labels.menu.data=Backup/Restore - labels.menu_crawl=Crawler labels.menu.web=Web labels.menu.file_system=File System @@ -317,11 +189,13 @@ labels.menu.file_authentication=File Authentication labels.menu.request_header=Request Header labels.menu.overlapping_host=Overlapping Host labels.menu.role_type=Role - +labels.menu_user=User +labels.menu.user=User +labels.menu.role=Role +labels.menu.group=Group labels.menu_suggest=Suggest labels.menu.suggest_elevate_word=Additional Word labels.menu.suggest_bad_word=Bad Word - labels.menu_system_log=System Info labels.menu.system_info=Config Info labels.menu.session_info=Session Info @@ -329,24 +203,15 @@ labels.menu.log=Log Files labels.menu.jobLog=Job Log labels.menu.failure_url=Failure URL labels.menu.search_list=Search - labels.menu_user_log=User Info labels.menu.search_log=Search Log labels.menu.stats=Statistics -labels.menu.user=Users labels.menu.favoriteLog=Popular URL - labels.menu.logout=Logout - -# view/common/admin/header.jsp labels.header.logo_alt=Fess labels.header.home=Home labels.header.help=Help - -# view/common/admin/footer.jsp labels.footer.copyright=Copyright(C) 2009-2015 CodeLibs Project. All Rights Reserved. - -# view/search.jsp labels.search=Search labels.search_result_status=Results {2} - {3} of {1} pages for {0} labels.search_result_time=({0} sec) @@ -372,34 +237,12 @@ labels.search_result_sort_favoriteCount_asc=Favorite (ascending) labels.search_result_sort_favoriteCount_desc=Favorite (descending) labels.search_result_size={0} bytes labels.search_result_created=Registered: -labels.search_result_lastModified=Last Modified: +labels.search_result_last_modified=Last Modified: labels.search_result_favorite=Vote it labels.search_result_favorited=Voted labels.search_click_count=Click: {0} labels.search_result_more=more.. labels.search_result_cache=Cache - -label.facet_label_title=Label -label.facet_lastModified_title=Term -label.facet_lastModified_1day=Past 24 Hours -label.facet_lastModified_1week=Past Week -label.facet_lastModified_1month=Past Month -label.facet_lastModified_1year=Past Year -label.facet_contentLength_title=Size -label.facet_contentLength_10k=  - 10kb -label.facet_contentLength_10kto100k=10kb - 100kb -label.facet_contentLength_100kto500k=100kb - 500kb -label.facet_contentLength_500kto1m=500kb - 1mb -label.facet_contentLength_1m=1mb -   -label.facet_filetype_title=File Type -label.facet_filetype_html=HTML -label.facet_filetype_word=Word -label.facet_filetype_excel=Excel -label.facet_filetype_powerpoint=PowerPoint -label.facet_filetype_pdf=PDF -label.facet_filetype_others=PDF -label.facet_label_reset=Reset - labels.searchoptions_all=All labels.searchoptions_score=Score labels.searchoptions_menu_sort=Sort: @@ -408,21 +251,13 @@ labels.searchoptions_num={0} results labels.searchoptions_menu_lang=Language: labels.searchoptions_menu_labels=Labels: labels.searchheader_username=Username: {0} - -# view/error.jsp labels.error_title=Error - -# view/error/system.jsp labels.system_error_title=System Error labels.contact_site_admin=Contact the Site Administrator. labels.request_error_title=Bad Request labels.bad_request=Invalid request for the url. - -# view/error/notFound.jsp labels.page_not_found_title=Page Not Found labels.check_url=Check the url. - -# view/login/index.jsp labels.home=Home labels.user_name=User Name labels.login=Login @@ -432,14 +267,10 @@ labels.index_label=Labels labels.index_lang=Languages labels.index_sort=Sort labels.index_num=Results per page - -# view/login/logout.jsp labels.logout_title=Logout labels.logout=Logout labels.do_you_want_to_logout=Do you want to logout? labels.logout_button=Logout - -# view/index.jsp labels.top.search=Search labels.search_top_logo_alt=Fess labels.index_title=Fess @@ -458,15 +289,9 @@ labels.search_options_close=Close labels.search_options_clear=Clear labels.search_cache_msg=This is a cache of {0}. It is a snapshot of the page at {1}. labels.search_unknown=Unknown - -# view/footer.jsp labels.footer_back_to_top=Back to top - -# view/header.jsp labels.header_brand_name=Fess labels.header_form_option_btn=Options - -# view/admin/fileCrawlingConfig/edit.jsp labels.file_crawling_configuration=File Crawling Configuration labels.file_crawling_title_details=File Crawling Configuration labels.included_paths=Included Paths For Crawling @@ -483,16 +308,10 @@ labels.label_type=Label labels.file_crawling_button_create=Create labels.file_crawling_button_back=Back labels.file_crawling_button_confirm=Confirm - -# view/admin/fileCrawlingConfig/confirm.jsp labels.file_crawling_title_confirm=Confirm File Crawling Configuration labels.file_crawling_button_update=Update labels.file_crawling_button_delete=Delete labels.file_crawling_button_edit=Edit - -# view/admin/fileCrawlingConfig/error.jsp - -# view/admin/fileCrawlingConfig/index.jsp labels.file_crawling_link_create_new=Create New labels.file_crawling_link_list=List labels.file_crawling_link_create=Create New @@ -504,8 +323,6 @@ labels.file_crawling_link_edit=Edit labels.file_crawling_link_delete=Delete labels.file_crawling_link_prev_page=Prev labels.file_crawling_link_next_page=Next - -# view/admin/webCrawlingConfig/edit.jsp labels.web_crawling_configuration=Web Crawling Configuration labels.web_crawling_title_details=Web Crawling Configuration labels.included_urls=Included URLs For Crawling @@ -516,16 +333,10 @@ labels.user_agent=User Agent labels.web_crawling_button_create=Create labels.web_crawling_button_back=Back labels.web_crawling_button_confirm=Confirm - -# view/admin/webCrawlingConfig/confirm.jsp labels.web_crawling_title_confirm=Confirm Web Crawling Configuration labels.web_crawling_button_update=Update labels.web_crawling_button_delete=Delete labels.web_crawling_button_edit=Edit - -# view/admin/webCrawlingConfig/error.jsp - -# view/admin/webCrawlingConfig/index.jsp labels.web_crawling_link_create_new=Create New labels.web_crawling_link_list=List labels.web_crawling_link_create=Create New @@ -537,8 +348,6 @@ labels.web_crawling_link_edit=Edit labels.web_crawling_link_delete=Delete labels.web_crawling_link_prev_page=Prev labels.web_crawling_link_next_page=Next - -# view/admin/crawl/index.jsp labels.crawler_configuration=General Configuration labels.crawler_title_edit=General Configuration labels.schedule=Schedule @@ -576,8 +385,6 @@ labels.purge_user_info_day=Purge User Before labels.purge_by_bots=Bots Name For Purge labels.csv_file_encoding=Encoding for CSV labels.notification_to=Notification Email - -# view/admin/filePathMapping/edit.jsp labels.path_mapping_configuration=Path Mapping Configuration labels.path_mapping_title_details=Path Mapping labels.path_mapping_button_create=Create @@ -587,8 +394,6 @@ labels.disabled=Disabled labels.path_mapping_pt_crawling=Crawling labels.path_mapping_pt_displaying=Displaying labels.path_mapping_pt_both=Crawling/Displaying - -# view/admin/filePathMapping/confirm.jsp labels.path_mapping_title_confirm=Confirm Path Mapping labels.regular_name=Regular Name labels.overlapping_name=Overlapping Name @@ -597,10 +402,6 @@ labels.path_mapping_button_back=Back labels.path_mapping_button_update=Update labels.path_mapping_button_delete=Delete labels.path_mapping_button_edit=Edit - -# view/admin/filePathMapping/error.jsp - -# view/admin/filePathMapping/index.jsp labels.path_mapping_link_create_new=Create New labels.path_mapping_link_list=List labels.path_mapping_link_create=Create New @@ -612,25 +413,17 @@ labels.path_mapping_link_edit=Edit labels.path_mapping_link_delete=Delete labels.path_mapping_link_prev_page=Prev labels.path_mapping_link_next_page=Next - -# view/admin/overlappingHost/edit.jsp labels.overlapping_host_configuration=Overlapping Host Configuration labels.overlapping_host_title_details=Overlapping Host labels.overlapping_host_button_create=Create labels.overlapping_host_button_back=Back labels.overlapping_host_button_confirm=Confirm - -# view/admin/overlappingHost/confirm.jsp labels.overlapping_host_title_confirm=Confirm Overlapping Host labels.overlapping_host_button_create=Create labels.overlapping_host_button_back=Back labels.overlapping_host_button_update=Update labels.overlapping_host_button_delete=Delete labels.overlapping_host_button_edit=Edit - -# view/admin/overlappingHost/error.jsp - -# view/admin/overlappingHost/index.jsp labels.overlapping_host_link_create_new=Create New labels.overlapping_host_link_list=List labels.overlapping_host_link_create=Create New @@ -642,8 +435,6 @@ labels.overlapping_host_link_edit=Edit labels.overlapping_host_link_delete=Delete labels.overlapping_host_link_prev_page=Prev labels.overlapping_host_link_next_page=Next - -# view/admin/solr/index.jsp labels.system_title_configuration=System Configuration labels.system_title_system_status=System Status labels.es_button_update=Update @@ -694,19 +485,14 @@ labels.suggest_type_content=content labels.suggest_type_searchlog=search words labels.suggest_search_log_enabled=Suggest by Search Words labels.purge_suggest_search_log_day=Purge Suggest Docs by Search Words - -# view/admin/crawlingSession/confirm.jsp labels.crawling_session_title=Session Information labels.crawling_session_title_confirm=Crawling Information labels.crawling_session_button_back=Back labels.crawling_session_button_delete=Delete - -# view/admin/crawlingSession/error.jsp - -# view/admin/crawlingSession/index.jsp labels.crawling_session_configuration=Crawling Session labels.crawling_session_search=Search labels.crawling_session_reset=Reset +labels.crawling_session_link_list=List labels.crawling_session_link_details=Details labels.crawling_session_link_delete=Delete labels.crawling_session_prev_page=Prev @@ -718,7 +504,6 @@ labels.crawling_session_created_time=Created labels.crawling_session_expired_time=Expired labels.crawling_session_delete_all_link=Delete All labels.crawling_session_delete_all_confirmation=Do you want to delete all? - labels.crawling_session_CrawlerStatus=Crawling Status labels.crawling_session_CrawlerStartTime=Start Time (Crawling) labels.crawling_session_CrawlerEndTime=End Time (Crawling) @@ -743,8 +528,6 @@ labels.crawling_session_ReplicationStatus=Replication Status labels.crawling_session_ReplicationStartTime=Start Time (Replication) labels.crawling_session_ReplicationEndTime=End Time (Replication) labels.crawling_session_ReplicationExecTime=Exec Time (Replication) - -# view/admin/data/index.jsp labels.data_configuration=Backup/Restore Configuration labels.backup_title_edit=Backup labels.backup=Backup @@ -757,8 +540,6 @@ labels.backup_config=Confinguration labels.backup_session_info=Session Info labels.backup_search_log=Search Log labels.backup_click_log=Click Long - -# view/admin/webAuthentication/index.jsp labels.web_authentication_configuration=Web Authentication labels.web_authentication_link_create_new=Create New labels.web_authentication_link_list=List @@ -776,8 +557,6 @@ labels.web_authentication_list_realm=Realm labels.web_authentication_list_web_crawling_config=Config Name labels.web_authentication_any=Any labels.web_authentication_create_web_config=Create New Web Config - -# view/admin/webAuthentication/edit.jsp labels.web_authentication_title_details=Web Authentication labels.web_authentication_button_create=Create labels.web_authentication_button_back=Back @@ -793,20 +572,14 @@ labels.web_authentication_web_crawling_config=Web Config labels.web_authentication_scheme_basic=Basic labels.web_authentication_scheme_digest=Digest labels.web_authentication_scheme_ntlm=NTLM - -# view/admin/webAuthentication/confirm.jsp labels.web_authentication_title_confirm=Web Authentication labels.web_authentication_button_update=Update labels.web_authentication_button_delete=Delete labels.web_authentication_button_edit=Edit - -# view/admin/log/confirm.jsp labels.log_configuration=Log Files labels.log_file_download_title=Log Files labels.log_file_name=File Name labels.log_file_date=Timestamp - -# view/admin/labelType/edit.jsp labels.labeltype_configuration=Label labels.labeltype_title_details=Label labels.labeltype_button_create=Create @@ -814,8 +587,6 @@ labels.labeltype_button_back=Back labels.labeltype_button_confirm=Confirm labels.labeltype_name=Name labels.labeltype_value=Value - -# view/admin/labelType/confirm.jsp labels.labeltype_title_confirm=Confirm Label labels.labeltype_button_create=Create labels.labeltype_button_back=Back @@ -824,8 +595,6 @@ labels.labeltype_button_delete=Delete labels.labeltype_button_edit=Edit labels.labeltype_included_paths=Included Paths labels.labeltype_excluded_paths=Excluded Paths - -# view/admin/labeltype/index.jsp labels.labeltype_link_create_new=Create New labels.labeltype_link_list=List labels.labeltype_link_create=Create New @@ -837,8 +606,6 @@ labels.labeltype_link_edit=Edit labels.labeltype_link_delete=Delete labels.labeltype_link_prev_page=Prev labels.labeltype_link_next_page=Next - -# view/admin/roleType/edit.jsp labels.roletype_configuration=Role labels.roletype_title_details=Role labels.roletype_button_create=Create @@ -846,16 +613,12 @@ labels.roletype_button_back=Back labels.roletype_button_confirm=Confirm labels.roletype_name=Name labels.roletype_value=Value - -# view/admin/roleType/confirm.jsp labels.roletype_title_confirm=Confirm Role labels.roletype_button_create=Create labels.roletype_button_back=Back labels.roletype_button_update=Update labels.roletype_button_delete=Delete labels.roletype_button_edit=Edit - -# view/admin/roletype/index.jsp labels.roletype_link_create_new=Create New labels.roletype_link_list=List labels.roletype_link_create=Create New @@ -867,8 +630,6 @@ labels.roletype_link_edit=Edit labels.roletype_link_delete=Delete labels.roletype_link_prev_page=Prev labels.roletype_link_next_page=Next - -# view/admin/requestHeader/index.jsp labels.request_header_configuration=Request Header labels.request_header_link_create_new=Create New labels.request_header_link_list=List @@ -884,8 +645,6 @@ labels.request_header_link_next_page=Next labels.request_header_list_name=Name labels.request_header_list_web_crawling_config=Config Name labels.request_header_create_web_config=Create New Web Config - -# view/admin/requestHeader/edit.jsp labels.request_header_title_details=Request Header labels.request_header_button_create=Create labels.request_header_button_back=Back @@ -893,14 +652,10 @@ labels.request_header_button_confirm=Confirm labels.request_header_name=Name labels.request_header_value=Value labels.request_header_web_crawling_config=Web Config - -# view/admin/requestHeader/confirm.jsp labels.request_header_title_confirm=Request Header labels.request_header_button_update=Update labels.request_header_button_delete=Delete labels.request_header_button_edit=Edit - -# view/admin/keyMatch/index.jsp labels.key_match_configuration=Key Match labels.key_match_link_create_new=Create New labels.key_match_link_list=List @@ -919,22 +674,16 @@ labels.key_match_term=Term labels.key_match_query=Query labels.key_match_size=Size labels.key_match_boost=Boost - -# view/admin/keyMatch/edit.jsp labels.key_match_title_details=Key Match labels.key_match_button_create=Create labels.key_match_button_back=Back labels.key_match_button_confirm=Confirm labels.key_match_name=Name labels.key_match_value=Value - -# view/admin/keyMatch/confirm.jsp labels.key_match_title_confirm=Confirm Key Match labels.key_match_button_update=Update labels.key_match_button_delete=Delete labels.key_match_button_edit=Edit - -# view/admin/design/index.jsp labels.design_configuration=Design labels.design_title_file_upload=File Upload labels.design_title_file=File Manager @@ -962,13 +711,9 @@ labels.design_file_errorSystem=Error Page (System Error) labels.design_file_errorRedirect=Error Page (Redirect) labels.design_file_errorBadRequest=Error Page (BadRequest) labels.design_delete_confirmation=Do you want to delete it? - -# view/admin/design/edit.jsp labels.design_title_edit_content=Edit Page View File labels.design_button_update=Update labels.design_button_back=Back - -# view/admin/dataCrawlingConfig/edit.jsp labels.data_crawling_configuration=Data Crawling Configuration labels.data_crawling_title_details=Data Crawling Configuration labels.handler_name=Handler Name @@ -979,16 +724,10 @@ labels.label_type=Label labels.data_crawling_button_create=Create labels.data_crawling_button_back=Back labels.data_crawling_button_confirm=Confirm - -# view/admin/dataCrawlingConfig/confirm.jsp labels.data_crawling_title_confirm=Confirm Data Crawling Configuration labels.data_crawling_button_update=Update labels.data_crawling_button_delete=Delete labels.data_crawling_button_edit=Edit - -# view/admin/dataCrawlingConfig/error.jsp - -# view/admin/dataCrawlingConfig/index.jsp labels.data_crawling_link_create_new=Create New labels.data_crawling_link_list=List labels.data_crawling_link_create=Create New @@ -1000,14 +739,10 @@ labels.data_crawling_link_edit=Edit labels.data_crawling_link_delete=Delete labels.data_crawling_link_prev_page=Prev labels.data_crawling_link_next_page=Next - -# view/admin/wizard/index.jsp labels.wizard_title_configuration=Configuration Wizard labels.wizard_start_title=Configuration Wizard labels.wizard_start_desc=Using Configuration Wizard, you can create crawling settings easily. labels.wizard_start_button=Start - -# view/admin/wizard/schduleForm.jsp labels.wizard_schedule_title=Crawling Schedule labels.wizard_schedule_enabled=Use Schedule labels.wizard_schedule=Schedule @@ -1023,8 +758,6 @@ labels.wizard_button_next=Next labels.wizard_button_skip=Skip labels.wizard_button_cancel=Cancel labels.wizard_button_back=Back - -# view/admin/wizard/schduleForm.jsp labels.wizard_crawling_config_title=Crawling Configuration labels.wizard_crawling_config_name=Name labels.wizard_crawling_config_path=Crawling Path @@ -1040,23 +773,15 @@ labels.wizard_schedule_day_sat=Sat labels.wizard_schedule_day_m_f=Mon-Fri labels.wizard_schedule_day_mwf=Mon,Wed,Fri labels.wizard_schedule_day_tt=Tue,Thu - -# view/admin/wizard/startCrawling.jsp labels.wizard_start_crawling_title=Start Crawling labels.wizard_start_crawling_desc=To click "Start Crawling" button, you can start a crawling now. labels.wizard_button_start_crawling=Start Crawling labels.wizard_button_finish=Finish - -# view/admin/searchList/index.jsp labels.search_list_configuration=Search Result labels.search_list_index_page=Type a search query. - -# view/admin/searchList/confirmDelete.jsp labels.search_list_title_confirm_delete=Delete Confirmation labels.search_list_url=URL labels.search_list_delete_link=Delete - -# view/admin/searchLog/index.jsp labels.search_log_configuration=Search Log labels.search_log_search_word_search=Search Word labels.search_log_user_code_search=User ID @@ -1079,8 +804,6 @@ labels.search_log_search_start_page=First Query Only labels.search_log_search_term=Term labels.search_log_search_term_from=From: labels.search_log_search_term_to=To: - -# view/admin/searchLog/confirm.jsp labels.search_log_title=Search Log labels.search_log_title_confirm=Details labels.search_log_id=ID @@ -1095,8 +818,6 @@ labels.search_log_click_log_title=Click Logs labels.search_log_click_log_url=URL labels.search_log_click_log_requestedTime=Requested Time labels.search_log_access_type=Access Type - -# view/admin/failureUrl/index.jsp labels.failure_url_configuration=Failure URL labels.failure_url_search_url=URL labels.failure_url_search_error_count=Error Count @@ -1106,8 +827,6 @@ labels.failure_url_last_access_time=Last Access labels.failure_url_link_confirm=Confirm labels.failure_url_delete_all_confirmation=Do you want to delete all? labels.failure_url_error_count=Error Count - -# view/admin/failureUrl/confirm.jsp labels.failure_url_title_confirm=Failure URL Details labels.failure_url_id=ID labels.failure_url_thread_name=Thread Name @@ -1116,8 +835,6 @@ labels.failure_url_error_log=Log labels.failure_url_url=URL labels.failure_url_web_config_name=Web Crawling Configuration labels.failure_url_file_config_name=File Crawling Configuration - -# view/admin/stats/index.jsp labels.stats_configuration=Statistics labels.stats_search_report_type=Report Type labels.stats_search_term=Term @@ -1134,16 +851,12 @@ labels.stats_client_ip=Client IP labels.stats_count=Count labels.stats_click_url=Clicked URL labels.stats_favorite_url=Voted URL - -# view/admin/systemInfo/index.jsp labels.system_info_configuration=System Info labels.system_info_env_title=Env Properties labels.system_info_prop_title=System Properties labels.system_info_fess_prop_title=Fess Properties labels.system_info_bug_report_title=Properties for Bug Report labels.system_info_crawler_properties_does_not_exist=crawler.properties does not exist. Default values are applied. - -# view/admin/fileAuthentication/index.jsp labels.file_authentication_configuration=File Authentication labels.file_authentication_link_create_new=Create New labels.file_authentication_link_list=List @@ -1160,8 +873,6 @@ labels.file_authentication_list_hostname=Hostname labels.file_authentication_list_file_crawling_config=Config Name labels.file_authentication_any=Any labels.file_authentication_create_file_config=Create New File Config - -# view/admin/fileAuthentication/edit.jsp labels.file_authentication_title_details=File Authentication labels.file_authentication_button_create=Create labels.file_authentication_button_back=Back @@ -1174,17 +885,12 @@ labels.file_authentication_password=Password labels.file_authentication_parameters=Parameters labels.file_authentication_file_crawling_config=FS Config labels.file_authentication_scheme_samba=Samba - -# view/admin/fileAuthentication/confirm.jsp labels.file_authentication_title_confirm=File Authentication labels.file_authentication_button_update=Update labels.file_authentication_button_delete=Delete labels.file_authentication_button_edit=Edit - labels.pagination_page_guide_msg={0}/{1} ({2} items) labels.list_could_not_find_crud_table=No data. - -# view/admin/userInfo/index.jsp labels.user_info_configuration=User Info labels.user_info_title=User Info labels.user_info_title_confirm=Details @@ -1198,8 +904,6 @@ labels.user_info_edit_createddate=Created labels.user_info_edit_lastupdated=Last Accessed labels.user_info_delete_all_link=Delete All labels.user_info_delete_all_confirmation=Do you want to delete all? - -# view/admin/favoriteLog/index.jsp labels.favorite_log_title=Popular URL labels.favorite_log_configuration=Popular URL labels.favorite_log_user_code_search=User ID @@ -1215,8 +919,6 @@ labels.favorite_log_download_csv=Download (CSV) labels.favorite_log_search_term=Term labels.favorite_log_title_confirm=Details labels.favorite_log_id=ID - -# view/admin/ScheduledJob/edit.jsp labels.scheduledjob_configuration=Managed Jobs labels.scheduledjob_title_details=Jobs labels.scheduledjob_button_create=Create @@ -1233,8 +935,6 @@ labels.scheduledjob_crawler=Crawler Job labels.scheduledjob_running=Running labels.scheduledjob_active=Active labels.scheduledjob_nojob=- - -# view/admin/ScheduledJob/confirm.jsp labels.scheduledjob_title_confirm=Confirm Job labels.scheduledjob_button_create=Create labels.scheduledjob_button_back=Back @@ -1243,8 +943,6 @@ labels.scheduledjob_button_delete=Delete labels.scheduledjob_button_edit=Edit labels.scheduledjob_button_start=Start labels.scheduledjob_button_stop=Stop - -# view/admin/scheduledjob/index.jsp labels.scheduledjob_link_create_new=Create New labels.scheduledjob_link_list=List labels.scheduledjob_link_create=Create New @@ -1256,8 +954,6 @@ labels.scheduledjob_link_edit=Edit labels.scheduledjob_link_delete=Delete labels.scheduledjob_link_prev_page=Prev labels.scheduledjob_link_next_page=Next - -# jobLog labels.joblog_button_back=Back labels.joblog_button_create=Create labels.joblog_button_delete=Delete @@ -1287,8 +983,6 @@ labels.joblog_title_details=Job Log Details labels.joblog_title_list=Job Log List labels.joblog_delete_all_link=Delete All labels.joblog_delete_all_confirmation=Do you want to delete all? - -# dict labels.dict_configuration=Dictionary List labels.dict_list_title=Dictionary List labels.dict_list_link=Dictionaries @@ -1300,8 +994,6 @@ labels.dict_link_delete=Delete labels.dict_link_prev_page=Prev labels.dict_link_next_page=Next labels.dict_button_back=Back - -# synonym labels.dict_synonym_configuration=Synonym List labels.dict_synonym_title=Synonym List labels.dict_synonym_list_link=List @@ -1322,8 +1014,6 @@ labels.dict_synonym_button_update=Update labels.dict_synonym_button_download=Download labels.dict_synonym_button_upload=Upload labels.dict_synonym_file=Synonym File - -# userdict labels.dict_userdict_configuration=UserDict List labels.dict_userdict_title=UserDict List labels.dict_userdict_list_link=List @@ -1346,8 +1036,6 @@ labels.dict_userdict_button_update=Update labels.dict_userdict_button_download=Download labels.dict_userdict_button_upload=Upload labels.dict_userdict_file=UserDict File - -# boost document rule labels.boost_document_rule_configuration=Doc Boost labels.boost_document_rule_title_list=Doc Boost labels.boost_document_rule_title_confirm=Confirm Doc Boost @@ -1373,8 +1061,6 @@ labels.boost_document_rule_list_url_expr=Condition labels.boost_document_rule_url_expr=Condition labels.boost_document_rule_boost_expr=Boost Expr labels.boost_document_rule_sort_order=Sort Order - -# suggest\u3000elevate\u3000word labels.suggest_elevate_word_configuration=Additional Word labels.suggest_elevate_word_title_list=Additional Word labels.suggest_elevate_word_title_confirm=Confirm Additional Word @@ -1407,8 +1093,6 @@ labels.suggest_elevate_word_target_role=Role labels.suggest_elevate_word_target_label=Label labels.suggest_elevate_word_boost=Boost labels.suggest_elevate_word_file=Additional Word File - -# suggest bad word labels.suggest_bad_word_configuration=Bad Word labels.suggest_bad_word_title_list=Bad Word labels.suggest_bad_word_title_confirm=Confirm Bad Word @@ -1439,18 +1123,78 @@ labels.suggest_bad_word_suggest_word=Bad Word labels.suggest_bad_word_target_role=Role labels.suggest_bad_word_target_label=Label labels.suggest_bad_word_file=Bad Word File - -# CRUD PROPERTIES: BEGIN -errors.crud_invalid_mode=Invalid mode(expected value is {0}, but it's {1}). -errors.crud_failed_to_create_crud_table=Failed to create a new data. -errors.crud_failed_to_update_crud_table=Failed to update the data. -errors.crud_failed_to_delete_crud_table=Failed to delete the data. -errors.crud_could_not_find_crud_table=Could not find the data({0}). - -success.crud_create_crud_table=Created data. -success.crud_update_crud_table=Updated data. -success.crud_delete_crud_table=Deleted data. - +labels.user_configuration=User +labels.user_link_create_new=Create New +labels.user_link_list=List +labels.user_link_create=Create New +labels.user_link_update=Edit +labels.user_link_delete=Delete +labels.user_link_confirm=Details +labels.user_link_details=Details +labels.user_link_edit=Edit +labels.user_link_delete=Delete +labels.user_link_prev_page=Prev +labels.user_link_next_page=Next +labels.user_list_name=Name +labels.user_name=Name +labels.user_password=Password +labels.user_confirm_password=Confirm +labels.user_role=Role +labels.user_group=Group +labels.user_title_details=User +labels.user_button_create=Create +labels.user_button_back=Back +labels.user_button_confirm=Confirm +labels.user_title_confirm=Confirm User +labels.user_button_update=Update +labels.user_button_delete=Delete +labels.user_button_edit=Edit +labels.role_configuration=Role +labels.role_link_create_new=Create New +labels.role_link_list=List +labels.role_link_create=Create New +labels.role_link_update=Edit +labels.role_link_delete=Delete +labels.role_link_confirm=Details +labels.role_link_details=Details +labels.role_link_edit=Edit +labels.role_link_delete=Delete +labels.role_link_prev_page=Prev +labels.role_link_next_page=Next +labels.role_list_name=Name +labels.role_name=Name +labels.role_title_details=Role +labels.role_button_create=Create +labels.role_button_back=Back +labels.role_button_confirm=Confirm +labels.role_title_confirm=Confirm Role +labels.role_button_update=Update +labels.role_button_delete=Delete +labels.role_button_edit=Edit +labels.group_configuration=Group +labels.group_link_create_new=Create New +labels.group_link_list=List +labels.group_link_create=Create New +labels.group_link_update=Edit +labels.group_link_delete=Delete +labels.group_link_confirm=Details +labels.group_link_details=Details +labels.group_link_edit=Edit +labels.group_link_delete=Delete +labels.group_link_prev_page=Prev +labels.group_link_next_page=Next +labels.group_list_name=Name +labels.group_name=Name +labels.group_title_details=Group +labels.group_button_create=Create +labels.group_button_back=Back +labels.group_button_confirm=Confirm +labels.group_title_confirm=Confirm Group +labels.group_button_update=Update +labels.group_button_delete=Delete +labels.group_button_edit=Edit +labels.roles=Roles +labels.groups=Groups labels.crud_button_create=Create labels.crud_button_update=Update labels.crud_button_delete=Delete @@ -1459,14 +1203,11 @@ labels.crud_button_edit=Edit labels.crud_button_confirm=Confirm labels.crud_button_search=Search labels.crud_button_reset=Reset - labels.crud_link_create_new=Create New labels.crud_link_delete=Delete labels.crud_link_back=Back labels.crud_link_edit=Edit labels.crud_link_next_page=Next labels.crud_link_prev_page=Back - labels.crud_title_details=Details labels.crud_title_confirm=Confirmation -# CRUD PROPERTIES: END diff --git a/src/main/resources/application_ja.properties b/src/main/resources/fess_label_ja.properties similarity index 76% rename from src/main/resources/application_ja.properties rename to src/main/resources/fess_label_ja.properties index 797ec2e4d..27fa3b7e8 100644 --- a/src/main/resources/application_ja.properties +++ b/src/main/resources/fess_label_ja.properties @@ -1,124 +1,3 @@ -errors.front_header=
    -errors.front_footer=
    -errors.front_prefix=
    -errors.front_suffix=
    -errors.header=
    -errors.footer=
    -errors.prefix=

    -errors.suffix=

    -errors.invalid={0}\u304c\u4e0d\u6b63\u3067\u3059\u3002 -errors.maxlength={0}\u306e\u9577\u3055\u304c\u6700\u5927\u5024({1})\u3092\u8d85\u3048\u3066\u3044\u307e\u3059\u3002 -errors.minlength={0}\u306e\u9577\u3055\u304c\u6700\u5c0f\u5024({1})\u672a\u6e80\u3067\u3059\u3002 -errors.maxbytelength={0}\u306e\u30d0\u30a4\u30c8\u9577\u304c\u6700\u5927\u5024({1})\u3092\u8d85\u3048\u3066\u3044\u307e\u3059\u3002 -errors.minbytelength={0}\u306e\u30d0\u30a4\u30c8\u9577\u304c\u6700\u5c0f\u5024({1})\u672a\u6e80\u3067\u3059\u3002 -errors.range={0}\u306f{1}\u3068{2}\u306e\u9593\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.required={0}\u306f\u5fc5\u9808\u3067\u3059\u3002 -errors.byte={0}\u306f\u30d0\u30a4\u30c8\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.date={0}\u306f\u65e5\u4ed8\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093 -errors.double={0}\u306f\u500d\u7cbe\u5ea6\u5b9f\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.float={0}\u306f\u5358\u7cbe\u5ea6\u5b9f\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.integer={0}\u306f\u6574\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.long={0}\u306f\u9577\u6574\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.short={0}\u306f\u77ed\u6574\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.creditcard={0}\u306f\u30af\u30ec\u30b8\u30c3\u30c8\u30ab\u30fc\u30c9\u756a\u53f7\u3068\u3057\u3066\u4e0d\u6b63\u3067\u3059\u3002 -errors.email={0}\u306f\u30e1\u30fc\u30eb\u30a2\u30c9\u30ec\u30b9\u3068\u3057\u3066\u4e0d\u6b63\u3067\u3059\u3002 -errors.url={0}\u306fURL\u3068\u3057\u3066\u4e0d\u6b63\u3067\u3059\u3002 -errors.cronexpression={0}\u306f\u6b63\u3057\u3044\u30d5\u30a9\u30fc\u30de\u30c3\u30c8\u3067\u306f\u3042\u308a\u307e\u305b\u3093\u3002 -errors.uritype={0}\u306f\u6b63\u3057\u3044 URI \u5f62\u5f0f\u3067\u306f\u3042\u308a\u307e\u305b\u3093\u3002 -errors.alphaDigitOnly={0}\u306f\u82f1\u6570\u5b57\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.alphaDigitSpaceOnly={0}\u306f\u82f1\u6570\u5b57\u307e\u305f\u306f\u7a7a\u767d\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.token=\u4e0d\u6b63\u306a\u30ea\u30af\u30a8\u30b9\u30c8\u3067\u3059\u3002 - -errors.failed_to_update_crawler_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002\u30b5\u30a4\u30c8\u7ba1\u7406\u8005\u306b\u9023\u7d61\u3057\u3066\u304f\u3060\u3055\u3044\u3002 -errors.failed_to_update_web_crawler_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002\u30b5\u30a4\u30c8\u7ba1\u7406\u8005\u306b\u9023\u7d61\u3057\u3066\u304f\u3060\u3055\u3044\u3002 -errors.failed_to_update_solr_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002\u30b5\u30a4\u30c8\u7ba1\u7406\u8005\u306b\u9023\u7d61\u3057\u3066\u304f\u3060\u3055\u3044\u3002 -error.login_error=\u30e6\u30fc\u30b6\u30fc\u540d\u307e\u305f\u306f\u30d1\u30b9\u30ef\u30fc\u30c9\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 -errors.failed_to_commit_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u30b3\u30df\u30c3\u30c8\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_optimize_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u6700\u9069\u5316\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_delete_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u524a\u9664\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_start_solr_process_because_of_running=Solr\u30d7\u30ed\u30bb\u30b9\u304c\u5b9f\u884c\u4e2d\u306a\u306e\u3067\u3001\u51e6\u7406\u306e\u8d77\u52d5\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_import_data=\u8a2d\u5b9a\u30c7\u30fc\u30bf\u306e\u30ea\u30b9\u30c8\u30a2\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.unknown_import_file=\u672a\u77e5\u306e\u30d5\u30a1\u30a4\u30eb\u5f62\u5f0f\u3067\u3059\u3002 -errors.failed_to_export_data=\u8a2d\u5b9a\u30c7\u30fc\u30bf\u306e\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.could_not_find_log_file={0}\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 -errors.no_running_crawl_process=\u5b9f\u884c\u4e2d\u306e\u30d7\u30ed\u30bb\u30b9\u304c\u3042\u308a\u307e\u305b\u3093\u3002 -errors.failed_to_start_crawl_process=\u30af\u30ed\u30fc\u30eb\u30d7\u30ed\u30bb\u30b9\u3092\u958b\u59cb\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f\u3002 -errors.invalid_design_jsp_file_name=JSP\u30d5\u30a1\u30a4\u30eb\u540d\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 -errors.design_jsp_file_does_not_exist=JSP\u30d5\u30a1\u30a4\u30eb\u304c\u5b58\u5728\u3057\u307e\u305b\u3093\u3002 -errors.design_file_name_is_not_found=\u30d5\u30a1\u30a4\u30eb\u540d\u304c\u6307\u5b9a\u3055\u308c\u3066\u3044\u307e\u305b\u3093\u3002 -errors.failed_to_write_design_image_file=\u753b\u50cf\u30d5\u30a1\u30a4\u30eb\u306e\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u306b\u3057\u3063\u3071\u3044\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_update_jsp_file=JSP\u30d5\u30a1\u30a4\u30eb\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.design_file_name_is_invalid=\u30d5\u30a1\u30a4\u30eb\u540d\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 -errors.design_file_is_unsupported_type=\u30d5\u30a1\u30a4\u30eb\u540d\u306f\u30b5\u30dd\u30fc\u30c8\u3057\u3066\u3044\u307e\u305b\u3093\u3002 -errors.failed_to_start_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u8d77\u52d5\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_stop_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u505c\u6b62\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_reload_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u30ea\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_update_crawler_schedule=\u30af\u30ed\u30fc\u30eb\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_create_crawling_config_at_wizard=\u30af\u30ed\u30fc\u30eb\u8a2d\u5b9a\u306e\u4f5c\u6210\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.design_editor_disabled=\u3053\u306e\u6a5f\u80fd\u306f\u7121\u52b9\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002 -errors.could_not_create_search_log_csv=\u691c\u7d22\u30ed\u30b0\u306eCSV\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u6210\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f\u3002 -errors.not_found_on_file_system={0} \u306f\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 -errors.could_not_open_on_system={0}\u306f\u958b\u3051\u307e\u305b\u3093\u3067\u3057\u305f\u3002
    \u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306b\u95a2\u9023\u4ed8\u3051\u3089\u308c\u3066\u3044\u308b\u304b\u78ba\u8a8d\u3057\u3066\u304f\u3060\u3055\u3044\u3002 -errors.process_time_is_exceeded=\u691c\u7d22\u51e6\u7406\u6642\u9593\u306e\u4e0a\u9650\u3092\u8d85\u3048\u305f\u305f\u3081\u3001\u691c\u7d22\u7d50\u679c\u306e\u4e00\u90e8\u304c\u8868\u793a\u3055\u308c\u3066\u3044\u307e\u3059\u3002 -errors.result_size_exceeded=\u3053\u308c\u4ee5\u4e0a\u306e\u691c\u7d22\u7d50\u679c\u306e\u8868\u793a\u306f\u3067\u304d\u307e\u305b\u3093\u3002 -errors.target_file_does_not_exist=\u30d5\u30a1\u30a4\u30eb {0} \u304c\u5b58\u5728\u3057\u307e\u305b\u3093\u3002 -errors.failed_to_download_file={0} \u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_delete_file=\u30d5\u30a1\u30a4\u30eb {0} \u306e\u524a\u9664\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_redirect={0}\u3078\u306e\u30ea\u30c0\u30a4\u30ec\u30af\u30c8\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.unsupported_encoding={0}\u306f\u30b5\u30dd\u30fc\u30c8\u3055\u308c\u3066\u3044\u306a\u3044\u30a8\u30f3\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u3067\u3059\u3002 -errors.docid_not_found=ID:{0}\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 -errors.document_not_found=ID:{0}\u306eURL\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 -errors.not_load_from_server=\u3053\u306e\u30b5\u30fc\u30d0\u304b\u3089\u30ed\u30fc\u30c9\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f: {0} -errors.failed_to_start_job=\u30b8\u30e7\u30d6 {0} \u306e\u958b\u59cb\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_stop_job=\u30b8\u30e7\u30d6 {0} \u306e\u958b\u59cb\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.expired_dict_id=\u8f9e\u66f8\u60c5\u5831\u304c\u671f\u9650\u5207\u308c\u3067\u3059\u3002\u518d\u5ea6\u8aad\u307f\u306a\u304a\u3057\u3066\u304f\u3060\u3055\u3044\u3002 -errors.failed_to_create_cache=ID:{0}\u306e\u30ad\u30e3\u30c3\u30b7\u30e5\u304c\u751f\u6210\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f\u3002 -errors.synonym_file_is_not_found=\u540c\u7fa9\u8a9e\u30d5\u30a1\u30a4\u30eb\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 -errors.failed_to_download_synonym_file=\u540c\u7fa9\u8a9e\u30d5\u30a1\u30a4\u30eb\u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_upload_synonym_file=\u540c\u7fa9\u8a9e\u30d5\u30a1\u30a4\u30eb\u306e\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.userdict_file_is_not_found=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u30d5\u30a1\u30a4\u30eb\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 -errors.failed_to_download_userdict_file=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u30d5\u30a1\u30a4\u30eb\u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.failed_to_upload_userdict_file=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u30d5\u30a1\u30a4\u30eb\u306e\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 - -errors.invalid_query_unknown=\u691c\u7d22\u30af\u30a8\u30ea\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 -errors.invalid_query_quoted=\u30af\u30aa\u30fc\u30c8\u6587\u5b57(")\u306e\u5229\u7528\u65b9\u6cd5\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 -errors.invalid_query_curly_bracket=\u62ec\u5f27\u300c'{}'\u300d\u306e\u5229\u7528\u65b9\u6cd5\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 -errors.invalid_query_square_bracket=\u62ec\u5f27\u300c[]\u300d\u306e\u5229\u7528\u65b9\u6cd5\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 -errors.invalid_query_parenthesis=\u62ec\u5f27\u300c()\u300d\u306e\u5229\u7528\u65b9\u6cd5\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 -errors.invalid_query_num_range=\u7bc4\u56f2\u306e\u6307\u5b9a\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002\u6b63\u3057\u3044\u4f8b: field:[20020101 TO 20030101] -errors.invalid_query_str_range=\u7bc4\u56f2\u306e\u6307\u5b9a\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002\u6b63\u3057\u3044\u4f8b: "field:'{'Aida TO Carmen'}'" - -success.update_crawler_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 -success.update_web_crawler_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 -success.update_solr_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 -success.commit_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u30b3\u30df\u30c3\u30c8\u30d7\u30ed\u30bb\u30b9\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 -success.optimize_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u6700\u9069\u5316\u30d7\u30ed\u30bb\u30b9\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 -success.delete_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u524a\u9664\u30d7\u30ed\u30bb\u30b9\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 -success.importing_data=\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3055\u308c\u305f\u30d5\u30a1\u30a4\u30eb\u304b\u3089\u306e\u30c7\u30fc\u30bf\u30ea\u30b9\u30c8\u30a2\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 -success.crawling_session_delete_all=\u30bb\u30c3\u30b7\u30e7\u30f3\u30c7\u30fc\u30bf\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 -success.start_crawl_process=\u30af\u30ed\u30fc\u30eb\u30d7\u30ed\u30bb\u30b9\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 -success.stopping_crawl_process=\u30af\u30ed\u30fc\u30eb\u30d7\u30ed\u30bb\u30b9\u3092\u505c\u6b62\u3057\u3066\u3044\u307e\u3059\u3002\u3057\u3070\u3089\u304f\u304a\u5f85\u3061\u304f\u3060\u3055\u3044\u3002 -success.upload_design_file={0} \u3092\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u307e\u3057\u305f\u3002 -success.update_design_jsp_file={0} \u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 -success.starting_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u8d77\u52d5\u3057\u3066\u3044\u307e\u3059\u3002 -success.stopping_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u505c\u6b62\u3057\u3066\u3044\u307e\u3059\u3002 -success.reloading_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u30ea\u30ed\u30fc\u30c9\u3057\u3066\u3044\u307e\u3059\u3002 -success.update_crawler_schedule=\u30af\u30ed\u30fc\u30eb\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 -success.create_crawling_config_at_wizard=\u30af\u30ed\u30fc\u30eb\u8a2d\u5b9a {0} \u3092\u8ffd\u52a0\u3057\u307e\u3057\u305f\u3002 -success.search_log_delete_all=\u691c\u7d22\u30ed\u30b0\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 -success.failure_url_delete_all=\u969c\u5bb3URL\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 -success.delete_file=\u30d5\u30a1\u30a4\u30eb {0} \u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 -success.user_info_delete_all= \u5229\u7528\u8005\u60c5\u5831\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 -success.favorite_log_delete_all=\u4eba\u6c17URL\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 -success.job_started=\u30b8\u30e7\u30d6 {0} \u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 -success.job_stopped=\u30b8\u30e7\u30d6 {0} \u3092\u505c\u6b62\u3057\u307e\u3057\u305f\u3002 -success.joblog_delete_all=\u30b8\u30e7\u30d6\u30ed\u30b0\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 -success.upload_synonym_file=\u540c\u7fa9\u8a9e\u30d5\u30a1\u30a4\u30eb\u3092\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u307e\u3057\u305f\u3002 -success.upload_userdict_file=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u30d5\u30a1\u30a4\u30eb\u3092\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u307e\u3057\u305f\u3002 -success.upload_suggest_elevate_word=\u8ffd\u52a0\u5019\u88dc\u30d5\u30a1\u30a4\u30eb\u3092\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u307e\u3057\u305f\u3002 -success.upload_suggest_bad_word=NG\u30ef\u30fc\u30c9\u30d5\u30a1\u30a4\u30eb\u3092\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u307e\u3057\u305f\u3002 - -# labels labels.authRealm=\u8a8d\u8a3c\u30ec\u30eb\u30e0 labels.available=\u72b6\u614b labels.createdBy=\u4f5c\u6210\u8005 @@ -288,12 +167,6 @@ labels.synonymFile=\u540c\u7fa9\u8a9e\u30d5\u30a1\u30a4\u30eb labels.userDictFile=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u30d5\u30a1\u30a4\u30eb labels.suggestElevateWordFile=\u8ffd\u52a0\u5019\u88dc\u30d5\u30a1\u30a4\u30eb labels.suggestBadWordFile=NG\u30ef\u30fc\u30c9\u30d5\u30a1\u30a4\u30eb - -# view/common/common.jsp - -# view/common/admin/layout.jsp - -# view/common/admin/menu.jsp labels.menu_system=\u30b7\u30b9\u30c6\u30e0 labels.menu.wizard=\u8a2d\u5b9a\u30a6\u30a3\u30b6\u30fc\u30c9 labels.menu.crawl_config=\u30af\u30ed\u30fc\u30eb\u5168\u822c @@ -303,7 +176,6 @@ labels.menu.document_config=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9 labels.menu.design=\u30c7\u30b6\u30a4\u30f3 labels.menu.dict=\u8f9e\u66f8 labels.menu.data=\u30d0\u30c3\u30af\u30a2\u30c3\u30d7/\u30ea\u30b9\u30c8\u30a2 - labels.menu_crawl=\u30af\u30ed\u30fc\u30eb labels.menu.web=\u30a6\u30a7\u30d6 labels.menu.file_system=\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0 @@ -317,11 +189,13 @@ labels.menu.file_authentication=\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0 labels.menu.request_header=\u30ea\u30af\u30a8\u30b9\u30c8\u30d8\u30c3\u30c0\u30fc labels.menu.overlapping_host=\u91cd\u8907\u30db\u30b9\u30c8 labels.menu.role_type=\u30ed\u30fc\u30eb - +labels.menu_user=\u30e6\u30fc\u30b6\u30fc +labels.menu.user=\u30e6\u30fc\u30b6\u30fc +labels.menu.role=\u30ed\u30fc\u30eb +labels.menu.group=\u30b0\u30eb\u30fc\u30d7 labels.menu_suggest=\u30b5\u30b8\u30a7\u30b9\u30c8 labels.menu.suggest_elevate_word=\u8ffd\u52a0\u5019\u88dc labels.menu.suggest_bad_word=NG\u30ef\u30fc\u30c9 - labels.menu_system_log=\u30b7\u30b9\u30c6\u30e0\u60c5\u5831 labels.menu.system_info=\u8a2d\u5b9a\u60c5\u5831 labels.menu.session_info=\u30bb\u30c3\u30b7\u30e7\u30f3\u60c5\u5831 @@ -329,24 +203,15 @@ labels.menu.log=\u30ed\u30b0\u30d5\u30a1\u30a4\u30eb labels.menu.jobLog=\u30b8\u30e7\u30d6\u30ed\u30b0 labels.menu.failure_url=\u969c\u5bb3URL labels.menu.search_list=\u691c\u7d22 - labels.menu_user_log=\u5229\u7528\u8005\u60c5\u5831 labels.menu.search_log=\u691c\u7d22\u30ed\u30b0 labels.menu.stats=\u7d71\u8a08 -labels.menu.user=\u5229\u7528\u8005 labels.menu.favoriteLog=\u4eba\u6c17URL - labels.menu.logout=\u30ed\u30b0\u30a2\u30a6\u30c8 - -# view/common/admin/header.jsp labels.header.logo_alt=Fess labels.header.home=\u30db\u30fc\u30e0 labels.header.help=\u30d8\u30eb\u30d7 - -# view/common/admin/footer.jsp labels.footer.copyright=Copyright(C) 2009-2015 CodeLibs Project. All Rights Reserved. - -# view/search.jsp labels.search=\u691c\u7d22 labels.search_result_status={0} \u306e\u691c\u7d22\u7d50\u679c {1} \u4ef6\u4e2d {2} - {3} \u4ef6\u76ee labels.search_result_time=({0} \u79d2) @@ -372,34 +237,12 @@ labels.search_result_sort_favoriteCount_asc=\u304a\u6c17\u306b\u5165\u308a\u6570 labels.search_result_sort_favoriteCount_desc=\u304a\u6c17\u306b\u5165\u308a\u6570 (\u964d\u9806) labels.search_result_size={0} \u30d0\u30a4\u30c8 labels.search_result_created=\u767b\u9332\u65e5\u6642: -labels.search_result_lastModified=\u66f4\u65b0\u65e5\u6642: +labels.search_result_last_modified=\u66f4\u65b0\u65e5\u6642: labels.search_result_favorite=1\u7968\u5165\u308c\u308b labels.search_result_favorited=\u6295\u7968\u6e08\u307f labels.search_click_count=\u30af\u30ea\u30c3\u30af\u6570: {0} labels.search_result_more=\u8a73\u7d30.. labels.search_result_cache=\u30ad\u30e3\u30c3\u30b7\u30e5 - -label.facet_label_title=\u30e9\u30d9\u30eb -label.facet_lastModified_title=\u671f\u9593 -label.facet_lastModified_1day=24 \u6642\u9593\u4ee5\u5185 -label.facet_lastModified_1week=1 \u9031\u9593\u4ee5\u5185 -label.facet_lastModified_1month=1 \u30f6\u6708\u4ee5\u5185 -label.facet_lastModified_1year=1 \u5e74\u4ee5\u5185 -label.facet_contentLength_title=\u30b5\u30a4\u30ba -label.facet_contentLength_10k=  - 10KB -label.facet_contentLength_10kto100k=10KB - 100KB -label.facet_contentLength_100kto500k=100KB - 500KB -label.facet_contentLength_500kto1m=500KB - 1MB -label.facet_contentLength_1m=1MB -   -label.facet_filetype_title=\u30d5\u30a1\u30a4\u30eb\u306e\u7a2e\u985e -label.facet_filetype_html=HTML -label.facet_filetype_word=Word -label.facet_filetype_excel=Excel -label.facet_filetype_powerpoint=PowerPoint -label.facet_filetype_pdf=PDF -label.facet_filetype_others=\u305d\u306e\u4ed6 -label.facet_label_reset=\u30ea\u30bb\u30c3\u30c8 - labels.searchoptions_all=\u3059\u3079\u3066 labels.searchoptions_score=\u30b9\u30b3\u30a2 labels.searchoptions_menu_sort=\u30bd\u30fc\u30c8: @@ -408,34 +251,22 @@ labels.searchoptions_num={0} \u4ef6 labels.searchoptions_menu_lang=\u8a00\u8a9e: labels.searchoptions_menu_labels=\u30e9\u30d9\u30eb: labels.searchheader_username=\u30e6\u30fc\u30b6\u30fc\u540d: {0} - -# view/error.jsp labels.error_title=\u30a8\u30e9\u30fc - -# view/error/system.jsp labels.system_error_title=\u30b7\u30b9\u30c6\u30e0\u30a8\u30e9\u30fc labels.contact_site_admin=\u30b5\u30a4\u30c8\u7ba1\u7406\u8005\u306b\u304a\u554f\u3044\u5408\u308f\u305b\u304f\u3060\u3055\u3044\u3002 labels.request_error_title=\u30ea\u30af\u30a8\u30b9\u30c8\u30a8\u30e9\u30fc labels.bad_request=\u30da\u30fc\u30b8\u3078\u306e\u30ea\u30af\u30a8\u30b9\u30c8\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 - -# view/error/notFound.jsp labels.page_not_found_title=\u30da\u30fc\u30b8\u304c\u5b58\u5728\u3057\u307e\u305b\u3093 labels.check_url=URL\u3092\u78ba\u8a8d\u3057\u3066\u304f\u3060\u3055\u3044\u3002 - -# view/login/index.jsp labels.home=\u30db\u30fc\u30e0 labels.user_name=\u30e6\u30fc\u30b6\u30fc\u540d labels.login=\u30ed\u30b0\u30a4\u30f3 labels.login.footer_copyright=Copyright(C) 2009-2014 CodeLibs Project. All Rights Reserved. labels.login_title=\u30ed\u30b0\u30a4\u30f3 - -# view/login/logout.jsp labels.logout_title=\u30ed\u30b0\u30a2\u30a6\u30c8 labels.logout=\u30ed\u30b0\u30a2\u30a6\u30c8 labels.do_you_want_to_logout=\u30ed\u30b0\u30a2\u30a6\u30c8\u3057\u307e\u3059\u304b? labels.logout_button=\u30ed\u30b0\u30a2\u30a6\u30c8 - -# view/index.jsp labels.top.search=\u691c\u7d22 labels.search_top_logo_alt=Fess labels.index_title=Fess @@ -458,15 +289,9 @@ labels.search_options_close=\u9589\u3058\u308b labels.search_options_clear=\u30af\u30ea\u30a2 labels.search_cache_msg=\u3053\u306e\u30da\u30fc\u30b8\u306f {0} \u306e\u30ad\u30e3\u30c3\u30b7\u30e5\u3067\u3059\u3002{1} \u306b\u5b58\u5728\u3057\u3066\u3044\u305f\u30da\u30fc\u30b8\u306e\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u3067\u3059\u3002 labels.search_unknown=\u4e0d\u660e - -# view/footer.jsp labels.footer_back_to_top=\u4e0a\u90e8\u3078\u79fb\u52d5 - -# view/header.jsp labels.header_brand_name=Fess labels.header_form_option_btn=\u30aa\u30d7\u30b7\u30e7\u30f3 - -# view/admin/fileConfig/edit.jsp labels.file_crawling_configuration=\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0\u30af\u30ed\u30fc\u30eb\u306e\u8a2d\u5b9a labels.file_crawling_title_details=\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0\u30af\u30ed\u30fc\u30eb\u306e\u8a2d\u5b9a labels.included_paths=\u30af\u30ed\u30fc\u30eb\u5bfe\u8c61\u3068\u3059\u308b\u30d1\u30b9 @@ -483,16 +308,10 @@ labels.label_type=\u30e9\u30d9\u30eb labels.file_crawling_button_create=\u4f5c\u6210 labels.file_crawling_button_back=\u623b\u308b labels.file_crawling_button_confirm=\u78ba\u8a8d - -# view/admin/fileConfig/confirm.jsp labels.file_crawling_title_confirm=\u30d5\u30a1\u30a4\u30eb\u30b7\u30b9\u30c6\u30e0\u30af\u30ed\u30fc\u30eb\u306e\u8a2d\u5b9a\u306e\u78ba\u8a8d labels.file_crawling_button_update=\u66f4\u65b0 labels.file_crawling_button_delete=\u524a\u9664 labels.file_crawling_button_edit=\u7de8\u96c6 - -# view/admin/fileConfig/error.jsp - -# view/admin/fileConfig/index.jsp labels.file_crawling_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.file_crawling_link_list=\u4e00\u89a7 labels.file_crawling_link_create=\u65b0\u898f\u4f5c\u6210 @@ -504,8 +323,6 @@ labels.file_crawling_link_edit=\u7de8\u96c6 labels.file_crawling_link_delete=\u524a\u9664 labels.file_crawling_link_prev_page=\u524d\u3078 labels.file_crawling_link_next_page=\u6b21\u3078 - -# view/admin/webConfig/edit.jsp labels.web_crawling_configuration=\u30a6\u30a7\u30d6\u30af\u30ed\u30fc\u30eb\u306e\u8a2d\u5b9a labels.web_crawling_title_details=\u30a6\u30a7\u30d6\u30af\u30ed\u30fc\u30eb\u306e\u8a2d\u5b9a labels.included_urls=\u30af\u30ed\u30fc\u30eb\u5bfe\u8c61\u3068\u3059\u308bURL @@ -516,16 +333,10 @@ labels.user_agent=\u30e6\u30fc\u30b6\u30fc\u30a8\u30fc\u30b8\u30a7\u30f3\u30c8 labels.web_crawling_button_create=\u4f5c\u6210 labels.web_crawling_button_back=\u623b\u308b labels.web_crawling_button_confirm=\u78ba\u8a8d - -# view/admin/webConfig/confirm.jsp labels.web_crawling_title_confirm=\u30a6\u30a7\u30d6\u30af\u30ed\u30fc\u30eb\u306e\u8a2d\u5b9a\u306e\u78ba\u8a8d labels.web_crawling_button_update=\u66f4\u65b0 labels.web_crawling_button_delete=\u524a\u9664 labels.web_crawling_button_edit=\u7de8\u96c6 - -# view/admin/webConfig/error.jsp - -# view/admin/webConfig/index.jsp labels.web_crawling_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.web_crawling_link_list=\u4e00\u89a7 labels.web_crawling_link_create=\u65b0\u898f\u4f5c\u6210 @@ -537,8 +348,6 @@ labels.web_crawling_link_edit=\u7de8\u96c6 labels.web_crawling_link_delete=\u524a\u9664 labels.web_crawling_link_prev_page=\u524d\u3078 labels.web_crawling_link_next_page=\u6b21\u3078 - -# view/admin/crawl/index.jsp labels.crawler_configuration=\u30af\u30ed\u30fc\u30eb\u5168\u822c\u306e\u8a2d\u5b9a labels.crawler_title_edit=\u30af\u30ed\u30fc\u30eb\u5168\u822c\u306e\u8a2d\u5b9a labels.schedule=\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb @@ -576,8 +385,6 @@ labels.purge_user_info_day=\u6307\u5b9a\u65e5\u6570\u4ee5\u524d\u306e\u5229\u752 labels.purge_by_bots=\u30ed\u30b0\u524a\u9664\u306eBots\u540d labels.csv_file_encoding=CSV\u30a8\u30f3\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0 labels.notification_to=\u901a\u77e5\u30a2\u30c9\u30ec\u30b9 - -# view/admin/filePathMapping/edit.jsp labels.path_mapping_configuration=\u30d1\u30b9\u30de\u30c3\u30d4\u30f3\u30b0\u306e\u8a2d\u5b9a labels.path_mapping_title_details=\u30d1\u30b9\u30de\u30c3\u30d4\u30f3\u30b0\u306e\u8a2d\u5b9a labels.path_mapping_button_create=\u4f5c\u6210 @@ -587,18 +394,12 @@ labels.disabled=\u7121\u52b9 labels.path_mapping_pt_crawling=\u30af\u30ed\u30fc\u30eb\u6642 labels.path_mapping_pt_displaying=\u8868\u793a\u6642 labels.path_mapping_pt_both=\u30af\u30ed\u30fc\u30eb\u6642/\u8868\u793a\u6642 - -# view/admin/filePathMapping/confirm.jsp labels.path_mapping_title_confirm=\u30d1\u30b9\u30de\u30c3\u30d4\u30f3\u30b0\u306e\u8a2d\u5b9a\u306e\u78ba\u8a8d labels.path_mapping_button_create=\u4f5c\u6210 labels.path_mapping_button_back=\u623b\u308b labels.path_mapping_button_update=\u66f4\u65b0 labels.path_mapping_button_delete=\u524a\u9664 labels.path_mapping_button_edit=\u7de8\u96c6 - -# view/admin/filePathMapping/error.jsp - -# view/admin/filePathMapping/index.jsp labels.path_mapping_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.path_mapping_link_list=\u4e00\u89a7 labels.path_mapping_link_create=\u65b0\u898f\u4f5c\u6210 @@ -610,15 +411,11 @@ labels.path_mapping_link_edit=\u7de8\u96c6 labels.path_mapping_link_delete=\u524a\u9664 labels.path_mapping_link_prev_page=\u524d\u3078 labels.path_mapping_link_next_page=\u6b21\u3078 - -# view/admin/overlappingHost/edit.jsp labels.overlapping_host_configuration=\u91cd\u8907\u30db\u30b9\u30c8\u306e\u8a2d\u5b9a labels.overlapping_host_title_details=\u91cd\u8907\u30db\u30b9\u30c8\u306e\u8a2d\u5b9a labels.overlapping_host_button_create=\u4f5c\u6210 labels.overlapping_host_button_back=\u623b\u308b labels.overlapping_host_button_confirm=\u78ba\u8a8d - -# view/admin/overlappingHost/confirm.jsp labels.overlapping_host_title_confirm=\u91cd\u8907\u30db\u30b9\u30c8\u306e\u8a2d\u5b9a\u306e\u78ba\u8a8d labels.regular_name=\u6b63\u898f\u540d labels.overlapping_name=\u91cd\u8907\u540d @@ -627,10 +424,6 @@ labels.overlapping_host_button_back=\u623b\u308b labels.overlapping_host_button_update=\u66f4\u65b0 labels.overlapping_host_button_delete=\u524a\u9664 labels.overlapping_host_button_edit=\u7de8\u96c6 - -# view/admin/overlappingHost/error.jsp - -# view/admin/overlappingHost/index.jsp labels.overlapping_host_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.overlapping_host_link_list=\u4e00\u89a7 labels.overlapping_host_link_create=\u65b0\u898f\u4f5c\u6210 @@ -642,8 +435,6 @@ labels.overlapping_host_link_edit=\u7de8\u96c6 labels.overlapping_host_link_delete=\u524a\u9664 labels.overlapping_host_link_prev_page=\u524d\u3078 labels.overlapping_host_link_next_page=\u6b21\u3078 - -# view/admin/solr/index.jsp labels.system_title_configuration=\u30b7\u30b9\u30c6\u30e0\u8a2d\u5b9a labels.system_title_system_status=\u30b7\u30b9\u30c6\u30e0\u72b6\u614b labels.es_button_update=\u66f4\u65b0 @@ -694,19 +485,14 @@ labels.suggest_type_content=\u30b3\u30f3\u30c6\u30f3\u30c4 labels.suggest_type_searchlog=\u691c\u7d22\u30ed\u30b0 labels.suggest_search_log_enabled=\u691c\u7d22\u8a9e\u30b5\u30b8\u30a7\u30b9\u30c8 labels.purge_suggest_search_log_day=\u691c\u7d22\u8a9e\u30b5\u30b8\u30a7\u30b9\u30c8\u306e\u6709\u52b9\u671f\u9650 - -# view/admin/crawlingSession/confirm.jsp labels.crawling_session_title=\u30bb\u30c3\u30b7\u30e7\u30f3\u60c5\u5831 labels.crawling_session_title_confirm=\u30af\u30ed\u30fc\u30eb\u60c5\u5831 labels.crawling_session_button_back=\u623b\u308b labels.crawling_session_button_delete=\u524a\u9664 - -# view/admin/crawlingSession/error.jsp - -# view/admin/crawlingSession/index.jsp labels.crawling_session_configuration=\u30af\u30ed\u30fc\u30eb\u60c5\u5831 labels.crawling_session_search=\u691c\u7d22 labels.crawling_session_reset=\u30ea\u30bb\u30c3\u30c8 +labels.crawling_session_link_list=\u4e00\u89a7 labels.crawling_session_link_details=\u8a73\u7d30 labels.crawling_session_link_delete=\u524a\u9664 labels.crawling_session_prev_page=\u524d\u3078 @@ -718,7 +504,6 @@ labels.crawling_session_created_time=\u767b\u9332\u6642\u523b labels.crawling_session_expired_time=\u671f\u9650 labels.crawling_session_delete_all_link=\u3059\u3079\u3066\u524a\u9664 labels.crawling_session_delete_all_confirmation=\u524a\u9664\u3057\u307e\u3059\u304b? - labels.crawling_session_CrawlerStatus=\u30af\u30ed\u30fc\u30eb\u30b9\u30c6\u30fc\u30bf\u30b9 labels.crawling_session_CrawlerStartTime=\u958b\u59cb\u6642\u523b (\u30af\u30ed\u30fc\u30eb) labels.crawling_session_CrawlerEndTime=\u7d42\u4e86\u6642\u523b (\u30af\u30ed\u30fc\u30eb) @@ -743,8 +528,6 @@ labels.crawling_session_ReplicationStatus=\u30ec\u30d7\u30ea\u30b1\u30fc\u30b7\u labels.crawling_session_ReplicationStartTime=\u958b\u59cb\u6642\u523b (\u30ec\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3) labels.crawling_session_ReplicationEndTime=\u7d42\u4e86\u6642\u523b (\u30ec\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3) labels.crawling_session_ReplicationExecTime=\u5b9f\u884c\u6642\u9593 (\u30ec\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3) - -# view/admin/data/index.jsp labels.data_configuration=\u8a2d\u5b9a\u306e\u30d0\u30c3\u30af\u30a2\u30c3\u30d7/\u30ea\u30b9\u30c8\u30a2 labels.backup_title_edit=\u8a2d\u5b9a\u306e\u30d0\u30c3\u30af\u30a2\u30c3\u30d7 labels.backup=\u30d0\u30c3\u30af\u30a2\u30c3\u30d7 @@ -757,8 +540,6 @@ labels.backup_config=\u8a2d\u5b9a labels.backup_session_info=\u30bb\u30c3\u30b7\u30e7\u30f3\u60c5\u5831 labels.backup_search_log=\u691c\u7d22\u30ed\u30b0 labels.backup_click_log=\u30af\u30ea\u30c3\u30af\u30ed\u30b0 - -# view/admin/webAuthentication/index.jsp labels.web_authentication_configuration=\u30a6\u30a7\u30d6\u8a8d\u8a3c labels.web_authentication_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.web_authentication_link_list=\u4e00\u89a7 @@ -776,8 +557,6 @@ labels.web_authentication_list_realm=\u30ec\u30eb\u30e0 labels.web_authentication_list_web_crawling_config=\u30a6\u30a7\u30d6\u8a2d\u5b9a\u540d labels.web_authentication_any=\u4efb\u610f labels.web_authentication_create_web_config=\u65b0\u898f\u306b\u30a6\u30a7\u30d6\u30af\u30ed\u30fc\u30eb\u8a2d\u5b9a\u3092\u4f5c\u6210 - -# view/admin/webAuthentication/edit.jsp labels.web_authentication_title_details=\u30a6\u30a7\u30d6\u8a8d\u8a3c labels.web_authentication_button_create=\u4f5c\u6210 labels.web_authentication_button_back=\u623b\u308b @@ -793,20 +572,14 @@ labels.web_authentication_web_crawling_config=\u30a6\u30a7\u30d6\u8a2d\u5b9a\u54 labels.web_authentication_scheme_basic=Basic\u8a8d\u8a3c labels.web_authentication_scheme_digest=Digest\u8a8d\u8a3c labels.web_authentication_scheme_ntlm=NTLM\u8a8d\u8a3c - -# view/admin/webAuthentication/confirm.jsp labels.web_authentication_title_confirm=\u30a6\u30a7\u30d6\u8a8d\u8a3c labels.web_authentication_button_update=\u66f4\u65b0 labels.web_authentication_button_delete=\u524a\u9664 labels.web_authentication_button_edit=\u7de8\u96c6 - -# view/admin/log/confirm.jsp labels.log_configuration=\u30ed\u30b0\u30d5\u30a1\u30a4\u30eb labels.log_file_download_title=\u30ed\u30b0\u30d5\u30a1\u30a4\u30eb labels.log_file_name=\u30d5\u30a1\u30a4\u30eb\u540d labels.log_file_date=\u65e5\u6642 - -# view/admin/labelType/edit.jsp labels.labeltype_configuration=\u30e9\u30d9\u30eb labels.labeltype_title_details=\u30e9\u30d9\u30eb labels.labeltype_button_create=\u4f5c\u6210 @@ -814,8 +587,6 @@ labels.labeltype_button_back=\u623b\u308b labels.labeltype_button_confirm=\u78ba\u8a8d labels.labeltype_name=\u8a2d\u5b9a\u540d labels.labeltype_value=\u5024 - -# view/admin/labelType/confirm.jsp labels.labeltype_title_confirm=\u30e9\u30d9\u30eb\u306e\u78ba\u8a8d labels.labeltype_button_create=\u4f5c\u6210 labels.labeltype_button_back=\u623b\u308b @@ -824,8 +595,6 @@ labels.labeltype_button_delete=\u524a\u9664 labels.labeltype_button_edit=\u7de8\u96c6 labels.labeltype_included_paths=\u5bfe\u8c61\u3068\u3059\u308b\u30d1\u30b9 labels.labeltype_excluded_paths=\u9664\u5916\u3059\u308b\u30d1\u30b9 - -# view/admin/labelType/index.jsp labels.labeltype_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.labeltype_link_list=\u4e00\u89a7 labels.labeltype_link_create=\u65b0\u898f\u4f5c\u6210 @@ -837,8 +606,6 @@ labels.labeltype_link_edit=\u7de8\u96c6 labels.labeltype_link_delete=\u524a\u9664 labels.labeltype_link_prev_page=\u524d\u3078 labels.labeltype_link_next_page=\u6b21\u3078 - -# view/admin/roletype/edit.jsp labels.roletype_configuration=\u30ed\u30fc\u30eb labels.roletype_title_details=\u30ed\u30fc\u30eb labels.roletype_button_create=\u4f5c\u6210 @@ -846,16 +613,12 @@ labels.roletype_button_back=\u623b\u308b labels.roletype_button_confirm=\u78ba\u8a8d labels.roletype_name=\u8a2d\u5b9a\u540d labels.roletype_value=\u5024 - -# view/admin/roletype/confirm.jsp labels.roletype_title_confirm=\u30ed\u30fc\u30eb\u306e\u78ba\u8a8d labels.roletype_button_create=\u4f5c\u6210 labels.roletype_button_back=\u623b\u308b labels.roletype_button_update=\u66f4\u65b0 labels.roletype_button_delete=\u524a\u9664 labels.roletype_button_edit=\u7de8\u96c6 - -# view/admin/roletype/index.jsp labels.roletype_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.roletype_link_list=\u4e00\u89a7 labels.roletype_link_create=\u65b0\u898f\u4f5c\u6210 @@ -867,8 +630,6 @@ labels.roletype_link_edit=\u7de8\u96c6 labels.roletype_link_delete=\u524a\u9664 labels.roletype_link_prev_page=\u524d\u3078 labels.roletype_link_next_page=\u6b21\u3078 - -# view/admin/requestHeader/index.jsp labels.request_header_configuration=\u30ea\u30af\u30a8\u30b9\u30c8\u30d8\u30c3\u30c0\u30fc labels.request_header_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.request_header_link_list=\u4e00\u89a7 @@ -884,8 +645,6 @@ labels.request_header_link_next_page=\u6b21\u3078 labels.request_header_list_name=\u540d\u524d labels.request_header_list_web_crawling_config=\u30a6\u30a7\u30d6\u8a2d\u5b9a\u540d labels.request_header_create_web_config=\u65b0\u898f\u306b\u30a6\u30a7\u30d6\u30af\u30ed\u30fc\u30eb\u8a2d\u5b9a\u3092\u4f5c\u6210 - -# view/admin/requestHeader/edit.jsp labels.request_header_title_details=\u30ea\u30af\u30a8\u30b9\u30c8\u30d8\u30c3\u30c0\u30fc labels.request_header_button_create=\u4f5c\u6210 labels.request_header_button_back=\u623b\u308b @@ -893,14 +652,10 @@ labels.request_header_button_confirm=\u78ba\u8a8d labels.request_header_name=\u540d\u524d labels.request_header_value=\u5024 labels.request_header_web_crawling_config=\u30a6\u30a7\u30d6\u8a2d\u5b9a\u540d - -# view/admin/requestHeader/confirm.jsp labels.request_header_title_confirm=\u30ea\u30af\u30a8\u30b9\u30c8\u30d8\u30c3\u30c0\u30fc labels.request_header_button_update=\u66f4\u65b0 labels.request_header_button_delete=\u524a\u9664 labels.request_header_button_edit=\u7de8\u96c6 - -# view/admin/keyMatch/index.jsp labels.key_match_configuration=\u30ad\u30fc\u30de\u30c3\u30c1 labels.key_match_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.key_match_link_list=\u4e00\u89a7 @@ -919,22 +674,16 @@ labels.key_match_term=\u691c\u7d22\u8a9e labels.key_match_query=\u30af\u30a8\u30ea\u30fc labels.key_match_size=\u30b5\u30a4\u30ba labels.key_match_boost=\u30d6\u30fc\u30b9\u30c8 - -# view/admin/keyMatch/edit.jsp labels.key_match_title_details=\u30ad\u30fc\u30de\u30c3\u30c1 labels.key_match_button_create=\u4f5c\u6210 labels.key_match_button_back=\u623b\u308b labels.key_match_button_confirm=\u78ba\u8a8d labels.key_match_name=\u540d\u524d labels.key_match_value=\u5024 - -# view/admin/keyMatch/confirm.jsp labels.key_match_title_confirm=\u30ad\u30fc\u30de\u30c3\u30c1\u306e\u78ba\u8a8d labels.key_match_button_update=\u66f4\u65b0 labels.key_match_button_delete=\u524a\u9664 labels.key_match_button_edit=\u7de8\u96c6 - -# view/admin/design/index.jsp labels.design_configuration=\u30c7\u30b6\u30a4\u30f3 labels.design_title_file_upload=\u30d5\u30a1\u30a4\u30eb\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9 labels.design_title_file=\u30d5\u30a1\u30a4\u30eb\u7ba1\u7406 @@ -962,13 +711,9 @@ labels.design_file_errorSystem=\u30a8\u30e9\u30fc\u30da\u30fc\u30b8 (\u30b7\u30b labels.design_file_errorRedirect=\u30a8\u30e9\u30fc\u30da\u30fc\u30b8 (\u30ea\u30c0\u30a4\u30ec\u30af\u30c8) labels.design_file_errorBadRequest=\u30a8\u30e9\u30fc\u30da\u30fc\u30b8 (\u4e0d\u6b63\u306a\u30ea\u30af\u30a8\u30b9\u30c8) labels.design_delete_confirmation=\u524a\u9664\u3057\u307e\u3059\u304b? - -# view/admin/design/edit.jsp labels.design_title_edit_content=\u753b\u9762\u8868\u793a\u30d5\u30a1\u30a4\u30eb\u7de8\u96c6 labels.design_button_update=\u66f4\u65b0 labels.design_button_back=\u623b\u308b - -# view/admin/dataConfig/edit.jsp labels.data_crawling_configuration=\u30c7\u30fc\u30bf\u30b9\u30c8\u30a2\u30af\u30ed\u30fc\u30eb\u306e\u8a2d\u5b9a labels.data_crawling_title_details=\u30c7\u30fc\u30bf\u30b9\u30c8\u30a2\u30af\u30ed\u30fc\u30eb\u306e\u8a2d\u5b9a labels.handler_name=\u30cf\u30f3\u30c9\u30e9\u540d @@ -979,16 +724,10 @@ labels.label_type=\u30e9\u30d9\u30eb labels.data_crawling_button_create=\u4f5c\u6210 labels.data_crawling_button_back=\u623b\u308b labels.data_crawling_button_confirm=\u78ba\u8a8d - -# view/admin/dataConfig/confirm.jsp labels.data_crawling_title_confirm=\u30c7\u30fc\u30bf\u30b9\u30c8\u30a2\u30af\u30ed\u30fc\u30eb\u306e\u8a2d\u5b9a\u306e\u78ba\u8a8d labels.data_crawling_button_update=\u66f4\u65b0 labels.data_crawling_button_delete=\u524a\u9664 labels.data_crawling_button_edit=\u7de8\u96c6 - -# view/admin/dataConfig/error.jsp - -# view/admin/dataConfig/index.jsp labels.data_crawling_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.data_crawling_link_list=\u4e00\u89a7 labels.data_crawling_link_create=\u65b0\u898f\u4f5c\u6210 @@ -1000,14 +739,10 @@ labels.data_crawling_link_edit=\u7de8\u96c6 labels.data_crawling_link_delete=\u524a\u9664 labels.data_crawling_link_prev_page=\u524d\u3078 labels.data_crawling_link_next_page=\u6b21\u3078 - -# view/admin/wizard/index.jsp labels.wizard_title_configuration=\u8a2d\u5b9a\u30a6\u30a3\u30b6\u30fc\u30c9 labels.wizard_start_title=\u8a2d\u5b9a\u30a6\u30a3\u30b6\u30fc\u30c9 labels.wizard_start_desc=\u8a2d\u5b9a\u30a6\u30a3\u30b6\u30fc\u30c9\u3092\u5229\u7528\u3059\u308b\u3053\u3068\u3067
    \u30af\u30ed\u30fc\u30eb\u306b\u5fc5\u8981\u306a\u9805\u76ee\u3092\u7c21\u5358\u306b\u8a2d\u5b9a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002 labels.wizard_start_button=\u958b\u59cb - -# view/admin/wizard/schduleForm.jsp labels.wizard_schedule_title=\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u306e\u8a2d\u5b9a labels.wizard_schedule_enabled=\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u306e\u5229\u7528 labels.wizard_schedule=\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb @@ -1023,8 +758,6 @@ labels.wizard_button_next=\u6b21\u3078 labels.wizard_button_skip=\u30b9\u30ad\u30c3\u30d7 labels.wizard_button_cancel=\u30ad\u30e3\u30f3\u30bb\u30eb labels.wizard_button_back=\u623b\u308b - -# view/admin/wizard/schduleForm.jsp labels.wizard_crawling_config_title=\u30af\u30ed\u30fc\u30eb\u8a2d\u5b9a labels.wizard_crawling_config_name=\u30af\u30ed\u30fc\u30eb\u8a2d\u5b9a\u540d labels.wizard_crawling_config_path=\u30af\u30ed\u30fc\u30eb\u30d1\u30b9 @@ -1040,23 +773,15 @@ labels.wizard_schedule_day_sat=\u571f labels.wizard_schedule_day_m_f=\u6708-\u91d1 labels.wizard_schedule_day_mwf=\u6708,\u6c34,\u91d1 labels.wizard_schedule_day_tt=\u706b,\u6728 - -# view/admin/wizard/startCrawling.jsp labels.wizard_start_crawling_title=\u30af\u30ed\u30fc\u30eb\u958b\u59cb labels.wizard_start_crawling_desc=\u300c\u30af\u30ed\u30fc\u30eb\u958b\u59cb\u300d\u30dc\u30bf\u30f3\u3092\u62bc\u4e0b\u3059\u308b\u3053\u3068\u3067\u5373\u6642\u306b\u30af\u30ed\u30fc\u30eb\u3092\u958b\u59cb\u3067\u304d\u307e\u3059\u3002 labels.wizard_button_start_crawling=\u30af\u30ed\u30fc\u30eb\u958b\u59cb labels.wizard_button_finish=\u5b8c\u4e86 - -# view/admin/searchList/index.jsp labels.search_list_configuration=\u691c\u7d22\u7d50\u679c labels.search_list_index_page=\u691c\u7d22\u30af\u30a8\u30ea\u30fc\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002 - -# view/admin/searchList/confirmDelete.jsp labels.search_list_title_confirm_delete=\u524a\u9664\u306e\u78ba\u8a8d labels.search_list_url=URL labels.search_list_delete_link=\u524a\u9664 - -# view/admin/searchLog/index.jsp labels.search_log_configuration=\u691c\u7d22\u30ed\u30b0 labels.search_log_search_word_search=\u691c\u7d22\u8a9e labels.search_log_user_code_search=\u5229\u7528\u8005ID @@ -1079,8 +804,6 @@ labels.search_log_search_start_page=\u691c\u7d22\u958b\u59cb\u6642\u306e\u307f labels.search_log_search_term=\u671f\u9593 labels.search_log_search_term_from=\u958b\u59cb: labels.search_log_search_term_to=\u7d42\u4e86: - -# view/admin/searchLog/confirm.jsp labels.search_log_title=\u691c\u7d22\u30ed\u30b0 labels.search_log_title_confirm=\u691c\u7d22\u30ed\u30b0\u8a73\u7d30 labels.search_log_id=ID @@ -1095,8 +818,6 @@ labels.search_log_click_log_title=\u30af\u30ea\u30c3\u30af\u4e00\u89a7 labels.search_log_click_log_url=URL labels.search_log_click_log_requestedTime=\u30af\u30ea\u30c3\u30af\u6642\u523b labels.search_log_access_type=\u30a2\u30af\u30bb\u30b9\u7a2e\u5225 - -# view/admin/failureUrl/index.jsp labels.failure_url_configuration=\u30a2\u30af\u30bb\u30b9\u969c\u5bb3URL labels.failure_url_search_url=URL labels.failure_url_search_error_count=\u30a8\u30e9\u30fc\u56de\u6570 @@ -1106,8 +827,6 @@ labels.failure_url_last_access_time=\u6700\u7d42\u30a2\u30af\u30bb\u30b9\u6642\u labels.failure_url_link_confirm=\u78ba\u8a8d labels.failure_url_delete_all_confirmation=\u524a\u9664\u3057\u307e\u3059\u304b? labels.failure_url_error_count=\u30a8\u30e9\u30fc\u56de\u6570 - -# view/admin/failureUrl/confirm.jsp labels.failure_url_title_confirm=\u30a2\u30af\u30bb\u30b9\u969c\u5bb3URL\u306e\u8a73\u7d30 labels.failure_url_id=ID labels.failure_url_thread_name=\u30b9\u30ec\u30c3\u30c9\u540d @@ -1116,8 +835,6 @@ labels.failure_url_error_log=\u30ed\u30b0 labels.failure_url_url=URL labels.failure_url_web_config_name=\u30a6\u30a7\u30d6\u30af\u30ed\u30fc\u30eb\u8a2d\u5b9a labels.failure_url_file_config_name=\u30d5\u30a1\u30a4\u30eb\u30af\u30ed\u30fc\u30eb\u8a2d\u5b9a - -# view/admin/stats/index.jsp labels.stats_configuration=\u7d71\u8a08 labels.stats_search_report_type=\u30ec\u30dd\u30fc\u30c8\u7a2e\u5225 labels.stats_search_term=\u671f\u9593 @@ -1134,16 +851,12 @@ labels.stats_client_ip=\u30af\u30e9\u30a4\u30a2\u30f3\u30c8IP labels.stats_count=\u4ef6\u6570 labels.stats_click_url=\u30af\u30ea\u30c3\u30af\u3055\u308c\u305fURL labels.stats_favorite_url=\u6295\u7968\u3055\u308c\u305fURL - -# view/admin/systemInfo/index.jsp labels.system_info_configuration=\u30b7\u30b9\u30c6\u30e0\u60c5\u5831 labels.system_info_env_title=\u74b0\u5883\u5909\u6570\u30d7\u30ed\u30d1\u30c6\u30a3 labels.system_info_prop_title=\u30b7\u30b9\u30c6\u30e0\u30d7\u30ed\u30d1\u30c6\u30a3 labels.system_info_fess_prop_title=Fess \u30d7\u30ed\u30d1\u30c6\u30a3 labels.system_info_bug_report_title=\u30d0\u30b0\u30ec\u30dd\u30fc\u30c8\u7528 labels.system_info_crawler_properties_does_not_exist=crawler.properties\u30d5\u30a1\u30a4\u30eb\u304c\u5b58\u5728\u3057\u3066\u3044\u307e\u305b\u3093\u3002\u30c7\u30d5\u30a9\u30eb\u30c8\u5024\u304c\u9069\u7528\u3055\u308c\u3066\u3044\u307e\u3059\u3002 - -# view/admin/fileAuthentication/index.jsp labels.file_authentication_configuration=\u30d5\u30a1\u30a4\u30eb\u8a8d\u8a3c labels.file_authentication_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.file_authentication_link_list=\u4e00\u89a7 @@ -1160,8 +873,6 @@ labels.file_authentication_list_hostname=\u30db\u30b9\u30c8\u540d labels.file_authentication_list_file_crawling_config=\u30d5\u30a1\u30a4\u30eb\u8a2d\u5b9a\u540d labels.file_authentication_any=\u4efb\u610f labels.file_authentication_create_file_config=\u65b0\u898f\u306b\u30d5\u30a1\u30a4\u30eb\u30af\u30ed\u30fc\u30eb\u8a2d\u5b9a\u3092\u4f5c\u6210 - -# view/admin/fileAuthentication/edit.jsp labels.file_authentication_title_details=\u30d5\u30a1\u30a4\u30eb\u8a8d\u8a3c labels.file_authentication_button_create=\u4f5c\u6210 labels.file_authentication_button_back=\u623b\u308b @@ -1174,17 +885,12 @@ labels.file_authentication_password=\u30d1\u30b9\u30ef\u30fc\u30c9 labels.file_authentication_parameters=\u30d1\u30e9\u30e1\u30fc\u30bf labels.file_authentication_file_crawling_config=FS\u8a2d\u5b9a\u540d labels.file_authentication_scheme_samba=Samba - -# view/admin/fileAuthentication/confirm.jsp labels.file_authentication_title_confirm=\u30d5\u30a1\u30a4\u30eb\u8a8d\u8a3c labels.file_authentication_button_update=\u66f4\u65b0 labels.file_authentication_button_delete=\u524a\u9664 labels.file_authentication_button_edit=\u7de8\u96c6 - labels.pagination_page_guide_msg={0}/{1} ({2}\u4ef6) labels.list_could_not_find_crud_table=\u767b\u9332\u3055\u308c\u3066\u3044\u307e\u305b\u3093\u3002 - -# view/admin/userInfo/index.jsp labels.user_info_configuration=\u5229\u7528\u8005\u60c5\u5831 labels.user_info_title=\u5229\u7528\u8005\u60c5\u5831 labels.user_info_title_confirm=\u5229\u7528\u8005\u60c5\u5831\u8a73\u7d30 @@ -1198,8 +904,6 @@ labels.user_info_edit_createddate=\u521d\u56de\u30a2\u30af\u30bb\u30b9\u65e5\u66 labels.user_info_edit_lastupdated=\u6700\u7d42\u30a2\u30af\u30bb\u30b9\u65e5\u6642 labels.user_info_delete_all_link=\u3059\u3079\u3066\u524a\u9664 labels.user_info_delete_all_confirmation=\u524a\u9664\u3057\u307e\u3059\u304b? - -# view/admin/favoriteLog/index.jsp labels.favorite_log_title=\u4eba\u6c17URL labels.favorite_log_configuration=\u4eba\u6c17URL labels.favorite_log_user_code_search=\u5229\u7528\u8005ID @@ -1215,8 +919,6 @@ labels.favorite_log_download_csv=\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9(CSV) labels.favorite_log_search_term=\u671f\u9593 labels.favorite_log_title_confirm=\u4eba\u6c17URL\u8a73\u7d30 labels.favorite_log_id=ID - -# view/admin/ScheduledJob/edit.jsp labels.scheduledjob_configuration=\u30b8\u30e7\u30d6\u7ba1\u7406 labels.scheduledjob_title_details=\u30b8\u30e7\u30d6 labels.scheduledjob_button_create=\u4f5c\u6210 @@ -1233,8 +935,6 @@ labels.scheduledjob_crawler=\u30af\u30ed\u30fc\u30eb\u30b8\u30e7\u30d6 labels.scheduledjob_running=\u5b9f\u884c\u4e2d labels.scheduledjob_active=\u6709\u52b9 labels.scheduledjob_nojob=- - -# view/admin/ScheduledJob/confirm.jsp labels.scheduledjob_title_confirm=\u30b8\u30e7\u30d6\u306e\u78ba\u8a8d labels.scheduledjob_button_create=\u4f5c\u6210 labels.scheduledjob_button_back=\u623b\u308b @@ -1243,8 +943,6 @@ labels.scheduledjob_button_delete=\u524a\u9664 labels.scheduledjob_button_edit=\u7de8\u96c6 labels.scheduledjob_button_start=\u958b\u59cb labels.scheduledjob_button_stop=\u505c\u6b62 - -# view/admin/scheduledjob/index.jsp labels.scheduledjob_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.scheduledjob_link_list=\u4e00\u89a7 labels.scheduledjob_link_create=\u65b0\u898f\u4f5c\u6210 @@ -1256,8 +954,6 @@ labels.scheduledjob_link_edit=\u7de8\u96c6 labels.scheduledjob_link_delete=\u524a\u9664 labels.scheduledjob_link_prev_page=\u524d\u3078 labels.scheduledjob_link_next_page=\u6b21\u3078 - -# jobLog labels.joblog_button_back=\u623b\u308b labels.joblog_button_create=\u4f5c\u6210 labels.joblog_button_delete=\u524a\u9664 @@ -1287,8 +983,6 @@ labels.joblog_title_details=\u30b8\u30e7\u30d6\u30ed\u30b0\u8a73\u7d30 labels.joblog_title_list=\u30b8\u30e7\u30d6\u30ed\u30b0\u4e00\u89a7 labels.joblog_delete_all_link=\u3059\u3079\u3066\u524a\u9664 labels.joblog_delete_all_confirmation=\u524a\u9664\u3057\u307e\u3059\u304b? - -# dict labels.dict_configuration=\u8f9e\u66f8\u4e00\u89a7 labels.dict_list_title=\u8f9e\u66f8\u4e00\u89a7 labels.dict_list_link=\u8f9e\u66f8\u4e00\u89a7 @@ -1300,8 +994,6 @@ labels.dict_link_delete=\u524a\u9664 labels.dict_link_prev_page=\u524d\u3078 labels.dict_link_next_page=\u6b21\u3078 labels.dict_button_back=\u623b\u308b - -# synonym labels.dict_synonym_configuration=\u540c\u7fa9\u8a9e\u4e00\u89a7 labels.dict_synonym_title=\u540c\u7fa9\u8a9e\u4e00\u89a7 labels.dict_synonym_list_link=\u4e00\u89a7 @@ -1322,8 +1014,6 @@ labels.dict_synonym_button_update=\u66f4\u65b0 labels.dict_synonym_button_download=\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9 labels.dict_synonym_button_upload=\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9 labels.dict_synonym_file=\u540c\u7fa9\u8a9e\u30d5\u30a1\u30a4\u30eb - -# userdict labels.dict_userdict_configuration=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u4e00\u89a7 labels.dict_userdict_title=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u4e00\u89a7 labels.dict_userdict_list_link=\u4e00\u89a7 @@ -1346,8 +1036,6 @@ labels.dict_userdict_button_update=\u66f4\u65b0 labels.dict_userdict_button_download=\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9 labels.dict_userdict_button_upload=\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9 labels.dict_userdict_file=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u30d5\u30a1\u30a4\u30eb - -# boost document rule labels.boost_document_rule_configuration=\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u30d6\u30fc\u30b9\u30c8 labels.boost_document_rule_title_list=\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u30d6\u30fc\u30b9\u30c8 labels.boost_document_rule_title_confirm=\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u30d6\u30fc\u30b9\u30c8\u306e\u78ba\u8a8d @@ -1373,8 +1061,6 @@ labels.boost_document_rule_list_url_expr=\u6761\u4ef6 labels.boost_document_rule_url_expr=\u6761\u4ef6 labels.boost_document_rule_boost_expr=\u30d6\u30fc\u30b9\u30c8\u5024\u5f0f labels.boost_document_rule_sort_order=\u8868\u793a\u9806 - -# suggest\u3000elevate\u3000word labels.suggest_elevate_word_configuration=\u8ffd\u52a0\u5019\u88dc labels.suggest_elevate_word_title_list=\u8ffd\u52a0\u5019\u88dc labels.suggest_elevate_word_title_confirm=\u8ffd\u52a0\u5019\u88dc\u306e\u78ba\u8a8d @@ -1407,8 +1093,6 @@ labels.suggest_elevate_word_target_role=\u30ed\u30fc\u30eb\u540d labels.suggest_elevate_word_target_label=\u30e9\u30d9\u30eb\u540d labels.suggest_elevate_word_boost=\u30d6\u30fc\u30b9\u30c8\u5024 labels.suggest_elevate_word_file=\u8ffd\u52a0\u5019\u88dc\u30d5\u30a1\u30a4\u30eb - -# suggest bad word labels.suggest_bad_word_configuration=NG\u30ef\u30fc\u30c9 labels.suggest_bad_word_title_list=NG\u30ef\u30fc\u30c9 labels.suggest_bad_word_title_confirm=NG\u30ef\u30fc\u30c9\u306e\u78ba\u8a8d @@ -1439,18 +1123,78 @@ labels.suggest_bad_word_suggest_word=\u30b5\u30b8\u30a7\u30b9\u30c8\u5019\u88dc labels.suggest_bad_word_target_role=\u30ed\u30fc\u30eb\u540d labels.suggest_bad_word_target_label=\u30e9\u30d9\u30eb\u540d labels.suggest_bad_word_file=NG\u30ef\u30fc\u30c9\u30d5\u30a1\u30a4\u30eb - -# CRUD PROPERTIES: BEGIN -errors.crud_invalid_mode=\u30e2\u30fc\u30c9\u304c\u9055\u3044\u307e\u3059\u3002(\u6b63\u3057\u3044\u5024\u306f {0} \u3067\u3059\u304c\u3001\u5165\u529b\u3055\u308c\u305f\u5024\u306f {1} \u306b\u306a\u3063\u3066\u3044\u307e\u3059) -errors.crud_failed_to_create_crud_table=\u30c7\u30fc\u30bf\u306e\u4f5c\u6210\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.crud_failed_to_update_crud_table=\u30c7\u30fc\u30bf\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.crud_failed_to_delete_crud_table=\u30c7\u30fc\u30bf\u306e\u524a\u9664\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -errors.crud_could_not_find_crud_table=\u30c7\u30fc\u30bf {0} \u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 - -success.crud_create_crud_table=\u30c7\u30fc\u30bf\u3092\u4f5c\u6210\u3057\u307e\u3057\u305f\u3002 -success.crud_update_crud_table=\u30c7\u30fc\u30bf\u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 -success.crud_delete_crud_table=\u30c7\u30fc\u30bf\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 - +labels.user_configuration=\u30e6\u30fc\u30b6\u30fc +labels.user_link_create_new=\u65b0\u898f\u4f5c\u6210 +labels.user_link_list=\u4e00\u89a7 +labels.user_link_create=\u65b0\u898f\u4f5c\u6210 +labels.user_link_update=\u7de8\u96c6 +labels.user_link_delete=\u524a\u9664 +labels.user_link_confirm=\u8a73\u7d30 +labels.user_link_details=\u8a73\u7d30 +labels.user_link_edit=\u7de8\u96c6 +labels.user_link_delete=\u524a\u9664 +labels.user_link_prev_page=\u524d\u3078 +labels.user_link_next_page=\u6b21\u3078 +labels.user_list_name=\u540d\u524d +labels.user_name=\u540d\u524d +labels.user_password=\u30d1\u30b9\u30ef\u30fc\u30c9 +labels.user_confirm_password=\u78ba\u8a8d +labels.user_role=\u30ed\u30fc\u30eb +labels.user_group=\u30b0\u30eb\u30fc\u30d7 +labels.user_title_details=\u30e6\u30fc\u30b6\u30fc +labels.user_button_create=\u4f5c\u6210 +labels.user_button_back=\u623b\u308b +labels.user_button_confirm=\u78ba\u8a8d +labels.user_title_confirm=\u30e6\u30fc\u30b6\u30fc\u8a2d\u5b9a\u306e\u78ba\u8a8d +labels.user_button_update=\u66f4\u65b0 +labels.user_button_delete=\u524a\u9664 +labels.user_button_edit=\u7de8\u96c6 +labels.role_configuration=\u30ed\u30fc\u30eb +labels.role_link_create_new=\u65b0\u898f\u4f5c\u6210 +labels.role_link_list=\u4e00\u89a7 +labels.role_link_create=\u65b0\u898f\u4f5c\u6210 +labels.role_link_update=\u7de8\u96c6 +labels.role_link_delete=\u524a\u9664 +labels.role_link_confirm=\u8a73\u7d30 +labels.role_link_details=\u8a73\u7d30 +labels.role_link_edit=\u7de8\u96c6 +labels.role_link_delete=\u524a\u9664 +labels.role_link_prev_page=\u524d\u3078 +labels.role_link_next_page=\u6b21\u3078 +labels.role_list_name=\u540d\u524d +labels.role_name=\u540d\u524d +labels.role_title_details=\u30ed\u30fc\u30eb +labels.role_button_create=\u4f5c\u6210 +labels.role_button_back=\u623b\u308b +labels.role_button_confirm=\u78ba\u8a8d +labels.role_title_confirm=\u30ed\u30fc\u30eb\u8a2d\u5b9a\u306e\u78ba\u8a8d +labels.role_button_update=\u66f4\u65b0 +labels.role_button_delete=\u524a\u9664 +labels.role_button_edit=\u7de8\u96c6 +labels.group_configuration=\u30b0\u30eb\u30fc\u30d7 +labels.group_link_create_new=\u65b0\u898f\u4f5c\u6210 +labels.group_link_list=\u4e00\u89a7 +labels.group_link_create=\u65b0\u898f\u4f5c\u6210 +labels.group_link_update=\u7de8\u96c6 +labels.group_link_delete=\u524a\u9664 +labels.group_link_confirm=\u8a73\u7d30 +labels.group_link_details=\u8a73\u7d30 +labels.group_link_edit=\u7de8\u96c6 +labels.group_link_delete=\u524a\u9664 +labels.group_link_prev_page=\u524d\u3078 +labels.group_link_next_page=\u6b21\u3078 +labels.group_list_name=\u540d\u524d +labels.group_name=\u540d\u524d +labels.group_title_details=\u30b0\u30eb\u30fc\u30d7 +labels.group_button_create=\u4f5c\u6210 +labels.group_button_back=\u623b\u308b +labels.group_button_confirm=\u78ba\u8a8d +labels.group_title_confirm=\u30b0\u30eb\u30fc\u30d7\u8a2d\u5b9a\u306e\u78ba\u8a8d +labels.group_button_update=\u66f4\u65b0 +labels.group_button_delete=\u524a\u9664 +labels.group_button_edit=\u7de8\u96c6 +labels.roles=\u30ed\u30fc\u30eb +labels.groups=\u30b0\u30eb\u30fc\u30d7 labels.crud_button_create=\u4f5c\u6210 labels.crud_button_update=\u66f4\u65b0 labels.crud_button_delete=\u524a\u9664 @@ -1459,14 +1203,11 @@ labels.crud_button_edit=\u7de8\u96c6 labels.crud_button_confirm=\u78ba\u8a8d labels.crud_button_search=\u691c\u7d22 labels.crud_button_reset=\u30ea\u30bb\u30c3\u30c8 - labels.crud_link_create_new=\u65b0\u898f\u4f5c\u6210 labels.crud_link_delete=\u524a\u9664 labels.crud_link_back=\u623b\u308b labels.crud_link_edit=\u7de8\u96c6 labels.crud_link_next_page=\u6b21\u3078 labels.crud_link_prev_page=\u524d\u3078 - labels.crud_title_details=\u8a73\u7d30 labels.crud_title_confirm=\u78ba\u8a8d -# CRUD PROPERTIES: END diff --git a/src/main/resources/fess_message.properties b/src/main/resources/fess_message.properties index c935366fb..fe813694e 100644 --- a/src/main/resources/fess_message.properties +++ b/src/main/resources/fess_message.properties @@ -1,11 +1,82 @@ # ======================================================================================== -# Struts Default -# ============== +# Framework Default +# ================= +# ---------------------------------------------------------- +# Lasta Taglib +# ------------ errors.header=
      errors.footer=
    errors.prefix=
  • errors.suffix=
  • + +# ---------------------------------------------------------- +# Javax Validator +# --------------- +constraints.AssertFalse.message = must be false +constraints.AssertTrue.message = must be true +constraints.DecimalMax.message = must be less than ${inclusive == true ? 'or equal to ' : ''}{value} +constraints.DecimalMin.message = must be greater than ${inclusive == true ? 'or equal to ' : ''}{value} +constraints.Digits.message = numeric value out of bounds (<{integer} digits>.<{fraction} digits> expected) +constraints.Future.message = must be in the future +constraints.Max.message = must be less than or equal to {value} +constraints.Min.message = must be greater than or equal to {value} +constraints.NotNull.message = may not be null +constraints.Null.message = must be null +constraints.Past.message = must be in the past +constraints.Pattern.message = must match "{regexp}" +constraints.Size.message = size must be between {min} and {max} + +# ---------------------------------------------------------- +# Hibernate Validator +# ------------------- +constraints.CreditCardNumber.message = invalid credit card number +constraints.EAN.message = invalid {type} barcode +constraints.Email.message = not a well-formed email address +constraints.Length.message = length must be between {min} and {max} +constraints.LuhnCheck.message = The check digit for ${value} is invalid, Luhn Modulo 10 checksum failed +constraints.Mod10Check.message = The check digit for ${value} is invalid, Modulo 10 checksum failed +constraints.Mod11Check.message = The check digit for ${value} is invalid, Modulo 11 checksum failed +constraints.ModCheck.message = The check digit for ${value} is invalid, ${modType} checksum failed +constraints.NotBlank.message = may not be empty +constraints.NotEmpty.message = may not be empty +constraints.ParametersScriptAssert.message = script expression "{script}" didn't evaluate to true +constraints.Range.message = must be between {min} and {max} +constraints.SafeHtml.message = may have unsafe html content +constraints.ScriptAssert.message = script expression "{script}" didn't evaluate to true +constraints.URL.message = must be a valid URL +constraints.Required.message = is required + +# ---------------------------------------------------------- +# Application Exception +# --------------------- +# /- - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# five framework-embedded messages (don't change key names) +# - - - - - - - - - -/ +errors.login.failure=could not login +errors.app.illegal.transition=retry because of illegal transition +errors.app.db.already.deleted=others might be updated, so retry +errors.app.db.already.updated=others might be updated, so retry +errors.app.db.already.exists=already existing data, so retry + + +# _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ +# you can define your messages here: +# e.g. +# errors.xxx = ... +# info.xxx = ... +# _/_/_/_/_/_/_/_/_/_/ +# ======================================================================================== +# Fess +# ====== +errors.front_header=
    +errors.front_footer=
    +errors.front_prefix=
    +errors.front_suffix=
    +errors.header=
    +errors.footer=
    +errors.prefix=

    +errors.suffix=

    errors.invalid={0} is invalid. errors.maxlength={0} can not be greater than {1} characters. errors.minlength={0} can not be less than {1} characters. @@ -23,85 +94,132 @@ errors.short={0} must be an short. errors.creditcard={0} is not a valid credit card number. errors.email={0} is an invalid e-mail address. errors.url={0} is an invalid url (web address). +errors.cronexpression={0} is a invalid format. +errors.uritype={0} is a invalid uri. +errors.alphaDigitOnly={0} must be alphabet or digit only. +errors.alphaDigitSpaceOnly={0} must be alphabet, digit, or space only. +errors.token=Invalid request. +errors.failed_to_update_crawler_params=Failed to update parameters. Please contact to a site administrator. +errors.failed_to_update_web_crawler_params=Failed to update parameters. Please contact to a site administrator. +errors.failed_to_update_solr_params=Failed to update parameters. Please contact to a site administrator. +error.login_error=Username or Password is not correct. +errors.failed_to_commit_solr_index=Failed to commit index. +errors.failed_to_optimize_solr_index=Failed to optimize index. +errors.failed_to_delete_solr_index=Failed to delete index. +errors.failed_to_start_solr_process_because_of_running=Failed to start a process because of running solr process. +errors.failed_to_import_data=Failed to restore data. +errors.unknown_import_file=Unknown file type. +errors.failed_to_export_data=Failed to backup data. +errors.could_not_find_log_file=Could not find {0}. +errors.no_running_crawl_process=No running crawl process. +errors.failed_to_start_crawl_process=Failed to start a crawl process. +errors.invalid_design_jsp_file_name=Invalid JSP file. +errors.design_jsp_file_does_not_exist=JSP file does not exist. +errors.design_file_name_is_not_found=The file name is not specified. +errors.failed_to_write_design_image_file=Failed to upload an image file. +errors.failed_to_update_jsp_file=Failed to update a jsp file. +errors.design_file_name_is_invalid=The file name is invalid. +errors.design_file_is_unsupported_type=The kind of file is unsupported. +errors.failed_to_start_solr_instance=Failed to start a solr instance. +errors.failed_to_stop_solr_instance=Failed to stop a solr instance. +errors.failed_to_reload_solr_instance=Failed to reload a solr instance. +errors.failed_to_update_crawler_schedule=Failed to update a crawling schedule. +errors.failed_to_create_crawling_config_at_wizard=Failed to create a crawling config. +errors.design_editor_disabled=This feature is disabled. +errors.could_not_create_search_log_csv=Could not create a search log csv file. +errors.not_found_on_file_system=Not Found: {0} +errors.could_not_open_on_system=Could not open {0}.
    Please check if the file is associated with an application. +errors.process_time_is_exceeded=The limit of a search time was exceeded. The partial result was displayed. +errors.result_size_exceeded=No more results could be displayed. +errors.target_file_does_not_exist={0} file does not exist. +errors.failed_to_download_file=Failed to download {0} file. +errors.failed_to_delete_file=Failed to delete {0} file. +errors.failed_to_redirect=Failed to redirect {0}. +errors.unsupported_encoding={0} is not supported as encoding. +errors.docid_not_found=Not found Doc ID:{0} +errors.document_not_found=Not found URL of Doc ID:{0} +errors.not_load_from_server=Could not load from this server: {0} +errors.failed_to_start_job=Failed to start job {0}. +errors.failed_to_stop_job=Failed to stop job {0}. +errors.expired_dict_id=Expired dictionary information. Please reload it. +errors.failed_to_create_cache=Failed to create a cache reponse for ID:{0}. +errors.synonym_file_is_not_found=Synonym file is not found +errors.failed_to_download_synonym_file=Failed to download the Synonym file. +errors.failed_to_upload_synonym_file=Failed to upload the Synonym file. +errors.userdict_file_is_not_found=Synonym file is not found +errors.failed_to_download_userdict_file=Failed to download the UserDict file. +errors.failed_to_upload_userdict_file=Failed to upload the UserDict file. +errors.blank_password=Password is required. +errors.invalid_confirm_password=Confirm Password does not match. +errors.password_does_not_exist_in_session=Invalid password. -# ======================================================================================== -# Project Common -# ============== -# ---------------------------------------------------------- -# Value Message -# ------------- -errors.number=input number for {0} -errors.same.value=same value is selected in {0} -errors.greater.than=input {0} greater than {1} -errors.required.at.least.one=input {0} at least one -errors.required.or=input either {0} or {1} -errors.upload.size=Uploading failed, because actual size {0} bytes exceeded limit size {1} bytes. +errors.invalid_query_unknown=The given query is invalid. +errors.invalid_query_quoted=An invalid quote character is used. +errors.invalid_query_curly_bracket=An invalid curly bracket character is used. +errors.invalid_query_square_bracket=An invalid square bracket character is used. +errors.invalid_query_parenthesis=An invalid parenthesis character is used. +errors.invalid_query_num_range=An invalid range is used. The example of the range format is "field:[20020101 TO 20030101]". +errors.invalid_query_str_range=An invalid range is used. The example of the range format is "field:'{'Aida TO Carmen'}'". -# ---------------------------------------------------------- -# Business Message -# ---------------- -errors.empty.login=input mail address or password -errors.not.login=invalid mail address or password -errors.email.exists=mail address already registered -errors.already.registered={0} is already-regsitered {1} +success.update_crawler_params=Updated parameters. +success.update_web_crawler_params=Updated parameters. +success.update_solr_params=Updated parameters. +success.commit_solr_index=Started a process to commit index. +success.optimize_solr_index=Started a process to optimize index. +success.delete_solr_index=Started a process to optimize index. +success.importing_data=Started to restore data from the uploaded file. +success.crawling_session_delete_all=Deleted session data. +success.start_crawl_process=Started a crawl process. +success.stopping_crawl_process=Stopping a crawl process. +success.upload_design_file=Uploaded {0}. +success.update_design_jsp_file=Updated {0}. +success.starting_solr_instance=Starting a solr instance. +success.stopping_solr_instance=Stopping a solr instance. +success.reloading_solr_instance=Reloading a solr instance. +success.update_crawler_schedule=Updated a crawling schedule. +success.create_crawling_config_at_wizard=Created a crawling config ({0}). +success.search_log_delete_all=Deleted search logs. +success.failure_url_delete_all=Deleted failure urls. +success.delete_file=Deleted {0} file. +success.user_info_delete_all=Deleted user information. +success.favorite_log_delete_all=Deleted popular urls +success.job_started=Started job {0}. +success.job_stopped=Stopped job {0}. +success.joblog_delete_all=Deleted job logs. +success.upload_synonym_file=Uploaded Synonym file. +success.upload_userdict_file=Uploaded UserDict file. +success.upload_suggest_elevate_word=Uploaded Additional Word file. +success.upload_suggest_bad_word=Uploaded Bad Word file. -# ---------------------------------------------------------- -# Application Exception -# --------------------- -errors.app.illegal.transition=retry because of illegal transition -errors.app.already.deleted=others might be updated, so retry -errors.app.already.updated=others might be updated, so retry -errors.app.already.exists=already existing data, so retry +label.facet_label_title=Label +label.facet_lastModified_title=Term +label.facet_lastModified_1day=Past 24 Hours +label.facet_lastModified_1week=Past Week +label.facet_lastModified_1month=Past Month +label.facet_lastModified_1year=Past Year +label.facet_contentLength_title=Size +label.facet_contentLength_10k=  - 10kb +label.facet_contentLength_10kto100k=10kb - 100kb +label.facet_contentLength_100kto500k=100kb - 500kb +label.facet_contentLength_500kto1m=500kb - 1mb +label.facet_contentLength_1m=1mb -   +label.facet_filetype_title=File Type +label.facet_filetype_html=HTML +label.facet_filetype_word=Word +label.facet_filetype_excel=Excel +label.facet_filetype_powerpoint=PowerPoint +label.facet_filetype_pdf=PDF +label.facet_filetype_others=PDF +label.facet_label_reset=Reset +errors.crud_invalid_mode=Invalid mode(expected value is {0}, but it's {1}). +errors.crud_failed_to_create_crud_table=Failed to create a new data. +errors.crud_failed_to_update_crud_table=Failed to update the data. +errors.crud_failed_to_delete_crud_table=Failed to delete the data. +errors.crud_could_not_find_crud_table=Could not find the data({0}). -# ======================================================================================== -# Labels -# ====== -# ---------------------------------------------------------- -# Entity -# ------ -labels.member = Member - -# ---------------------------------------------------------- -# Attribute -# --------- -labels.memberId = Member ID -labels.memberName = Member Name -labels.email = Mail Address -labels.emailOrAccount = Mail or Account -labels.password = Password -labels.versionNo = Version No - -# ---------------------------------------------------------- -# Screen -# ------ -labels.list = List -labels.edit = Edit -labels.add = Add -labels.search = Search -labels.register = Register -labels.update = Update - -labels.member.list = @[labels.list] of @[labels.member] -labels.member.add = @[labels.add] @[labels.member] -labels.member.edit = @[labels.edit] @[labels.member] - -# ---------------------------------------------------------- -# Header Title -# ------------ -labels.header.title.error.message = Notice - - -# ======================================================================================== -# Messages -# ======== -# ---------------------------------------------------------- -# Input Note -# ---------- -messages.input.note.keyword = Input keyword to search -messages.input.note.email = Input your E-mail address -messages.input.note.emailOrAccount = Input your E-mail or account -messages.input.note.password = Input your password -messages.input.note.zipCode = e.g. 153-0051 +success.crud_create_crud_table=Created data. +success.crud_update_crud_table=Updated data. +success.crud_delete_crud_table=Deleted data. diff --git a/src/main/resources/fess_message_en.properties b/src/main/resources/fess_message_en.properties new file mode 100644 index 000000000..494e9d0d5 --- /dev/null +++ b/src/main/resources/fess_message_en.properties @@ -0,0 +1,154 @@ +errors.front_header=
    +errors.front_footer=
    +errors.front_prefix=
    +errors.front_suffix=
    +errors.header=
    +errors.footer=
    +errors.prefix=

    +errors.suffix=

    +errors.invalid={0} is invalid. +errors.maxlength={0} can not be greater than {1} characters. +errors.minlength={0} can not be less than {1} characters. +errors.maxbytelength={0} can not be greater than {1} bytes. +errors.minbytelength={0} can not be less than {1} bytes. +errors.range={0} is not in the range {1} through {2}. +errors.required={0} is required. +errors.byte={0} must be an byte. +errors.date={0} is not a date. +errors.double={0} must be an double. +errors.float={0} must be an float. +errors.integer={0} must be an integer. +errors.long={0} must be an long. +errors.short={0} must be an short. +errors.creditcard={0} is not a valid credit card number. +errors.email={0} is an invalid e-mail address. +errors.url={0} is an invalid url (web address). +errors.cronexpression={0} is a invalid format. +errors.uritype={0} is a invalid uri. +errors.alphaDigitOnly={0} must be alphabet or digit only. +errors.alphaDigitSpaceOnly={0} must be alphabet, digit, or space only. +errors.token=Invalid request. + +errors.failed_to_update_crawler_params=Failed to update parameters. Please contact to a site administrator. +errors.failed_to_update_web_crawler_params=Failed to update parameters. Please contact to a site administrator. +errors.failed_to_update_solr_params=Failed to update parameters. Please contact to a site administrator. +error.login_error=Username or Password is not correct. +errors.failed_to_commit_solr_index=Failed to commit index. +errors.failed_to_optimize_solr_index=Failed to optimize index. +errors.failed_to_delete_solr_index=Failed to delete index. +errors.failed_to_start_solr_process_because_of_running=Failed to start a process because of running solr process. +errors.failed_to_import_data=Failed to restore data. +errors.unknown_import_file=Unknown file type. +errors.failed_to_export_data=Failed to backup data. +errors.could_not_find_log_file=Could not find {0}. +errors.no_running_crawl_process=No running crawl process. +errors.failed_to_start_crawl_process=Failed to start a crawl process. +errors.invalid_design_jsp_file_name=Invalid JSP file. +errors.design_jsp_file_does_not_exist=JSP file does not exist. +errors.design_file_name_is_not_found=The file name is not specified. +errors.failed_to_write_design_image_file=Failed to upload an image file. +errors.failed_to_update_jsp_file=Failed to update a jsp file. +errors.design_file_name_is_invalid=The file name is invalid. +errors.design_file_is_unsupported_type=The kind of file is unsupported. +errors.failed_to_start_solr_instance=Failed to start a solr instance. +errors.failed_to_stop_solr_instance=Failed to stop a solr instance. +errors.failed_to_reload_solr_instance=Failed to reload a solr instance. +errors.failed_to_update_crawler_schedule=Failed to update a crawling schedule. +errors.failed_to_create_crawling_config_at_wizard=Failed to create a crawling config. +errors.design_editor_disabled=This feature is disabled. +errors.could_not_create_search_log_csv=Could not create a search log csv file. +errors.not_found_on_file_system=Not Found: {0} +errors.could_not_open_on_system=Could not open {0}.
    Please check if the file is associated with an application. +errors.process_time_is_exceeded=The limit of a search time was exceeded. The partial result was displayed. +errors.result_size_exceeded=No more results could be displayed. +errors.target_file_does_not_exist={0} file does not exist. +errors.failed_to_download_file=Failed to download {0} file. +errors.failed_to_delete_file=Failed to delete {0} file. +errors.failed_to_redirect=Failed to redirect {0}. +errors.unsupported_encoding={0} is not supported as encoding. +errors.docid_not_found=Not found Doc ID:{0} +errors.document_not_found=Not found URL of Doc ID:{0} +errors.not_load_from_server=Could not load from this server: {0} +errors.failed_to_start_job=Failed to start job {0}. +errors.failed_to_stop_job=Failed to stop job {0}. +errors.expired_dict_id=Expired dictionary information. Please reload it. +errors.failed_to_create_cache=Failed to create a cache reponse for ID:{0}. +errors.synonym_file_is_not_found=Synonym file is not found +errors.failed_to_download_synonym_file=Failed to download the Synonym file. +errors.failed_to_upload_synonym_file=Failed to upload the Synonym file. +errors.userdict_file_is_not_found=Synonym file is not found +errors.failed_to_download_userdict_file=Failed to download the UserDict file. +errors.failed_to_upload_userdict_file=Failed to upload the UserDict file. +errors.blank_password=Password is required. +errors.invalid_confirm_password=Confirm Password does not match. +errors.password_does_not_exist_in_session=Invalid password. + +errors.invalid_query_unknown=The given query is invalid. +errors.invalid_query_quoted=An invalid quote character is used. +errors.invalid_query_curly_bracket=An invalid curly bracket character is used. +errors.invalid_query_square_bracket=An invalid square bracket character is used. +errors.invalid_query_parenthesis=An invalid parenthesis character is used. +errors.invalid_query_num_range=An invalid range is used. The example of the range format is "field:[20020101 TO 20030101]". +errors.invalid_query_str_range=An invalid range is used. The example of the range format is "field:'{'Aida TO Carmen'}'". + +success.update_crawler_params=Updated parameters. +success.update_web_crawler_params=Updated parameters. +success.update_solr_params=Updated parameters. +success.commit_solr_index=Started a process to commit index. +success.optimize_solr_index=Started a process to optimize index. +success.delete_solr_index=Started a process to optimize index. +success.importing_data=Started to restore data from the uploaded file. +success.crawling_session_delete_all=Deleted session data. +success.start_crawl_process=Started a crawl process. +success.stopping_crawl_process=Stopping a crawl process. +success.upload_design_file=Uploaded {0}. +success.update_design_jsp_file=Updated {0}. +success.starting_solr_instance=Starting a solr instance. +success.stopping_solr_instance=Stopping a solr instance. +success.reloading_solr_instance=Reloading a solr instance. +success.update_crawler_schedule=Updated a crawling schedule. +success.create_crawling_config_at_wizard=Created a crawling config ({0}). +success.search_log_delete_all=Deleted search logs. +success.failure_url_delete_all=Deleted failure urls. +success.delete_file=Deleted {0} file. +success.user_info_delete_all=Deleted user information. +success.favorite_log_delete_all=Deleted popular urls +success.job_started=Started job {0}. +success.job_stopped=Stopped job {0}. +success.joblog_delete_all=Deleted job logs. +success.upload_synonym_file=Uploaded Synonym file. +success.upload_userdict_file=Uploaded UserDict file. +success.upload_suggest_elevate_word=Uploaded Additional Word file.
    Started to restore data. +success.upload_suggest_bad_word=Uploaded Bad Word file.
    Started to restore data. + +label.facet_label_title=Label +label.facet_lastModified_title=Term +label.facet_lastModified_1day=Past 24 Hours +label.facet_lastModified_1week=Past Week +label.facet_lastModified_1month=Past Month +label.facet_lastModified_1year=Past Year +label.facet_contentLength_title=Size +label.facet_contentLength_10k=  - 10kb +label.facet_contentLength_10kto100k=10kb - 100kb +label.facet_contentLength_100kto500k=100kb - 500kb +label.facet_contentLength_500kto1m=500kb - 1mb +label.facet_contentLength_1m=1mb -   +label.facet_filetype_title=File Type +label.facet_filetype_html=HTML +label.facet_filetype_word=Word +label.facet_filetype_excel=Excel +label.facet_filetype_powerpoint=PowerPoint +label.facet_filetype_pdf=PDF +label.facet_filetype_others=PDF +label.facet_label_reset=Reset + +errors.crud_invalid_mode=Invalid mode(expected value is {0}, but it's {1}). +errors.crud_failed_to_create_crud_table=Failed to create a new data. +errors.crud_failed_to_update_crud_table=Failed to update the data. +errors.crud_failed_to_delete_crud_table=Failed to delete the data. +errors.crud_could_not_find_crud_table=Could not find the data({0}). + +success.crud_create_crud_table=Created data. +success.crud_update_crud_table=Updated data. +success.crud_delete_crud_table=Deleted data. + diff --git a/src/main/resources/fess_message_ja.properties b/src/main/resources/fess_message_ja.properties index 58d2a7f26..94c30aa30 100644 --- a/src/main/resources/fess_message_ja.properties +++ b/src/main/resources/fess_message_ja.properties @@ -1,106 +1,151 @@ - -# ======================================================================================== -# Struts Default -# ============== -errors.header=
      -errors.footer=
    -errors.prefix=
  • -errors.suffix=
  • -errors.required={0}\u306f\u5fc5\u9808\u3067\u3059\u3002 -errors.minlength={0}\u306e\u9577\u3055\u304c\u6700\u5c0f\u5024({1})\u672a\u6e80\u3067\u3059\u3002 -errors.maxlength={0}\u306e\u9577\u3055\u304c\u6700\u5927\u5024({1})\u3092\u8d85\u3048\u3066\u3044\u307e\u3059\u3002 -errors.minbytelength={0}\u306e\u30d0\u30a4\u30c8\u9577\u304c\u6700\u5c0f\u5024({1})\u672a\u6e80\u3067\u3059\u3002 -errors.maxbytelength={0}\u306e\u30d0\u30a4\u30c8\u9577\u304c\u6700\u5927\u5024({1})\u3092\u8d85\u3048\u3066\u3044\u307e\u3059\u3002 +errors.front_header=
    +errors.front_footer=
    +errors.front_prefix=
    +errors.front_suffix=
    +errors.header=
    +errors.footer=
    +errors.prefix=

    +errors.suffix=

    errors.invalid={0}\u304c\u4e0d\u6b63\u3067\u3059\u3002 +errors.maxlength={0}\u306e\u9577\u3055\u304c\u6700\u5927\u5024({1})\u3092\u8d85\u3048\u3066\u3044\u307e\u3059\u3002 +errors.minlength={0}\u306e\u9577\u3055\u304c\u6700\u5c0f\u5024({1})\u672a\u6e80\u3067\u3059\u3002 +errors.maxbytelength={0}\u306e\u30d0\u30a4\u30c8\u9577\u304c\u6700\u5927\u5024({1})\u3092\u8d85\u3048\u3066\u3044\u307e\u3059\u3002 +errors.minbytelength={0}\u306e\u30d0\u30a4\u30c8\u9577\u304c\u6700\u5c0f\u5024({1})\u672a\u6e80\u3067\u3059\u3002 errors.range={0}\u306f{1}\u3068{2}\u306e\u9593\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 +errors.required={0}\u306f\u5fc5\u9808\u3067\u3059\u3002 errors.byte={0}\u306f\u30d0\u30a4\u30c8\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.short={0}\u306f\u77ed\u6574\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 +errors.date={0}\u306f\u65e5\u4ed8\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093 +errors.double={0}\u306f\u500d\u7cbe\u5ea6\u5b9f\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 +errors.float={0}\u306f\u5358\u7cbe\u5ea6\u5b9f\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 errors.integer={0}\u306f\u6574\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 errors.long={0}\u306f\u9577\u6574\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.float={0}\u306f\u5358\u7cbe\u5ea6\u5b9f\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.double={0}\u306f\u500d\u7cbe\u5ea6\u5b9f\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 -errors.date={0}\u306f\u65e5\u4ed8\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093 +errors.short={0}\u306f\u77ed\u6574\u6570\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 errors.creditcard={0}\u306f\u30af\u30ec\u30b8\u30c3\u30c8\u30ab\u30fc\u30c9\u756a\u53f7\u3068\u3057\u3066\u4e0d\u6b63\u3067\u3059\u3002 errors.email={0}\u306f\u30e1\u30fc\u30eb\u30a2\u30c9\u30ec\u30b9\u3068\u3057\u3066\u4e0d\u6b63\u3067\u3059\u3002 errors.url={0}\u306fURL\u3068\u3057\u3066\u4e0d\u6b63\u3067\u3059\u3002 +errors.cronexpression={0}\u306f\u6b63\u3057\u3044\u30d5\u30a9\u30fc\u30de\u30c3\u30c8\u3067\u306f\u3042\u308a\u307e\u305b\u3093\u3002 +errors.uritype={0}\u306f\u6b63\u3057\u3044 URI \u5f62\u5f0f\u3067\u306f\u3042\u308a\u307e\u305b\u3093\u3002 +errors.alphaDigitOnly={0}\u306f\u82f1\u6570\u5b57\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 +errors.alphaDigitSpaceOnly={0}\u306f\u82f1\u6570\u5b57\u307e\u305f\u306f\u7a7a\u767d\u3067\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002 +errors.token=\u4e0d\u6b63\u306a\u30ea\u30af\u30a8\u30b9\u30c8\u3067\u3059\u3002 +errors.failed_to_update_crawler_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002\u30b5\u30a4\u30c8\u7ba1\u7406\u8005\u306b\u9023\u7d61\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +errors.failed_to_update_web_crawler_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002\u30b5\u30a4\u30c8\u7ba1\u7406\u8005\u306b\u9023\u7d61\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +errors.failed_to_update_solr_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002\u30b5\u30a4\u30c8\u7ba1\u7406\u8005\u306b\u9023\u7d61\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +error.login_error=\u30e6\u30fc\u30b6\u30fc\u540d\u307e\u305f\u306f\u30d1\u30b9\u30ef\u30fc\u30c9\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 +errors.failed_to_commit_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u30b3\u30df\u30c3\u30c8\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_optimize_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u6700\u9069\u5316\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_delete_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u524a\u9664\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_start_solr_process_because_of_running=Solr\u30d7\u30ed\u30bb\u30b9\u304c\u5b9f\u884c\u4e2d\u306a\u306e\u3067\u3001\u51e6\u7406\u306e\u8d77\u52d5\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_import_data=\u8a2d\u5b9a\u30c7\u30fc\u30bf\u306e\u30ea\u30b9\u30c8\u30a2\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.unknown_import_file=\u672a\u77e5\u306e\u30d5\u30a1\u30a4\u30eb\u5f62\u5f0f\u3067\u3059\u3002 +errors.failed_to_export_data=\u8a2d\u5b9a\u30c7\u30fc\u30bf\u306e\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.could_not_find_log_file={0}\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 +errors.no_running_crawl_process=\u5b9f\u884c\u4e2d\u306e\u30d7\u30ed\u30bb\u30b9\u304c\u3042\u308a\u307e\u305b\u3093\u3002 +errors.failed_to_start_crawl_process=\u30af\u30ed\u30fc\u30eb\u30d7\u30ed\u30bb\u30b9\u3092\u958b\u59cb\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f\u3002 +errors.invalid_design_jsp_file_name=JSP\u30d5\u30a1\u30a4\u30eb\u540d\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 +errors.design_jsp_file_does_not_exist=JSP\u30d5\u30a1\u30a4\u30eb\u304c\u5b58\u5728\u3057\u307e\u305b\u3093\u3002 +errors.design_file_name_is_not_found=\u30d5\u30a1\u30a4\u30eb\u540d\u304c\u6307\u5b9a\u3055\u308c\u3066\u3044\u307e\u305b\u3093\u3002 +errors.failed_to_write_design_image_file=\u753b\u50cf\u30d5\u30a1\u30a4\u30eb\u306e\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u306b\u3057\u3063\u3071\u3044\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_update_jsp_file=JSP\u30d5\u30a1\u30a4\u30eb\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.design_file_name_is_invalid=\u30d5\u30a1\u30a4\u30eb\u540d\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 +errors.design_file_is_unsupported_type=\u30d5\u30a1\u30a4\u30eb\u540d\u306f\u30b5\u30dd\u30fc\u30c8\u3057\u3066\u3044\u307e\u305b\u3093\u3002 +errors.failed_to_start_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u8d77\u52d5\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_stop_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u505c\u6b62\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_reload_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u30ea\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_update_crawler_schedule=\u30af\u30ed\u30fc\u30eb\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_create_crawling_config_at_wizard=\u30af\u30ed\u30fc\u30eb\u8a2d\u5b9a\u306e\u4f5c\u6210\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.design_editor_disabled=\u3053\u306e\u6a5f\u80fd\u306f\u7121\u52b9\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002 +errors.could_not_create_search_log_csv=\u691c\u7d22\u30ed\u30b0\u306eCSV\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u6210\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f\u3002 +errors.not_found_on_file_system={0} \u306f\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 +errors.could_not_open_on_system={0}\u306f\u958b\u3051\u307e\u305b\u3093\u3067\u3057\u305f\u3002
    \u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306b\u95a2\u9023\u4ed8\u3051\u3089\u308c\u3066\u3044\u308b\u304b\u78ba\u8a8d\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +errors.process_time_is_exceeded=\u691c\u7d22\u51e6\u7406\u6642\u9593\u306e\u4e0a\u9650\u3092\u8d85\u3048\u305f\u305f\u3081\u3001\u691c\u7d22\u7d50\u679c\u306e\u4e00\u90e8\u304c\u8868\u793a\u3055\u308c\u3066\u3044\u307e\u3059\u3002 +errors.result_size_exceeded=\u3053\u308c\u4ee5\u4e0a\u306e\u691c\u7d22\u7d50\u679c\u306e\u8868\u793a\u306f\u3067\u304d\u307e\u305b\u3093\u3002 +errors.target_file_does_not_exist=\u30d5\u30a1\u30a4\u30eb {0} \u304c\u5b58\u5728\u3057\u307e\u305b\u3093\u3002 +errors.failed_to_download_file={0} \u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_delete_file=\u30d5\u30a1\u30a4\u30eb {0} \u306e\u524a\u9664\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_redirect={0}\u3078\u306e\u30ea\u30c0\u30a4\u30ec\u30af\u30c8\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.unsupported_encoding={0}\u306f\u30b5\u30dd\u30fc\u30c8\u3055\u308c\u3066\u3044\u306a\u3044\u30a8\u30f3\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u3067\u3059\u3002 +errors.docid_not_found=ID:{0}\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 +errors.document_not_found=ID:{0}\u306eURL\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 +errors.not_load_from_server=\u3053\u306e\u30b5\u30fc\u30d0\u304b\u3089\u30ed\u30fc\u30c9\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f: {0} +errors.failed_to_start_job=\u30b8\u30e7\u30d6 {0} \u306e\u958b\u59cb\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_stop_job=\u30b8\u30e7\u30d6 {0} \u306e\u958b\u59cb\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.expired_dict_id=\u8f9e\u66f8\u60c5\u5831\u304c\u671f\u9650\u5207\u308c\u3067\u3059\u3002\u518d\u5ea6\u8aad\u307f\u306a\u304a\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +errors.failed_to_create_cache=ID:{0}\u306e\u30ad\u30e3\u30c3\u30b7\u30e5\u304c\u751f\u6210\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f\u3002 +errors.synonym_file_is_not_found=\u540c\u7fa9\u8a9e\u30d5\u30a1\u30a4\u30eb\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 +errors.failed_to_download_synonym_file=\u540c\u7fa9\u8a9e\u30d5\u30a1\u30a4\u30eb\u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_upload_synonym_file=\u540c\u7fa9\u8a9e\u30d5\u30a1\u30a4\u30eb\u306e\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.userdict_file_is_not_found=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u30d5\u30a1\u30a4\u30eb\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 +errors.failed_to_download_userdict_file=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u30d5\u30a1\u30a4\u30eb\u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.failed_to_upload_userdict_file=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u30d5\u30a1\u30a4\u30eb\u306e\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -# ======================================================================================== -# Project Common -# ============== -# ---------------------------------------------------------- -# Value Message -# ------------- -errors.number={0}\u306f\u6570\u5024\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044 -errors.same.value={0}\u306b\u540c\u4e00\u306e\u9805\u76ee\u304c\u9078\u3070\u308c\u3066\u3044\u307e\u3059 -errors.greater.than={0}\u306f{1}\u3088\u308a\u5927\u304d\u3044\u6570\u5024\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044 -errors.required.at.least.one={0}\u306e\u3044\u305a\u308c\u304b\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044 -errors.required.or={0}\u3068{1}\u306e\u3069\u3061\u3089\u304b\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044 -errors.upload.size=\u4e0a\u9650\u304c{1}\u30d0\u30a4\u30c8\u306a\u306e\u306b\u5b9f\u969b\u306f{0}\u30d0\u30a4\u30c8\u3060\u3063\u305f\u306e\u3067\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f\u3002 +errors.invalid_query_unknown=\u691c\u7d22\u30af\u30a8\u30ea\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 +errors.invalid_query_quoted=\u30af\u30aa\u30fc\u30c8\u6587\u5b57(")\u306e\u5229\u7528\u65b9\u6cd5\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 +errors.invalid_query_curly_bracket=\u62ec\u5f27\u300c'{}'\u300d\u306e\u5229\u7528\u65b9\u6cd5\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 +errors.invalid_query_square_bracket=\u62ec\u5f27\u300c[]\u300d\u306e\u5229\u7528\u65b9\u6cd5\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 +errors.invalid_query_parenthesis=\u62ec\u5f27\u300c()\u300d\u306e\u5229\u7528\u65b9\u6cd5\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002 +errors.invalid_query_num_range=\u7bc4\u56f2\u306e\u6307\u5b9a\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002\u6b63\u3057\u3044\u4f8b: field:[20020101 TO 20030101] +errors.invalid_query_str_range=\u7bc4\u56f2\u306e\u6307\u5b9a\u304c\u6b63\u3057\u304f\u3042\u308a\u307e\u305b\u3093\u3002\u6b63\u3057\u3044\u4f8b: "field:'{'Aida TO Carmen'}'" -# ---------------------------------------------------------- -# Business Message -# ---------------- -errors.empty.login=\u30e1\u30fc\u30eb\u30a2\u30c9\u30ec\u30b9\u307e\u305f\u306f\u30d1\u30b9\u30ef\u30fc\u30c9\u304c\u672a\u5165\u529b\u3067\u3059 -errors.not.login=\u30e1\u30fc\u30eb\u30a2\u30c9\u30ec\u30b9\u53c8\u306f\u30d1\u30b9\u30ef\u30fc\u30c9\u304c\u9593\u9055\u3063\u3066\u3044\u307e\u3059 -errors.email.exists=\u65e2\u306b\u767b\u9332\u6e08\u307f\u306e\u30e1\u30fc\u30eb\u30a2\u30c9\u30ec\u30b9\u3067\u3059 -errors.already.registered={0}\u306f\u3059\u3067\u306b\u767b\u9332\u3055\u308c\u3066\u3044\u308b{1}\u3067\u3059 +success.update_crawler_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 +success.update_web_crawler_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 +success.update_solr_params=\u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 +success.commit_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u30b3\u30df\u30c3\u30c8\u30d7\u30ed\u30bb\u30b9\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 +success.optimize_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u6700\u9069\u5316\u30d7\u30ed\u30bb\u30b9\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 +success.delete_solr_index=\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u524a\u9664\u30d7\u30ed\u30bb\u30b9\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 +success.importing_data=\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3055\u308c\u305f\u30d5\u30a1\u30a4\u30eb\u304b\u3089\u306e\u30c7\u30fc\u30bf\u30ea\u30b9\u30c8\u30a2\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 +success.crawling_session_delete_all=\u30bb\u30c3\u30b7\u30e7\u30f3\u30c7\u30fc\u30bf\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 +success.start_crawl_process=\u30af\u30ed\u30fc\u30eb\u30d7\u30ed\u30bb\u30b9\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 +success.stopping_crawl_process=\u30af\u30ed\u30fc\u30eb\u30d7\u30ed\u30bb\u30b9\u3092\u505c\u6b62\u3057\u3066\u3044\u307e\u3059\u3002\u3057\u3070\u3089\u304f\u304a\u5f85\u3061\u304f\u3060\u3055\u3044\u3002 +success.upload_design_file={0} \u3092\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u307e\u3057\u305f\u3002 +success.update_design_jsp_file={0} \u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 +success.starting_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u8d77\u52d5\u3057\u3066\u3044\u307e\u3059\u3002 +success.stopping_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u505c\u6b62\u3057\u3066\u3044\u307e\u3059\u3002 +success.reloading_solr_instance=Solr\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u30ea\u30ed\u30fc\u30c9\u3057\u3066\u3044\u307e\u3059\u3002 +success.update_crawler_schedule=\u30af\u30ed\u30fc\u30eb\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 +success.create_crawling_config_at_wizard=\u30af\u30ed\u30fc\u30eb\u8a2d\u5b9a {0} \u3092\u8ffd\u52a0\u3057\u307e\u3057\u305f\u3002 +success.search_log_delete_all=\u691c\u7d22\u30ed\u30b0\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 +success.failure_url_delete_all=\u969c\u5bb3URL\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 +success.delete_file=\u30d5\u30a1\u30a4\u30eb {0} \u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 +success.user_info_delete_all= \u5229\u7528\u8005\u60c5\u5831\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 +success.favorite_log_delete_all=\u4eba\u6c17URL\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 +success.job_started=\u30b8\u30e7\u30d6 {0} \u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 +success.job_stopped=\u30b8\u30e7\u30d6 {0} \u3092\u505c\u6b62\u3057\u307e\u3057\u305f\u3002 +success.joblog_delete_all=\u30b8\u30e7\u30d6\u30ed\u30b0\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 +success.upload_synonym_file=\u540c\u7fa9\u8a9e\u30d5\u30a1\u30a4\u30eb\u3092\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u307e\u3057\u305f\u3002 +success.upload_userdict_file=\u30e6\u30fc\u30b6\u30fc\u8f9e\u66f8\u30d5\u30a1\u30a4\u30eb\u3092\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u307e\u3057\u305f\u3002 +success.upload_suggest_elevate_word=\u8ffd\u52a0\u5019\u88dc\u30d5\u30a1\u30a4\u30eb\u306e\u767b\u9332\u51e6\u7406\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 +success.upload_suggest_bad_word=NG\u30ef\u30fc\u30c9\u30d5\u30a1\u30a4\u30eb\u306e\u767b\u9332\u51e6\u7406\u3092\u958b\u59cb\u3057\u307e\u3057\u305f\u3002 -# ---------------------------------------------------------- -# Application Exception -# --------------------- -errors.app.already.deleted=\u4ed6\u306e\u4eba\u304c\u66f4\u65b0\u3057\u305f\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002\u518d\u5ea6\u3084\u308a\u76f4\u3057\u3066\u304f\u3060\u3055\u3044 -errors.app.already.updated=\u4ed6\u306e\u4eba\u304c\u66f4\u65b0\u3057\u305f\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002\u518d\u5ea6\u3084\u308a\u76f4\u3057\u3066\u304f\u3060\u3055\u3044 -errors.app.already.exists=\u65e2\u306b\u767b\u9332\u3055\u308c\u3066\u3044\u308b\u30c7\u30fc\u30bf\u3067\u3059\u3002\u518d\u5ea6\u3084\u308a\u76f4\u3057\u3066\u304f\u3060\u3055\u3044 -errors.app.illegal.transition=\u4e0d\u6b63\u306a\u30a2\u30af\u30bb\u30b9\u304c\u3055\u308c\u307e\u3057\u305f\u3002\u518d\u5ea6\u3084\u308a\u76f4\u3057\u3066\u304f\u3060\u3055\u3044 +label.facet_label_title=\u30e9\u30d9\u30eb +label.facet_lastModified_title=\u671f\u9593 +label.facet_lastModified_1day=24 \u6642\u9593\u4ee5\u5185 +label.facet_lastModified_1week=1 \u9031\u9593\u4ee5\u5185 +label.facet_lastModified_1month=1 \u30f6\u6708\u4ee5\u5185 +label.facet_lastModified_1year=1 \u5e74\u4ee5\u5185 +label.facet_contentLength_title=\u30b5\u30a4\u30ba +label.facet_contentLength_10k=  - 10KB +label.facet_contentLength_10kto100k=10KB - 100KB +label.facet_contentLength_100kto500k=100KB - 500KB +label.facet_contentLength_500kto1m=500KB - 1MB +label.facet_contentLength_1m=1MB -   +label.facet_filetype_title=\u30d5\u30a1\u30a4\u30eb\u306e\u7a2e\u985e +label.facet_filetype_html=HTML +label.facet_filetype_word=Word +label.facet_filetype_excel=Excel +label.facet_filetype_powerpoint=PowerPoint +label.facet_filetype_pdf=PDF +label.facet_filetype_others=\u305d\u306e\u4ed6 +label.facet_label_reset=\u30ea\u30bb\u30c3\u30c8 +errors.crud_invalid_mode=\u30e2\u30fc\u30c9\u304c\u9055\u3044\u307e\u3059\u3002(\u6b63\u3057\u3044\u5024\u306f {0} \u3067\u3059\u304c\u3001\u5165\u529b\u3055\u308c\u305f\u5024\u306f {1} \u306b\u306a\u3063\u3066\u3044\u307e\u3059) +errors.crud_failed_to_create_crud_table=\u30c7\u30fc\u30bf\u306e\u4f5c\u6210\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.crud_failed_to_update_crud_table=\u30c7\u30fc\u30bf\u306e\u66f4\u65b0\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.crud_failed_to_delete_crud_table=\u30c7\u30fc\u30bf\u306e\u524a\u9664\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 +errors.crud_could_not_find_crud_table=\u30c7\u30fc\u30bf {0} \u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002 -# ======================================================================================== -# Labels -# ====== -# ---------------------------------------------------------- -# Entity -# ------ -labels.member = \u4f1a\u54e1 +success.crud_create_crud_table=\u30c7\u30fc\u30bf\u3092\u4f5c\u6210\u3057\u307e\u3057\u305f\u3002 +success.crud_update_crud_table=\u30c7\u30fc\u30bf\u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 +success.crud_delete_crud_table=\u30c7\u30fc\u30bf\u3092\u524a\u9664\u3057\u307e\u3057\u305f\u3002 -# ---------------------------------------------------------- -# Attribute -# --------- -labels.memberId = \u4f1a\u54e1ID -labels.memberName = \u4f1a\u54e1\u540d\u79f0 -labels.email = \u30e1\u30fc\u30eb\u30a2\u30c9\u30ec\u30b9 -labels.emailOrAccount = \u30e1\u30a2\u30c9\u3082\u3057\u304f\u306f\u30a2\u30ab\u30a6\u30f3\u30c8 -labels.password = \u30d1\u30b9\u30ef\u30fc\u30c9 -labels.versionNo = \u30d0\u30fc\u30b8\u30e7\u30f3No - -# ---------------------------------------------------------- -# Screen -# ------ -labels.list = \u4e00\u89a7 -labels.add = \u8ffd\u52a0 -labels.edit = \u7de8\u96c6 -labels.search = \u691c\u7d22 -labels.register = \u767b\u9332 -labels.update = \u66f4\u65b0 - -labels.member.list = @[labels.member]@[labels.list] -labels.member.add = @[labels.member]@[labels.add] -labels.member.edit = @[labels.member]@[labels.edit] - -# ---------------------------------------------------------- -# Header Title -# ------------ -labels.header.title.error.message = \u304a\u77e5\u3089\u305b - - -# ======================================================================================== -# Messages -# ======== -# ---------------------------------------------------------- -# Input Note -# ---------- -messages.input.note.keyword = \u691c\u7d22\u30ad\u30fc\u30ef\u30fc\u30c9\u3092\u5165\u529b -messages.input.note.email = \u30e1\u30fc\u30eb\u30a2\u30c9\u30ec\u30b9\u3092\u5165\u529b -messages.input.note.emailOrAccount = Pixy \u3063\u3066\u5165\u308c\u3066\u30fc -messages.input.note.password = sea \u3063\u3066\u5165\u308c\u3066\u30fc -messages.input.note.zipCode = \u4f8b: 153-0051 diff --git a/src/main/resources/jdbc.dicon b/src/main/resources/jdbc.dicon deleted file mode 100644 index 68e0390ca..000000000 --- a/src/main/resources/jdbc.dicon +++ /dev/null @@ -1,169 +0,0 @@ - - - - - - - - - - - - "org.h2.Driver" - - - "jdbc:h2:tcp://localhost:19092/fess" - - + ";DB_CLOSE_ON_EXIT=FALSE;LOG=2;MVCC=true" - - "sa" - - - - - - - - - - - - - - - - - - - 600 - 10 - true - - - - - - - - - - diff --git a/src/main/resources/lasta_di.properties b/src/main/resources/lasta_di.properties new file mode 100644 index 000000000..c65e9325b --- /dev/null +++ b/src/main/resources/lasta_di.properties @@ -0,0 +1,9 @@ +# _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ +# Lasta Di properties, you can set container's options +# _/_/_/_/_/_/_/_/_/_/ + +# location of smart-deploy mode e.g. maihama_env.properties: lasta_di.smart.deploy.mode +smart.deploy.mode.location = fess_env.properties: lasta_di.smart.deploy.mode + +# package for smart deploy target e.g. org.docksidestage.app +smart.package1 = org.codelibs.fess.app diff --git a/src/main/resources/lastaflute_director.xml b/src/main/resources/lastaflute_director.xml new file mode 100644 index 000000000..6a0616df8 --- /dev/null +++ b/src/main/resources/lastaflute_director.xml @@ -0,0 +1,7 @@ + + + + + + diff --git a/src/main/resources/log4j.xml b/src/main/resources/log4j.xml deleted file mode 100644 index f3beb7024..000000000 --- a/src/main/resources/log4j.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/main/resources/logback.xml b/src/main/resources/logback.xml new file mode 100644 index 000000000..c45dc0edc --- /dev/null +++ b/src/main/resources/logback.xml @@ -0,0 +1,97 @@ + + + + + + + + + + + + + + ${log.pattern} + + + + ${log.file.basedir}/${domain.name}.log + true + + ${log.pattern} + + + ${log.file.basedir}/backup/${domain.name}${backup.date.suffix}.log + + ${backup.max.history} + + + + ${log.file.basedir}/audit.log + true + + ${audit.log.pattern} + + + ${log.file.basedir}/backup/audit${backup.date.suffix}.log + + ${backup.max.history} + + + + ${log.file.basedir}/mail.log + true + + ${log.pattern} + + + ${log.file.basedir}/backup/mail${backup.date.suffix}.log + + ${backup.max.history} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/main/resources/my_creator.xml b/src/main/resources/my_creator.xml new file mode 100644 index 000000000..80ab459d6 --- /dev/null +++ b/src/main/resources/my_creator.xml @@ -0,0 +1,7 @@ + + + + + + diff --git a/src/main/resources/s2container.dicon b/src/main/resources/s2container.dicon deleted file mode 100644 index 8ea4cffc5..000000000 --- a/src/main/resources/s2container.dicon +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/main/resources/s2robot/contentlength.xml b/src/main/resources/s2robot/contentlength.xml new file mode 100644 index 000000000..7c314d1d6 --- /dev/null +++ b/src/main/resources/s2robot/contentlength.xml @@ -0,0 +1,15 @@ + + + + + + + 10485760 + + "text/html" + 2621440 + + + diff --git a/src/main/resources/s2robot/es.xml b/src/main/resources/s2robot/es.xml new file mode 100644 index 000000000..4d9d756b9 --- /dev/null +++ b/src/main/resources/s2robot/es.xml @@ -0,0 +1,8 @@ + + + + + + diff --git a/src/main/resources/s2robot/interval.xml b/src/main/resources/s2robot/interval.xml new file mode 100644 index 000000000..33eceda48 --- /dev/null +++ b/src/main/resources/s2robot/interval.xml @@ -0,0 +1,11 @@ + + + + + + + + diff --git a/src/main/resources/s2robot/log.xml b/src/main/resources/s2robot/log.xml new file mode 100644 index 000000000..505e6b19a --- /dev/null +++ b/src/main/resources/s2robot/log.xml @@ -0,0 +1,10 @@ + + + + + + + + diff --git a/src/main/resources/s2robot_rule.dicon b/src/main/resources/s2robot/rule.xml similarity index 68% rename from src/main/resources/s2robot_rule.dicon rename to src/main/resources/s2robot/rule.xml index 2414f919c..4c905265c 100644 --- a/src/main/resources/s2robot_rule.dicon +++ b/src/main/resources/s2robot/rule.xml @@ -1,25 +1,26 @@ - - - - + + + + + - + sitemapsRule - - + + webHtmlRule - - + + webFileRule - - + + fsFileRule - - + + defaultRule - + @@ -28,10 +29,10 @@ - + "url" "http[s]?:.*sitemap[^/]*.xml$|http[s]?:.*sitemap[^/]*.gz$|http[s]?:.*sitemap[^/]*.txt$" - + @@ -39,20 +40,20 @@ fessXpathTransformer - new int[] {200} - new int[] {304} + (int[])[200] + (int[])[304] true - + "url" "http[s]?:.*" - - + + "mimeType" "text/html" - + @@ -60,16 +61,16 @@ fessFileTransformer - new int[] {200} - new int[] {304} + (int[])[200] + (int[])[304] true - + "url" "http[s]?:.*" - - + + "mimeType" @@ -81,7 +82,7 @@ + "|text/xml" + "|text/xml-external-parsed-entity)" - + @@ -89,16 +90,16 @@ fessFileTransformer - new int[] {200} - new int[] {304} + (int[])[200] + (int[])[304] true - + "url" "file:.*" - - + + "mimeType" @@ -111,7 +112,7 @@ + "|text/xml-external-parsed-entity" + "|text/html)" - + @@ -120,15 +121,15 @@ fessTikaTransformer - new int[] {200} - new int[] {304} + (int[])[200] + (int[])[304] true - + "url" ".*" - +
    diff --git a/src/main/resources/s2robot_transformer.dicon b/src/main/resources/s2robot/transformer.xml similarity index 67% rename from src/main/resources/s2robot_transformer.dicon rename to src/main/resources/s2robot/transformer.xml index 537628289..a2e68741f 100644 --- a/src/main/resources/s2robot_transformer.dicon +++ b/src/main/resources/s2robot/transformer.xml @@ -1,10 +1,11 @@ - - - + + + - + + "fessXpathTransformer" defaultFeatureMap defaultPropertyMap @@ -13,7 +14,7 @@ @java.util.regex.Pattern@compile("^\\s*javascript:|^\\s*mailto:|^\\s*irc:|^\\s*skype:|^\\s*callto:",@java.util.regex.Pattern@CASE_INSENSITIVE) --> - #{"feed:" : "http:"} + {"feed:" : "http:"} - + "title" "//TITLE" - - + + "noscript" - - + + "script" - + - + "fessFileTransformer" true "UTF-8" - + "title" "title" - - + + "Title" "title" - + - + "fessTikaTransformer" true "UTF-8" - + "title" "title" - - + + "Title" "title" - + diff --git a/src/main/resources/s2robot_contentlength.dicon b/src/main/resources/s2robot_contentlength.dicon deleted file mode 100644 index f79cf5ba5..000000000 --- a/src/main/resources/s2robot_contentlength.dicon +++ /dev/null @@ -1,12 +0,0 @@ - - - - - 10485760L - - "text/html" - 2621440L - - - diff --git a/src/main/resources/s2robot_db.dicon b/src/main/resources/s2robot_db.dicon deleted file mode 100644 index 8a13a5437..000000000 --- a/src/main/resources/s2robot_db.dicon +++ /dev/null @@ -1,49 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - true - - - - - - - - - - - - s2robot_j2ee.requiredTx - - - - - s2robot_j2ee.requiredTx - - - - - s2robot_j2ee.requiredTx - - - - diff --git a/src/main/resources/s2robot_es.xml b/src/main/resources/s2robot_es.xml new file mode 100644 index 000000000..3dfdb1708 --- /dev/null +++ b/src/main/resources/s2robot_es.xml @@ -0,0 +1,52 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ".robot" + "queue" + + + ".robot" + "data" + + + ".robot" + "filter" + + + diff --git a/src/main/resources/s2robot_interval.dicon b/src/main/resources/s2robot_interval.dicon deleted file mode 100644 index 200967f42..000000000 --- a/src/main/resources/s2robot_interval.dicon +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - diff --git a/src/main/resources/s2robot_jdbc.dicon b/src/main/resources/s2robot_jdbc.dicon deleted file mode 100644 index 287255e92..000000000 --- a/src/main/resources/s2robot_jdbc.dicon +++ /dev/null @@ -1,50 +0,0 @@ - - - - - - - - - "org.h2.Driver" - - - "jdbc:h2:file:" - + @org.codelibs.fess.util.ResourceUtil@getDbPath("robot") - + ";DB_CLOSE_ON_EXIT=FALSE;LOG=2;MVCC=true" - - "sa" - - - - - - - - 600 - 10 - true - @java.sql.Connection@TRANSACTION_REPEATABLE_READ - - - - - - diff --git a/src/main/resources/s2robot_log.dicon b/src/main/resources/s2robot_log.dicon deleted file mode 100644 index 4cbdcf3a6..000000000 --- a/src/main/resources/s2robot_log.dicon +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - diff --git a/src/main/resources/saflute_assist++.dicon b/src/main/resources/saflute_assist++.dicon deleted file mode 100644 index 51e60e162..000000000 --- a/src/main/resources/saflute_assist++.dicon +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - diff --git a/src/main/webapp/WEB-INF/cmd/lib/geronimo-servlet_2.4_spec-1.0.jar b/src/main/webapp/WEB-INF/cmd/lib/geronimo-servlet_2.4_spec-1.0.jar deleted file mode 100644 index c82fdfc3a..000000000 Binary files a/src/main/webapp/WEB-INF/cmd/lib/geronimo-servlet_2.4_spec-1.0.jar and /dev/null differ diff --git a/src/main/webapp/WEB-INF/cmd/resources/app.dicon b/src/main/webapp/WEB-INF/cmd/resources/app.xml similarity index 62% rename from src/main/webapp/WEB-INF/cmd/resources/app.dicon rename to src/main/webapp/WEB-INF/cmd/resources/app.xml index 3382c723d..86e3d2d6b 100644 --- a/src/main/webapp/WEB-INF/cmd/resources/app.dicon +++ b/src/main/webapp/WEB-INF/cmd/resources/app.xml @@ -1,14 +1,11 @@ - + - - - - - + + - + @@ -22,78 +19,69 @@
    - - + "text/html" "html" - - + + "application/msword" "word" - - + + "application/vnd.openxmlformats-officedocument.wordprocessingml.document" "word" - - + + "application/vnd.ms-excel" "excel" - - + + "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" "excel" - - + + "application/vnd.ms-powerpoint" "powerpoint" - - + + "application/vnd.openxmlformats-officedocument.presentationml.presentation" "powerpoint" - - + + "application/pdf" "pdf" - - - - - - - j2ee.requiresNewTx - + diff --git a/src/main/webapp/WEB-INF/cmd/resources/creator.dicon b/src/main/webapp/WEB-INF/cmd/resources/creator.dicon deleted file mode 100644 index 5735dc84c..000000000 --- a/src/main/webapp/WEB-INF/cmd/resources/creator.dicon +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - - - - - - diff --git a/src/main/webapp/WEB-INF/cmd/resources/customizer.dicon b/src/main/webapp/WEB-INF/cmd/resources/customizer.dicon deleted file mode 100644 index 68fc78de5..000000000 --- a/src/main/webapp/WEB-INF/cmd/resources/customizer.dicon +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - - "aop.traceInterceptor" - - - - - - - - - diff --git a/src/main/webapp/WEB-INF/cmd/resources/fess_env_production.properties b/src/main/webapp/WEB-INF/cmd/resources/fess_env_production.properties new file mode 100644 index 000000000..ce9094a55 --- /dev/null +++ b/src/main/webapp/WEB-INF/cmd/resources/fess_env_production.properties @@ -0,0 +1,47 @@ +# _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ +# Fess environment configuration for Local Development +# _/_/_/_/_/_/_/_/_/_/ +# ======================================================================================== +# Core +# ====== +# The mode of Lasta Di's smart-deploy, should be cool in production (e.g. hot, cool, warm) +lasta_di.smart.deploy.mode = warm + +# Is development environment here? (used for various purpose, you should set false if unknown) +development.here = false + +# The title of environment (e.g. local or integartion or production) +environment.title = Production + +# Does it enable the Framework internal debug? (true only when emergency) +framework.debug = false + +# one day: 86400000, three days: 259200000, five days: 432000000, one week: 604800000, one year: 31556926000 +# special script :: absolute mode: $(2014/07/10), relative mode: addDay(3).addMonth(4) +# The milliseconds for (relative or absolute) adjust time (set only when test) @LongType *dynamic in development +time.adjust.time.millis = 0 + +# ---------------------------------------------------------- +# Mail +# ------ +# Does it send mock mail? (true: no send actually, logging only) +mail.send.mock = true + +# SMTP server settings for main: host:port +mail.smtp.server.main.host.and.port = localhost:25 + +# The prefix of subject to show test environment or not +mail.subject.test.prefix = + +# The common return path of all mail +mail.return.path = root@localhost + + +# ======================================================================================== +# DB +# ==== + + +# ======================================================================================== +# Web +# ===== diff --git a/src/main/webapp/WEB-INF/cmd/resources/my_creator.xml b/src/main/webapp/WEB-INF/cmd/resources/my_creator.xml new file mode 100644 index 000000000..d217ba27f --- /dev/null +++ b/src/main/webapp/WEB-INF/cmd/resources/my_creator.xml @@ -0,0 +1,5 @@ + + + + diff --git a/src/main/webapp/WEB-INF/struts-config.xml b/src/main/webapp/WEB-INF/struts-config.xml deleted file mode 100644 index 56e92fb0f..000000000 --- a/src/main/webapp/WEB-INF/struts-config.xml +++ /dev/null @@ -1,55 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/main/webapp/WEB-INF/view/admin/boostDocumentRule/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/boostdocumentrule/confirm.jsp similarity index 50% rename from src/main/webapp/WEB-INF/view/admin/boostDocumentRule/confirm.jsp rename to src/main/webapp/WEB-INF/view/admin/boostdocumentrule/confirm.jsp index 230bf8f97..1d1c65080 100644 --- a/src/main/webapp/WEB-INF/view/admin/boostDocumentRule/confirm.jsp +++ b/src/main/webapp/WEB-INF/view/admin/boostdocumentrule/confirm.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.boost_document_rule_configuration" /> +Fess | <la:message key="labels.boost_document_rule_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,14 +42,14 @@
    <%-- Form --%> - - + + - - + + - - + +
    @@ -57,50 +57,50 @@

    - + - + - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%> - - + + - - + + - - + +
    ${f:h(urlExpr)}${f:h(urlExpr)}
    ${f:h(boostExpr)}${f:h(boostExpr)}
    ${f:h(sortOrder)}${f:h(sortOrder)}
    @@ -109,37 +109,37 @@ <%-- Box Footer --%>
    - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/boostDocumentRule/edit.jsp b/src/main/webapp/WEB-INF/view/admin/boostdocumentrule/edit.jsp similarity index 50% rename from src/main/webapp/WEB-INF/view/admin/boostDocumentRule/edit.jsp rename to src/main/webapp/WEB-INF/view/admin/boostdocumentrule/edit.jsp index c42cc1d27..81cbb4f64 100644 --- a/src/main/webapp/WEB-INF/view/admin/boostDocumentRule/edit.jsp +++ b/src/main/webapp/WEB-INF/view/admin/boostdocumentrule/edit.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.boost_document_rule_configuration" /> +Fess | <la:message key="labels.boost_document_rule_configuration" /> @@ -19,23 +19,23 @@ <%-- Content Header --%>

    - +

    @@ -43,14 +43,14 @@
    <%-- Form --%> - - + + - - + + - - + +
    @@ -58,63 +58,63 @@

    - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%>
    - - + +
    - - + +
    - - + +
    <%-- Box Footer --%>
    -
    +
    diff --git a/src/main/webapp/WEB-INF/view/admin/boostDocumentRule/error.jsp b/src/main/webapp/WEB-INF/view/admin/boostdocumentrule/error.jsp similarity index 70% rename from src/main/webapp/WEB-INF/view/admin/boostDocumentRule/error.jsp rename to src/main/webapp/WEB-INF/view/admin/boostdocumentrule/error.jsp index bcc993cd6..f19bb1bca 100644 --- a/src/main/webapp/WEB-INF/view/admin/boostDocumentRule/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/boostdocumentrule/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.boost_document_rule_configuration" /> +Fess | <la:message key="labels.boost_document_rule_configuration" /> @@ -15,12 +15,12 @@

    - +

    @@ -29,12 +29,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/boostDocumentRule/index.jsp b/src/main/webapp/WEB-INF/view/admin/boostdocumentrule/index.jsp similarity index 63% rename from src/main/webapp/WEB-INF/view/admin/boostDocumentRule/index.jsp rename to src/main/webapp/WEB-INF/view/admin/boostdocumentrule/index.jsp index 6137abbd2..09296b368 100644 --- a/src/main/webapp/WEB-INF/view/admin/boostDocumentRule/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/boostdocumentrule/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.boost_document_rule_configuration" /> +Fess | <la:message key="labels.boost_document_rule_configuration" /> @@ -17,12 +17,12 @@ <%-- Content Header --%>

    - +

    @@ -34,41 +34,41 @@ <%-- Box Header --%>

    - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - + - + @@ -80,31 +80,31 @@ <%-- Box Footer --%>
    ${f:h(data.urlExpr)}
    - - + + - + @@ -112,24 +109,24 @@ <%-- Box Footer --%> - + diff --git a/src/main/webapp/WEB-INF/view/admin/crawlingSession/error.jsp b/src/main/webapp/WEB-INF/view/admin/crawlingsession/error.jsp similarity index 67% rename from src/main/webapp/WEB-INF/view/admin/crawlingSession/error.jsp rename to src/main/webapp/WEB-INF/view/admin/crawlingsession/error.jsp index dc591581d..cfcaeb7a5 100644 --- a/src/main/webapp/WEB-INF/view/admin/crawlingSession/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/crawlingsession/error.jsp @@ -2,26 +2,26 @@ -Fess | <bean:message key="labels.crawling_session_configuration" /> +Fess | <la:message key="labels.crawling_session_configuration" />
    - +

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/crawlingSession/index.jsp b/src/main/webapp/WEB-INF/view/admin/crawlingsession/index.jsp similarity index 55% rename from src/main/webapp/WEB-INF/view/admin/crawlingSession/index.jsp rename to src/main/webapp/WEB-INF/view/admin/crawlingsession/index.jsp index 49d80f463..f4065b530 100644 --- a/src/main/webapp/WEB-INF/view/admin/crawlingSession/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/crawlingsession/index.jsp @@ -2,14 +2,14 @@ -Fess | <bean:message key="labels.crawling_session_configuration" /> +Fess | <la:message key="labels.crawling_session_configuration" />
    - + @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,62 +35,62 @@ <%-- Box Header --%>

    - +

    - - + value="" /> +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    ${f:h(sessionId)} - ${f:h(sessionId)} +
    ${f:h(sessionId)}
    - - - + + + - + - @@ -105,7 +105,7 @@ - - - + + <%-- Paging Info --%> - <%-- Paging Navigation --%>
      - + - + -
    • class="active">${p} +
    • class="active">${p}
    • - + - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/data/index.jsp b/src/main/webapp/WEB-INF/view/admin/data/index.jsp index 0e1ff7802..058e2581c 100644 --- a/src/main/webapp/WEB-INF/view/admin/data/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/data/index.jsp @@ -1,5 +1,5 @@ <%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - + @@ -11,62 +11,62 @@ <%-- Message: BEGIN --%>
    - -
    -
    - + +
    ${msg}
    +
    +
    <%-- Message: END --%> - +
    -

    +

    ${f:h(data.sessionId)} ${f:h(data.createdTime)} - + ${f:h(data.expiredTime)} - - - - - + + + + + + +
    - + - +
    - + - +
    - + - +
    - + - +
    - - + +
    -

    +

    - + @@ -74,23 +74,23 @@
    - + - +
    - "/> + "/>
    -
    +
    diff --git a/src/main/webapp/WEB-INF/view/admin/dataConfig/edit.jsp b/src/main/webapp/WEB-INF/view/admin/dataConfig/edit.jsp deleted file mode 100644 index 3a9395a56..000000000 --- a/src/main/webapp/WEB-INF/view/admin/dataConfig/edit.jsp +++ /dev/null @@ -1,165 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.data_crawling_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - -

    -
    - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - <%-- Form Fields --%> -
    - - -
    -
    - - - - ${f:h(hn.label)} - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - - - ${f:h(rt.name)} - - -
    -
    - - - - ${f:h(l.name)} - - -
    -
    - - - - - - - - - -
    -
    - - <%-- Box Footer --%> - -
    -
    -
    -
    - -
    -
    - - -
    - - - diff --git a/src/main/webapp/WEB-INF/view/admin/dataConfig/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/dataconfig/confirm.jsp similarity index 53% rename from src/main/webapp/WEB-INF/view/admin/dataConfig/confirm.jsp rename to src/main/webapp/WEB-INF/view/admin/dataconfig/confirm.jsp index 4ee2c2f63..f41d5ddc1 100644 --- a/src/main/webapp/WEB-INF/view/admin/dataConfig/confirm.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dataconfig/confirm.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.data_crawling_configuration" /> +Fess | <la:message key="labels.data_crawling_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,15 +42,15 @@
    <%-- Form --%> - - + + - - + + - - - + + +
    @@ -58,71 +58,71 @@

    - + - + - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%> - + - - + + - + - - + + - - + + - - + + - + - + - - + @@ -169,37 +169,37 @@ <%-- Box Footer --%> - + diff --git a/src/main/webapp/WEB-INF/view/admin/dataconfig/edit.jsp b/src/main/webapp/WEB-INF/view/admin/dataconfig/edit.jsp new file mode 100644 index 000000000..9e96dfa6b --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/dataconfig/edit.jsp @@ -0,0 +1,165 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.data_crawling_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + <%-- Form Fields --%> +
    + + +
    +
    + + + + ${f:h(hn.label)} + + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + + + + ${f:h(rt.name)} + + +
    +
    + + + + ${f:h(l.name)} + + +
    +
    + + + + + + + + + +
    +
    + + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + diff --git a/src/main/webapp/WEB-INF/view/admin/dataConfig/error.jsp b/src/main/webapp/WEB-INF/view/admin/dataconfig/error.jsp similarity index 71% rename from src/main/webapp/WEB-INF/view/admin/dataConfig/error.jsp rename to src/main/webapp/WEB-INF/view/admin/dataconfig/error.jsp index 56af0732d..1fa32a36b 100644 --- a/src/main/webapp/WEB-INF/view/admin/dataConfig/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dataconfig/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.data_crawling_configuration" /> +Fess | <la:message key="labels.data_crawling_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/dataConfig/index.jsp b/src/main/webapp/WEB-INF/view/admin/dataconfig/index.jsp similarity index 63% rename from src/main/webapp/WEB-INF/view/admin/dataConfig/index.jsp rename to src/main/webapp/WEB-INF/view/admin/dataconfig/index.jsp index fdf882dd3..83afa492f 100644 --- a/src/main/webapp/WEB-INF/view/admin/dataConfig/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dataconfig/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.data_crawling_configuration" /> +Fess | <la:message key="labels.data_crawling_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,49 +35,49 @@ <%-- Box Header --%>

    - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    ${f:h(id)}
    ${f:h(name)}${f:h(name)}
    ${f:h(hn.label)}
    - +
    ${f:br(f:h(handlerParameter))}${f:br(f:h(handlerParameter))}
    ${f:br(f:h(handlerScript))}${f:br(f:h(handlerScript))}
    ${f:h(boost)}${f:h(boost)}
    @@ -131,15 +131,15 @@ - + - ${f:h(rt.name)} + ${f:h(rt.name)} - +
    @@ -148,18 +148,18 @@ - + - ${f:h(l.name)} + ${f:h(l.name)} - +
    - - + + +
    - - + + - + @@ -90,31 +90,31 @@ <%-- Box Footer --%>
    ${f:h(data.name)} - + - +
    + + + + + + + + +
    + + + +
    + + + +
    +
    + <%-- Box Footer --%> + + +
    +
    + + <%-- Box Header --%> +
    +

    + +

    +
    + <%-- Box Body --%> +
    + + + + + + + + + + <%-- Error --%> + + + + + + + + +
    + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    + + + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/design/edit.jsp b/src/main/webapp/WEB-INF/view/admin/design/admin_design_edit.jsp similarity index 67% rename from src/main/webapp/WEB-INF/view/admin/design/edit.jsp rename to src/main/webapp/WEB-INF/view/admin/design/admin_design_edit.jsp index 20e999ddb..fc0e9a117 100644 --- a/src/main/webapp/WEB-INF/view/admin/design/edit.jsp +++ b/src/main/webapp/WEB-INF/view/admin/design/admin_design_edit.jsp @@ -2,14 +2,14 @@ -Fess | <bean:message key="labels.design_configuration" /> +Fess | <la:message key="labels.design_configuration" />
    - + @@ -18,7 +18,7 @@ <%-- Content Header --%>

    - +

    @@ -27,34 +27,34 @@
    - -
    -
    - + +
    ${msg}
    +
    +
    - + <%-- Box Header --%>

    - +

    <%-- Box Body --%>

    ${f:h(fileName)}

    - +
    <%-- Box Footer --%> - -
    + +
    diff --git a/src/main/webapp/WEB-INF/view/admin/design/index.jsp b/src/main/webapp/WEB-INF/view/admin/design/index.jsp deleted file mode 100644 index ec24b2d1b..000000000 --- a/src/main/webapp/WEB-INF/view/admin/design/index.jsp +++ /dev/null @@ -1,154 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.design_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    -
    - -
    - -
    -
    -
    - -
    -
    - -
    -
    - - <%-- Box Header --%> -
    -

    - -

    -
    - <%-- Box Body --%> -
    - - - - ${f:h(item)} - - -
    - <%-- Box Footer --%> - -
    -
    -
    - - <%-- Box Header --%> -
    -

    - -

    -
    - <%-- Box Body --%> -
    - - - - - - - - - -
    - - - -
    - - - -
    -
    - <%-- Box Footer --%> - -
    -
    -
    - - <%-- Box Header --%> -
    -

    - -

    -
    - <%-- Box Body --%> -
    - - - - - - - - - - <%-- Applet --%> - - <%-- Error --%> - - - - - - - - -
    - <%-- Box Footer --%> - -
    -
    -
    -
    - -
    -
    - -
    - - - \ No newline at end of file diff --git a/src/main/webapp/WEB-INF/view/admin/dict/error.jsp b/src/main/webapp/WEB-INF/view/admin/dict/error.jsp index 308495be6..a0dab77ac 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_configuration" /> +Fess | <la:message key="labels.dict_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/dict/index.jsp b/src/main/webapp/WEB-INF/view/admin/dict/index.jsp index 9dd6d010a..c0673c3f9 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_configuration" /> +Fess | <la:message key="labels.dict_configuration" /> @@ -18,7 +18,7 @@ <%-- Content Header --%>

    - +

    @@ -30,40 +30,40 @@ <%-- Box Header --%>

    - +

    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - - + + - + diff --git a/src/main/webapp/WEB-INF/view/admin/dict/synonym/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/dict/synonym/confirm.jsp index 2e80bd04c..dac7c4e9e 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/synonym/confirm.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/synonym/confirm.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_synonym_configuration" /> +Fess | <la:message key="labels.dict_synonym_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,8 +42,8 @@
    <%-- Form --%> - - + +
    @@ -51,66 +51,66 @@

    - + - + - + - +

    - - - + + + - - - + + + - + - + - + - + - - - + + + - - - + + +
    @@ -118,12 +118,12 @@
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%> @@ -131,13 +131,13 @@
    - + - - + +
    ${f:h(data.type)}${f:h(data.name)}${f:h(data.name)}
    - + ${f:br(f:h(inputs))}${f:br(f:h(inputs))}
    ${f:br(f:h(outputs))}${f:br(f:h(outputs))}
    @@ -146,37 +146,37 @@ <%-- Box Footer --%>
    - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/dict/synonym/download.jsp b/src/main/webapp/WEB-INF/view/admin/dict/synonym/download.jsp index 36eae9a35..83756c416 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/synonym/download.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/synonym/download.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_synonym_configuration" /> +Fess | <la:message key="labels.dict_synonym_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,33 +35,33 @@ <%-- Box Header --%>

    - +

    - - - + + + - + - - - + + + - - - + + + - - - + + +
    @@ -69,18 +69,18 @@
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Edit Form: BEGIN --%> - +
    - + @@ -88,13 +88,13 @@
    " /> + value="" />
    -
    + <%-- Edit Form: BEGIN --%>
    diff --git a/src/main/webapp/WEB-INF/view/admin/dict/synonym/edit.jsp b/src/main/webapp/WEB-INF/view/admin/dict/synonym/edit.jsp index 6367e02cd..48a2b5082 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/synonym/edit.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/synonym/edit.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_synonym_configuration" /> +Fess | <la:message key="labels.dict_synonym_configuration" /> @@ -17,18 +17,18 @@ <%-- Content Header --%>

    - +

    <%-- Form --%> - - - + + + - +
    @@ -37,60 +37,60 @@

    - + - +

    - - - + + + - - - + + + - + - + - + - + - - - + + + - - - + + +
    @@ -98,43 +98,43 @@
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%>
    - - + +
    - - + +
    <%-- Box Footer --%>
    -
    +
    diff --git a/src/main/webapp/WEB-INF/view/admin/dict/synonym/error.jsp b/src/main/webapp/WEB-INF/view/admin/dict/synonym/error.jsp index 3caaf4a66..98b22186e 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/synonym/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/synonym/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_synonym_configuration" /> +Fess | <la:message key="labels.dict_synonym_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    @@ -48,22 +48,22 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - - - - - +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + + + + +
    - +
    - +
    -
    -
    + + diff --git a/src/main/webapp/WEB-INF/view/admin/dict/synonym/index.jsp b/src/main/webapp/WEB-INF/view/admin/dict/synonym/index.jsp index f5c08cc29..9e46ff591 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/synonym/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/synonym/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_synonym_configuration" /> +Fess | <la:message key="labels.dict_synonym_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,33 +35,33 @@ <%-- Box Header --%>

    - +

    - - - + + + - + - - - + + + - - - + + + - - - + + +
    @@ -69,30 +69,30 @@
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - - + + - + @@ -104,31 +104,31 @@ <%-- Box Footer --%>
    ${f:h(data.inputs)} ${f:h(data.outputs)}
    @@ -88,7 +88,7 @@
    - + @@ -99,13 +99,13 @@
    " /> + value="" />
    - + <%-- Edit Form: BEGIN --%>
    diff --git a/src/main/webapp/WEB-INF/view/admin/dict/userDict/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/dict/userdict/confirm.jsp similarity index 51% rename from src/main/webapp/WEB-INF/view/admin/dict/userDict/confirm.jsp rename to src/main/webapp/WEB-INF/view/admin/dict/userdict/confirm.jsp index f69b09a9d..dc9bb2221 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/userDict/confirm.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/userdict/confirm.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_userdict_configuration" /> +Fess | <la:message key="labels.dict_userdict_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,8 +42,8 @@
    <%-- Form --%> - - + +
    @@ -51,66 +51,66 @@

    - + - + - + - +

    - - - + + + - - - + + + - + - + - + - + - - - + + + - - - + + +
    @@ -118,33 +118,33 @@
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%> - - + - - + + - - + + - - + +
    ${f:h(token)}${f:h(token)}
    ${f:h(segmentation)}${f:h(segmentation)}
    ${f:h(reading)}${f:h(reading)}
    ${f:h(pos)}${f:h(pos)}
    @@ -153,37 +153,37 @@ <%-- Box Footer --%>
    - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/dict/userDict/download.jsp b/src/main/webapp/WEB-INF/view/admin/dict/userdict/download.jsp similarity index 63% rename from src/main/webapp/WEB-INF/view/admin/dict/userDict/download.jsp rename to src/main/webapp/WEB-INF/view/admin/dict/userdict/download.jsp index f9b24bd4f..5c1ae31e9 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/userDict/download.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/userdict/download.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_userdict_configuration" /> +Fess | <la:message key="labels.dict_userdict_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,33 +35,33 @@ <%-- Box Header --%>

    - +

    - - - + + + - + - - - + + + - - - + + + - - - + + +
    @@ -69,18 +69,18 @@
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Edit Form: BEGIN --%> - +
    - + @@ -88,13 +88,13 @@
    " /> + value="" />
    -
    + <%-- Edit Form: BEGIN --%>
    diff --git a/src/main/webapp/WEB-INF/view/admin/dict/userDict/edit.jsp b/src/main/webapp/WEB-INF/view/admin/dict/userdict/edit.jsp similarity index 55% rename from src/main/webapp/WEB-INF/view/admin/dict/userDict/edit.jsp rename to src/main/webapp/WEB-INF/view/admin/dict/userdict/edit.jsp index 17cbb1f9d..610c31a08 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/userDict/edit.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/userdict/edit.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_userdict_configuration" /> +Fess | <la:message key="labels.dict_userdict_configuration" /> @@ -17,18 +17,18 @@ <%-- Content Header --%>

    - +

    <%-- Form --%> - - - + + + - +
    @@ -37,60 +37,60 @@

    - + - +

    - - - + + + - - - + + + - + - + - + - + - - - + + + - - - + + +
    @@ -98,51 +98,51 @@
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%>
    - - + +
    - - + +
    - - + +
    - - + +
    <%-- Box Footer --%>
    -
    +
    diff --git a/src/main/webapp/WEB-INF/view/admin/dict/userDict/error.jsp b/src/main/webapp/WEB-INF/view/admin/dict/userdict/error.jsp similarity index 51% rename from src/main/webapp/WEB-INF/view/admin/dict/userDict/error.jsp rename to src/main/webapp/WEB-INF/view/admin/dict/userdict/error.jsp index 600f1e635..586332c4a 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/userDict/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/userdict/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_userdict_configuration" /> +Fess | <la:message key="labels.dict_userdict_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    @@ -48,22 +48,22 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - - - - - +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + + + + +
    - +
    - +
    -
    -
    + + diff --git a/src/main/webapp/WEB-INF/view/admin/dict/userDict/index.jsp b/src/main/webapp/WEB-INF/view/admin/dict/userdict/index.jsp similarity index 62% rename from src/main/webapp/WEB-INF/view/admin/dict/userDict/index.jsp rename to src/main/webapp/WEB-INF/view/admin/dict/userdict/index.jsp index 74af46a65..43770b2ef 100644 --- a/src/main/webapp/WEB-INF/view/admin/dict/userDict/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/dict/userdict/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.dict_userdict_configuration" /> +Fess | <la:message key="labels.dict_userdict_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,33 +35,33 @@ <%-- Box Header --%>

    - +

    - - - + + + - + - - - + + + - - - + + + - - - + + +
    @@ -69,17 +69,17 @@
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    @@ -87,17 +87,17 @@ - - - + ${f:h(data.token)} ${f:h(data.reading)} @@ -109,31 +109,31 @@ <%-- Box Footer --%> diff --git a/src/main/webapp/WEB-INF/view/admin/failureUrl/error.jsp b/src/main/webapp/WEB-INF/view/admin/failureurl/error.jsp similarity index 71% rename from src/main/webapp/WEB-INF/view/admin/failureUrl/error.jsp rename to src/main/webapp/WEB-INF/view/admin/failureurl/error.jsp index 87c69c1cd..d7188499a 100644 --- a/src/main/webapp/WEB-INF/view/admin/failureUrl/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/failureurl/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.failure_url_configuration" /> +Fess | <la:message key="labels.failure_url_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/failureUrl/index.jsp b/src/main/webapp/WEB-INF/view/admin/failureurl/index.jsp similarity index 58% rename from src/main/webapp/WEB-INF/view/admin/failureUrl/index.jsp rename to src/main/webapp/WEB-INF/view/admin/failureurl/index.jsp index 147e9e1b5..adcb8cc10 100644 --- a/src/main/webapp/WEB-INF/view/admin/failureUrl/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/failureurl/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.failure_url_configuration" /> +Fess | <la:message key="labels.failure_url_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,62 +35,62 @@ <%-- Box Header --%>

    - +

    - + - - + + - - + styleClass="mini"> - - + +
    - -
    " /> " /> " /> + value="" />
    -
    +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - - + + @@ -99,12 +99,12 @@ @@ -119,7 +119,7 @@ - - - + + <%-- Paging Info --%> - <%-- Paging Navigation --%>
      - + - + -
    • class="active">${p} +
    • class="active">${p}
    • - + - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/fileAuthentication/edit.jsp b/src/main/webapp/WEB-INF/view/admin/fileAuthentication/edit.jsp deleted file mode 100644 index dc1dd5d00..000000000 --- a/src/main/webapp/WEB-INF/view/admin/fileAuthentication/edit.jsp +++ /dev/null @@ -1,151 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.file_authentication_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - -

    -
    - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - - <%-- Form Fields --%> -
    - - -
    -
    - - -
    -
    - - - - ${f:h(item.label)} - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - - - ${f:h(item.label)} - - -
    -
    - - <%-- Box Footer --%> - -
    -
    -
    -
    - -
    -
    - - -
    - - - diff --git a/src/main/webapp/WEB-INF/view/admin/fileConfig/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/fileConfig/confirm.jsp deleted file mode 100644 index 726ee4d33..000000000 --- a/src/main/webapp/WEB-INF/view/admin/fileConfig/confirm.jsp +++ /dev/null @@ -1,233 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.file_crawling_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - - - - - - - -

    -
    - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - - <%-- Form Fields --%> -
    ${f:h(data.url)}
    ${f:h(data.lastAccessTimeForList)} - - - - - - + + + + + +
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    ${f:h(id)}
    ${f:h(name)}
    ${f:br(f:h(paths))}
    ${f:br(f:h(includedPaths))}
    ${f:br(f:h(excludedPaths))}
    ${f:br(f:h(includedDocPaths))}
    ${f:br(f:h(excludedDocPaths))}
    ${f:br(f:h(configParameter))}
    ${f:h(depth)}
    ${f:h(maxAccessCount)}
    ${f:h(numOfThread)}
    ${f:h(intervalTime)}
    ${f:h(boost)}
    - - - - ${f:h(rt.name)}
    -
    -
    -
    - - - ${f:h(rt.name)} - - -
    - - - - ${f:h(l.name)}
    -
    -
    -
    - - - ${f:h(l.name)} - - -
    - - -
    -
    - - <%-- Box Footer --%> - -
    -
    -
    - - - - - - - - - - diff --git a/src/main/webapp/WEB-INF/view/admin/fileConfig/edit.jsp b/src/main/webapp/WEB-INF/view/admin/fileConfig/edit.jsp deleted file mode 100644 index 6366777bf..000000000 --- a/src/main/webapp/WEB-INF/view/admin/fileConfig/edit.jsp +++ /dev/null @@ -1,195 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.file_crawling_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - -

    -
    - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - - <%-- Form Fields --%> - - <%-- Form Fields --%> -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - -
    - - -
    -
    -
    - - -
    -
    - - - - ${f:h(rt.name)} - - -
    -
    - - - - ${f:h(l.name)} - - -
    -
    - - - - - - - - - -
    -
    - - <%-- Box Footer --%> - -
    -
    -
    -
    - -
    -
    - - -
    - - - diff --git a/src/main/webapp/WEB-INF/view/admin/fileAuthentication/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/fileauthentication/confirm.jsp similarity index 50% rename from src/main/webapp/WEB-INF/view/admin/fileAuthentication/confirm.jsp rename to src/main/webapp/WEB-INF/view/admin/fileauthentication/confirm.jsp index b99b269a3..a4cf9d04d 100644 --- a/src/main/webapp/WEB-INF/view/admin/fileAuthentication/confirm.jsp +++ b/src/main/webapp/WEB-INF/view/admin/fileauthentication/confirm.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.file_authentication_configuration" /> +Fess | <la:message key="labels.file_authentication_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,14 +42,14 @@
    <%-- Form --%> - - + + - - + + - - + +
    @@ -57,71 +57,71 @@

    - + - + - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%> - - + + - - + + - + + - - + + - + + - - + + - + +
    ${f:h(hostname)}${f:h(hostname)}
    ${f:h(port)}${f:h(port)}
    ${f:h(item.label)} -
    ${f:h(username)}${f:h(username)}
    ****** -
    ${f:br(f:h(parameters))}${f:br(f:h(parameters))}
    ${f:h(item.label)} -
    @@ -130,37 +130,37 @@ <%-- Box Footer --%>
    - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/fileauthentication/edit.jsp b/src/main/webapp/WEB-INF/view/admin/fileauthentication/edit.jsp new file mode 100644 index 000000000..ffa43a2dc --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/fileauthentication/edit.jsp @@ -0,0 +1,151 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.file_authentication_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> +
    + + +
    +
    + + +
    +
    + + + + ${f:h(item.label)} + + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + + + + ${f:h(item.label)} + + +
    +
    + + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + diff --git a/src/main/webapp/WEB-INF/view/admin/fileAuthentication/error.jsp b/src/main/webapp/WEB-INF/view/admin/fileauthentication/error.jsp similarity index 70% rename from src/main/webapp/WEB-INF/view/admin/fileAuthentication/error.jsp rename to src/main/webapp/WEB-INF/view/admin/fileauthentication/error.jsp index 58cf19f69..0afa6f5d7 100644 --- a/src/main/webapp/WEB-INF/view/admin/fileAuthentication/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/fileauthentication/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.file_authentication_configuration" /> +Fess | <la:message key="labels.file_authentication_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/fileAuthentication/index.jsp b/src/main/webapp/WEB-INF/view/admin/fileauthentication/index.jsp similarity index 61% rename from src/main/webapp/WEB-INF/view/admin/fileAuthentication/index.jsp rename to src/main/webapp/WEB-INF/view/admin/fileauthentication/index.jsp index bb03f3b14..e2b13748a 100644 --- a/src/main/webapp/WEB-INF/view/admin/fileAuthentication/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/fileauthentication/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.file_authentication_configuration" /> +Fess | <la:message key="labels.file_authentication_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -32,58 +32,58 @@
    - - - + + +
    <%-- Box Header --%>

    - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - - + + - +
    - + ${f:h(data.hostname)}: - + ${f:h(data.port)} @@ -99,31 +99,31 @@ <%-- Box Footer --%> + + + + + + + + + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/group/edit.jsp b/src/main/webapp/WEB-INF/view/admin/group/edit.jsp new file mode 100644 index 000000000..38494efe7 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/group/edit.jsp @@ -0,0 +1,117 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.group_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> +
    + + +
    + +
    + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/group/error.jsp b/src/main/webapp/WEB-INF/view/admin/group/error.jsp new file mode 100644 index 000000000..6523b4bbd --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/group/error.jsp @@ -0,0 +1,50 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.group_configuration" /> + + + +
    + + + + + + +
    +
    +

    + +

    + +
    + +
    + +
    +

    Error

    +

    + +

    +

    + + + +

    +
    + +
    +
    + + + +
    + + + diff --git a/src/main/webapp/WEB-INF/view/admin/group/index.jsp b/src/main/webapp/WEB-INF/view/admin/group/index.jsp new file mode 100644 index 000000000..cf9bd75f8 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/group/index.jsp @@ -0,0 +1,126 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.group_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + +
    +
    +
    + <%-- Box Header --%> +
    +

    + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- List --%> + +

    + +

    +
    + + + + + + + + + + + + + + +
    ${f:h(data.name)}
    +
    + +
    + <%-- Box Footer --%> + +
    +
    +
    + +
    +
    + + +
    + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/jobLog/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/jobLog/confirm.jsp deleted file mode 100644 index c95f4d314..000000000 --- a/src/main/webapp/WEB-INF/view/admin/jobLog/confirm.jsp +++ /dev/null @@ -1,153 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.joblog_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - - - - - - - -

    -
    - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - - <%-- Form Fields --%> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    ${f:h(jobName)}
    ${f:h(jobStatus)}
    ${f:h(target)}
    ${f:h(startTime)}
    ${f:h(endTime)}
    ${f:h(scriptType)}
    ${f:br(f:h(scriptData))}
    ${f:br(f:h(scriptResult))}
    - -
    - <%-- Box Footer --%> - -
    -
    -
    -
    - -
    -
    - - -
    - - - - diff --git a/src/main/webapp/WEB-INF/view/admin/joblog/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/joblog/confirm.jsp new file mode 100644 index 000000000..7c7a557db --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/joblog/confirm.jsp @@ -0,0 +1,150 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.joblog_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    ${f:h(jobName)}
    ${f:h(jobStatus)}
    ${f:h(target)}
    ${f:h(startTime)}
    ${f:h(endTime)}
    ${f:h(scriptType)}
    ${f:br(f:h(scriptData))}
    ${f:br(f:h(scriptResult))}
    + +
    + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/jobLog/error.jsp b/src/main/webapp/WEB-INF/view/admin/joblog/error.jsp similarity index 68% rename from src/main/webapp/WEB-INF/view/admin/jobLog/error.jsp rename to src/main/webapp/WEB-INF/view/admin/joblog/error.jsp index 9f9ed8a2f..5c7c04371 100644 --- a/src/main/webapp/WEB-INF/view/admin/jobLog/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/joblog/error.jsp @@ -2,26 +2,26 @@ -Fess | <bean:message key="labels.joblog_configuration" /> +Fess | <la:message key="labels.joblog_configuration" />
    - +

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/jobLog/index.jsp b/src/main/webapp/WEB-INF/view/admin/joblog/index.jsp similarity index 56% rename from src/main/webapp/WEB-INF/view/admin/jobLog/index.jsp rename to src/main/webapp/WEB-INF/view/admin/joblog/index.jsp index 2f3d71c7c..90caba46c 100644 --- a/src/main/webapp/WEB-INF/view/admin/jobLog/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/joblog/index.jsp @@ -2,14 +2,14 @@ -Fess | <bean:message key="labels.joblog_configuration" /> +Fess | <la:message key="labels.joblog_configuration" />
    - + @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,54 +35,54 @@ <%-- Box Header --%>

    - +

    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - - - - + + + + - + - + - @@ -94,31 +94,31 @@ <%-- Box Footer --%>
    ${f:h(data.jobName)} ${f:h(data.jobStatus)} - - + + - - - - - + + + + + + +
    - - + + - - + + - - + + - - + +
    ${f:h(term)}${f:h(term)}
    ${f:h(query)}${f:h(query)}
    ${f:h(maxSize)}${f:h(maxSize)}
    ${f:h(boost)}${f:h(boost)}
    @@ -113,37 +113,37 @@ <%-- Box Footer --%>
    - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/keyMatch/edit.jsp b/src/main/webapp/WEB-INF/view/admin/keymatch/edit.jsp similarity index 51% rename from src/main/webapp/WEB-INF/view/admin/keyMatch/edit.jsp rename to src/main/webapp/WEB-INF/view/admin/keymatch/edit.jsp index ac7885fdb..6f0ebf48d 100644 --- a/src/main/webapp/WEB-INF/view/admin/keyMatch/edit.jsp +++ b/src/main/webapp/WEB-INF/view/admin/keymatch/edit.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.key_match_configuration" /> +Fess | <la:message key="labels.key_match_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,14 +42,14 @@
    <%-- Form --%> - - + + - - + + - - + +
    @@ -57,68 +57,68 @@

    - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%>
    - - + +
    - - + +
    - - + +
    - - + +
    <%-- Box Footer --%>
    -
    +
    diff --git a/src/main/webapp/WEB-INF/view/admin/keyMatch/error.jsp b/src/main/webapp/WEB-INF/view/admin/keymatch/error.jsp similarity index 72% rename from src/main/webapp/WEB-INF/view/admin/keyMatch/error.jsp rename to src/main/webapp/WEB-INF/view/admin/keymatch/error.jsp index 74c94987d..a0a56ae07 100644 --- a/src/main/webapp/WEB-INF/view/admin/keyMatch/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/keymatch/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.key_match_configuration" /> +Fess | <la:message key="labels.key_match_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/keyMatch/index.jsp b/src/main/webapp/WEB-INF/view/admin/keymatch/index.jsp similarity index 63% rename from src/main/webapp/WEB-INF/view/admin/keyMatch/index.jsp rename to src/main/webapp/WEB-INF/view/admin/keymatch/index.jsp index 16929160f..230c0fcb5 100644 --- a/src/main/webapp/WEB-INF/view/admin/keyMatch/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/keymatch/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.key_match_configuration" /> +Fess | <la:message key="labels.key_match_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,43 +35,43 @@ <%-- Box Header --%>

    - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - - + + - + @@ -84,31 +84,31 @@ <%-- Box Footer --%>
    ${f:h(data.term)} ${f:h(data.query)}
    - - + + - - + + - - + + - - + + - + - - + +
    ${f:h(name)}${f:h(name)}
    ${f:h(value)}${f:h(value)}
    ${f:br(f:h(includedPaths))}${f:br(f:h(includedPaths))}
    ${f:br(f:h(excludedPaths))}${f:br(f:h(excludedPaths))}
    @@ -116,16 +116,16 @@ - + - ${f:h(rt.name)} + ${f:h(rt.name)} - +
    ${f:h(sortOrder)}${f:h(sortOrder)}
    @@ -134,37 +134,37 @@ <%-- Box Footer --%>
    - + diff --git a/src/main/webapp/WEB-INF/view/admin/labeltype/edit.jsp b/src/main/webapp/WEB-INF/view/admin/labeltype/edit.jsp new file mode 100644 index 000000000..53be452c7 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/labeltype/edit.jsp @@ -0,0 +1,142 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.labeltype_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> +
    + + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + + + + ${f:h(rt.name)} + + +
    +
    + + +
    +
    + + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + diff --git a/src/main/webapp/WEB-INF/view/admin/labelType/error.jsp b/src/main/webapp/WEB-INF/view/admin/labeltype/error.jsp similarity index 72% rename from src/main/webapp/WEB-INF/view/admin/labelType/error.jsp rename to src/main/webapp/WEB-INF/view/admin/labeltype/error.jsp index 0749a1d8e..f1aa4193b 100644 --- a/src/main/webapp/WEB-INF/view/admin/labelType/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/labeltype/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.labeltype_configuration" /> +Fess | <la:message key="labels.labeltype_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/labelType/index.jsp b/src/main/webapp/WEB-INF/view/admin/labeltype/index.jsp similarity index 64% rename from src/main/webapp/WEB-INF/view/admin/labelType/index.jsp rename to src/main/webapp/WEB-INF/view/admin/labeltype/index.jsp index d4ee1321e..b2c701f29 100644 --- a/src/main/webapp/WEB-INF/view/admin/labelType/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/labeltype/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.labeltype_configuration" /> +Fess | <la:message key="labels.labeltype_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,42 +35,42 @@ <%-- Box Header --%>

    - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - + - + @@ -82,31 +82,31 @@ <%-- Box Footer --%>
    ${f:h(data.name)}
    - - + + - diff --git a/src/main/webapp/WEB-INF/view/admin/overlappingHost/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/overlappinghost/confirm.jsp similarity index 53% rename from src/main/webapp/WEB-INF/view/admin/overlappingHost/confirm.jsp rename to src/main/webapp/WEB-INF/view/admin/overlappinghost/confirm.jsp index 844fa080e..96a06d6d7 100644 --- a/src/main/webapp/WEB-INF/view/admin/overlappingHost/confirm.jsp +++ b/src/main/webapp/WEB-INF/view/admin/overlappinghost/confirm.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.overlapping_host_configuration" /> +Fess | <la:message key="labels.overlapping_host_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,15 +42,15 @@
    <%-- Form --%> - - + + - - + + - - - + + +
    @@ -58,46 +58,46 @@

    - + - + - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%>
    - ${f:h(logFile.name)} + ${f:h(logFile.name)}
    - - + + - - + +
    ${f:h(regularName)}${f:h(regularName)}
    ${f:h(overlappingName)}${f:h(overlappingName)}
    @@ -106,37 +106,37 @@ <%-- Box Footer --%>
    - + diff --git a/src/main/webapp/WEB-INF/view/admin/overlappingHost/edit.jsp b/src/main/webapp/WEB-INF/view/admin/overlappinghost/edit.jsp similarity index 52% rename from src/main/webapp/WEB-INF/view/admin/overlappingHost/edit.jsp rename to src/main/webapp/WEB-INF/view/admin/overlappinghost/edit.jsp index bfae56ad6..f6748f547 100644 --- a/src/main/webapp/WEB-INF/view/admin/overlappingHost/edit.jsp +++ b/src/main/webapp/WEB-INF/view/admin/overlappinghost/edit.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.overlapping_host_configuration" /> +Fess | <la:message key="labels.overlapping_host_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,15 +42,15 @@
    <%-- Form --%> - - + + - - + + - - - + + +
    @@ -58,59 +58,59 @@

    - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%>
    - - + +
    - - + +
    <%-- Box Footer --%>
    - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/overlappingHost/error.jsp b/src/main/webapp/WEB-INF/view/admin/overlappinghost/error.jsp similarity index 70% rename from src/main/webapp/WEB-INF/view/admin/overlappingHost/error.jsp rename to src/main/webapp/WEB-INF/view/admin/overlappinghost/error.jsp index 82494e00e..8e2d5cd39 100644 --- a/src/main/webapp/WEB-INF/view/admin/overlappingHost/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/overlappinghost/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.overlapping_host_configuration" /> +Fess | <la:message key="labels.overlapping_host_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/overlappingHost/index.jsp b/src/main/webapp/WEB-INF/view/admin/overlappinghost/index.jsp similarity index 63% rename from src/main/webapp/WEB-INF/view/admin/overlappingHost/index.jsp rename to src/main/webapp/WEB-INF/view/admin/overlappinghost/index.jsp index 962c12ffb..0f9dec72b 100644 --- a/src/main/webapp/WEB-INF/view/admin/overlappingHost/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/overlappinghost/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.overlapping_host_configuration" /> +Fess | <la:message key="labels.overlapping_host_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,43 +35,43 @@ <%-- Box Header --%>

    - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - - + + - + @@ -84,31 +84,31 @@ <%-- Box Footer --%>
    ${f:h(data.regularName)} ${f:h(data.overlappingName)}
    - - + + - - + + - + - - + +
    ${f:h(regex)}${f:h(regex)}
    ${f:h(replacement)}${f:h(replacement)}
    - + - + - + - +
    ${f:h(sortOrder)}${f:h(sortOrder)}
    @@ -122,37 +122,37 @@ <%-- Box Footer --%>
    - + diff --git a/src/main/webapp/WEB-INF/view/admin/pathmapping/edit.jsp b/src/main/webapp/WEB-INF/view/admin/pathmapping/edit.jsp new file mode 100644 index 000000000..dd0885adc --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/pathmapping/edit.jsp @@ -0,0 +1,136 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.path_mapping_configuration" /> + + + +
    + + + + + + +
    + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + <%-- Form --%> + + + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + <%-- Form Fields --%> +
    + + +
    +
    + + +
    +
    + + + + + + + + + + + + +
    +
    + + +
    +
    + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + +
    + + + diff --git a/src/main/webapp/WEB-INF/view/admin/pathMapping/error.jsp b/src/main/webapp/WEB-INF/view/admin/pathmapping/error.jsp similarity index 71% rename from src/main/webapp/WEB-INF/view/admin/pathMapping/error.jsp rename to src/main/webapp/WEB-INF/view/admin/pathmapping/error.jsp index e52f3371c..1dbf294c6 100644 --- a/src/main/webapp/WEB-INF/view/admin/pathMapping/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/pathmapping/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.path_mapping_configuration" /> +Fess | <la:message key="labels.path_mapping_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -29,12 +29,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/pathMapping/index.jsp b/src/main/webapp/WEB-INF/view/admin/pathmapping/index.jsp similarity index 63% rename from src/main/webapp/WEB-INF/view/admin/pathMapping/index.jsp rename to src/main/webapp/WEB-INF/view/admin/pathmapping/index.jsp index ed87ef032..d56d82acb 100644 --- a/src/main/webapp/WEB-INF/view/admin/pathMapping/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/pathmapping/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.path_mapping_configuration" /> +Fess | <la:message key="labels.path_mapping_configuration" /> @@ -17,12 +17,12 @@ <%-- Content Header --%>

    - +

    @@ -33,42 +33,42 @@ <%-- Box Header --%>

    - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - - + + - + @@ -80,31 +80,31 @@ <%-- Box Footer --%> diff --git a/src/main/webapp/WEB-INF/view/admin/requestHeader/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/requestheader/confirm.jsp similarity index 54% rename from src/main/webapp/WEB-INF/view/admin/requestHeader/confirm.jsp rename to src/main/webapp/WEB-INF/view/admin/requestheader/confirm.jsp index d11b3c6d4..b7e2d56b1 100644 --- a/src/main/webapp/WEB-INF/view/admin/requestHeader/confirm.jsp +++ b/src/main/webapp/WEB-INF/view/admin/requestheader/confirm.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.request_header_configuration" /> +Fess | <la:message key="labels.request_header_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,14 +42,14 @@
    <%-- Form --%> - - + + - - + + - - + +
    @@ -57,52 +57,52 @@

    - + - + - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%>
    ${f:h(data.regex)} ${f:h(data.replacement)}
    - - + + - - + + - + +
    ${f:h(name)}${f:h(name)}
    ${f:h(value)}${f:h(value)}
    ${f:h(item.label)} -
    @@ -111,37 +111,37 @@ <%-- Box Footer --%>
    - + diff --git a/src/main/webapp/WEB-INF/view/admin/requestHeader/edit.jsp b/src/main/webapp/WEB-INF/view/admin/requestheader/edit.jsp similarity index 51% rename from src/main/webapp/WEB-INF/view/admin/requestHeader/edit.jsp rename to src/main/webapp/WEB-INF/view/admin/requestheader/edit.jsp index b09e90174..b20e02fdf 100644 --- a/src/main/webapp/WEB-INF/view/admin/requestHeader/edit.jsp +++ b/src/main/webapp/WEB-INF/view/admin/requestheader/edit.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.request_header_configuration" /> +Fess | <la:message key="labels.request_header_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,14 +42,14 @@
    <%-- Form --%> - - + + - - + + - - + +
    @@ -58,68 +58,68 @@

    - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%>
    - - + +
    - - + +
    - - + + - ${f:h(item.label)} + ${f:h(item.label)} - +
    <%-- Box Footer --%>
    -
    +
    diff --git a/src/main/webapp/WEB-INF/view/admin/requestHeader/error.jsp b/src/main/webapp/WEB-INF/view/admin/requestheader/error.jsp similarity index 71% rename from src/main/webapp/WEB-INF/view/admin/requestHeader/error.jsp rename to src/main/webapp/WEB-INF/view/admin/requestheader/error.jsp index 26d64f7bb..0bd6beec9 100644 --- a/src/main/webapp/WEB-INF/view/admin/requestHeader/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/requestheader/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.request_header_configuration" /> +Fess | <la:message key="labels.request_header_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/requestHeader/index.jsp b/src/main/webapp/WEB-INF/view/admin/requestheader/index.jsp similarity index 62% rename from src/main/webapp/WEB-INF/view/admin/requestHeader/index.jsp rename to src/main/webapp/WEB-INF/view/admin/requestheader/index.jsp index 03a1d2838..a520cf1af 100644 --- a/src/main/webapp/WEB-INF/view/admin/requestHeader/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/requestheader/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.request_header_configuration" /> +Fess | <la:message key="labels.request_header_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -32,52 +32,52 @@
    - - - + + +
    <%-- Box Header --%>

    - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - - + + - + @@ -90,31 +90,31 @@ <%-- Box Footer --%>
    ${f:h(data.name)} ${f:h(data.webConfig.name)}
    + + + + + + +
    ${f:h(name)}
    + +
    + <%-- Box Footer --%> + +
    +
    +
    + + + +
    + + + + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/role/edit.jsp b/src/main/webapp/WEB-INF/view/admin/role/edit.jsp new file mode 100644 index 000000000..5f325561d --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/role/edit.jsp @@ -0,0 +1,117 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.role_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> +
    + + +
    + +
    + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/role/error.jsp b/src/main/webapp/WEB-INF/view/admin/role/error.jsp new file mode 100644 index 000000000..71ca8c9c8 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/role/error.jsp @@ -0,0 +1,50 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.role_configuration" /> + + + +
    + + + + + + +
    +
    +

    + +

    + +
    + +
    + +
    +

    Error

    +

    + +

    +

    + + + +

    +
    + +
    +
    + + + +
    + + + diff --git a/src/main/webapp/WEB-INF/view/admin/role/index.jsp b/src/main/webapp/WEB-INF/view/admin/role/index.jsp new file mode 100644 index 000000000..e2f833358 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/role/index.jsp @@ -0,0 +1,126 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.role_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + +
    +
    +
    + <%-- Box Header --%> +
    +

    + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- List --%> + +

    + +

    +
    + + + + + + + + + + + + + + +
    ${f:h(data.name)}
    +
    + +
    + <%-- Box Footer --%> + +
    +
    +
    + +
    +
    + + +
    + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/roleType/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/roletype/confirm.jsp similarity index 55% rename from src/main/webapp/WEB-INF/view/admin/roleType/confirm.jsp rename to src/main/webapp/WEB-INF/view/admin/roletype/confirm.jsp index 6c27cd6be..4d7300f8f 100644 --- a/src/main/webapp/WEB-INF/view/admin/roleType/confirm.jsp +++ b/src/main/webapp/WEB-INF/view/admin/roletype/confirm.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.roletype_configuration" /> +Fess | <la:message key="labels.roletype_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,15 +42,15 @@
    <%-- Form --%> - - + + - - + + - - - + + +
    @@ -58,46 +58,46 @@

    - + - + - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%> - - + + - - + +
    ${f:h(name)}${f:h(name)}
    ${f:h(value)}${f:h(value)}
    @@ -106,37 +106,37 @@ <%-- Box Footer --%>
    - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/roleType/edit.jsp b/src/main/webapp/WEB-INF/view/admin/roletype/edit.jsp similarity index 53% rename from src/main/webapp/WEB-INF/view/admin/roleType/edit.jsp rename to src/main/webapp/WEB-INF/view/admin/roletype/edit.jsp index 8b9702b49..61ad163dc 100644 --- a/src/main/webapp/WEB-INF/view/admin/roleType/edit.jsp +++ b/src/main/webapp/WEB-INF/view/admin/roletype/edit.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.roletype_configuration" /> +Fess | <la:message key="labels.roletype_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,15 +42,15 @@
    <%-- Form --%> - - + + - - + + - - - + + +
    @@ -58,59 +58,59 @@

    - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%>
    - - + +
    - - + +
    <%-- Box Footer --%>
    - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/roleType/error.jsp b/src/main/webapp/WEB-INF/view/admin/roletype/error.jsp similarity index 72% rename from src/main/webapp/WEB-INF/view/admin/roleType/error.jsp rename to src/main/webapp/WEB-INF/view/admin/roletype/error.jsp index dfc96d77e..b905e289d 100644 --- a/src/main/webapp/WEB-INF/view/admin/roleType/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/roletype/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.roletype_configuration" /> +Fess | <la:message key="labels.roletype_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/roleType/index.jsp b/src/main/webapp/WEB-INF/view/admin/roletype/index.jsp similarity index 64% rename from src/main/webapp/WEB-INF/view/admin/roleType/index.jsp rename to src/main/webapp/WEB-INF/view/admin/roletype/index.jsp index c9d05da12..b2e4e3cd1 100644 --- a/src/main/webapp/WEB-INF/view/admin/roleType/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/roletype/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.roletype_configuration" /> +Fess | <la:message key="labels.roletype_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,42 +35,42 @@ <%-- Box Header --%>

    - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - + - + @@ -82,31 +82,31 @@ <%-- Box Footer --%>
    ${f:h(data.name)}
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    ${f:h(name)}
    ${f:h(target)}
    ${f:h(cronExpression)}
    ${f:h(scriptType)}
    ${f:br(f:h(scriptData))}
    - - - -
    - - - -
    - - - -
    ${f:h(sortOrder)}
    - -
    - <%-- Box Footer --%> - -
    - - - - - - - - - - - - diff --git a/src/main/webapp/WEB-INF/view/admin/scheduledJob/edit.jsp b/src/main/webapp/WEB-INF/view/admin/scheduledJob/edit.jsp deleted file mode 100644 index f3916fb61..000000000 --- a/src/main/webapp/WEB-INF/view/admin/scheduledJob/edit.jsp +++ /dev/null @@ -1,160 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.scheduledjob_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - -

    -
    - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - - <%-- Form Fields --%> -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - -
    - - -
    -
    -
    - -
    - - -
    -
    -
    - -
    - - -
    -
    -
    - - -
    -
    - -
    - <%-- Box Footer --%> - -
    -
    -
    - - - -
    - - - - - - diff --git a/src/main/webapp/WEB-INF/view/admin/scheduledjob/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/scheduledjob/confirm.jsp new file mode 100644 index 000000000..734c53b48 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/scheduledjob/confirm.jsp @@ -0,0 +1,197 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.scheduledjob_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    ${f:h(name)}
    ${f:h(target)}
    ${f:h(cronExpression)}
    ${f:h(scriptType)}
    ${f:br(f:h(scriptData))}
    + + + +
    + + + +
    + + + +
    ${f:h(sortOrder)}
    + +
    + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + diff --git a/src/main/webapp/WEB-INF/view/admin/scheduledjob/edit.jsp b/src/main/webapp/WEB-INF/view/admin/scheduledjob/edit.jsp new file mode 100644 index 000000000..d66ceab53 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/scheduledjob/edit.jsp @@ -0,0 +1,160 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.scheduledjob_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> +
    + + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + +
    + + +
    +
    +
    + +
    + + +
    +
    +
    + +
    + + +
    +
    +
    + + +
    +
    + +
    + <%-- Box Footer --%> + +
    +
    +
    + + + +
    + + + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/scheduledJob/error.jsp b/src/main/webapp/WEB-INF/view/admin/scheduledjob/error.jsp similarity index 67% rename from src/main/webapp/WEB-INF/view/admin/scheduledJob/error.jsp rename to src/main/webapp/WEB-INF/view/admin/scheduledjob/error.jsp index 64cfc9b81..3be75edc3 100644 --- a/src/main/webapp/WEB-INF/view/admin/scheduledJob/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/scheduledjob/error.jsp @@ -2,26 +2,26 @@ -Fess | <bean:message key="labels.scheduledjob_configuration" /> +Fess | <la:message key="labels.scheduledjob_configuration" />
    - +

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/scheduledJob/index.jsp b/src/main/webapp/WEB-INF/view/admin/scheduledjob/index.jsp similarity index 60% rename from src/main/webapp/WEB-INF/view/admin/scheduledJob/index.jsp rename to src/main/webapp/WEB-INF/view/admin/scheduledjob/index.jsp index 096d7fa0c..24780f1f1 100644 --- a/src/main/webapp/WEB-INF/view/admin/scheduledJob/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/scheduledjob/index.jsp @@ -2,14 +2,14 @@ -Fess | <bean:message key="labels.scheduledjob_configuration" /> +Fess | <la:message key="labels.scheduledjob_configuration" />
    - + @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,54 +35,54 @@ <%-- Box Header --%>

    - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - - - - + + + + - + @@ -98,31 +98,31 @@ <%-- Box Footer --%>
    ${f:h(data.name)} - + - + - +
    - - + value="" />
    ${f:h(url)}${f:h(url)}
    " /> " /> " />
    - +
    <%-- Box Footer --%>
    - + diff --git a/src/main/webapp/WEB-INF/view/admin/searchList/index.jsp b/src/main/webapp/WEB-INF/view/admin/searchlist/index.jsp similarity index 72% rename from src/main/webapp/WEB-INF/view/admin/searchList/index.jsp rename to src/main/webapp/WEB-INF/view/admin/searchlist/index.jsp index 4d2709273..63a56f647 100644 --- a/src/main/webapp/WEB-INF/view/admin/searchList/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/searchlist/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.search_list_configuration" /> +Fess | <la:message key="labels.search_list_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,25 +35,25 @@ <%-- Box Header --%>

    - +

    - +
    - - " name="search" /> + + " name="search" />
    -
    +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%> @@ -62,24 +62,24 @@

    - +

    - -

    - +
      @@ -91,14 +91,14 @@
      ${doc.contentDescription}
      - - + - - + + - - + +
      @@ -107,38 +107,38 @@
    - +
    - + @@ -175,4 +175,3 @@ - diff --git a/src/main/webapp/WEB-INF/view/admin/suggestBadWord/edit.jsp b/src/main/webapp/WEB-INF/view/admin/suggestBadWord/edit.jsp deleted file mode 100644 index 2df9240f7..000000000 --- a/src/main/webapp/WEB-INF/view/admin/suggestBadWord/edit.jsp +++ /dev/null @@ -1,127 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.suggest_bad_word_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - -

    -
    - - - - - - - - - - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - - <%-- Form Fields --%> -
    - - -
    -
    - <%-- Box Footer --%> - -
    -
    -
    -
    - -
    -
    - - -
    - - - - diff --git a/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/confirm.jsp deleted file mode 100644 index b2b7df643..000000000 --- a/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/confirm.jsp +++ /dev/null @@ -1,160 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.suggest_elevate_word_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - - - - - - - -

    -
    - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - - <%-- Form Fields --%> - - - - - - - - - - - - - - - - - - - - - - - -
    ${f:h(suggestWord)}
    ${f:h(reading)}
    ${f:h(targetRole)}
    ${f:h(targetLabel)}
    ${f:h(boost)}
    - -
    - <%-- Box Footer --%> - -
    -
    -
    -
    - -
    -
    - - -
    - - - - diff --git a/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/edit.jsp b/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/edit.jsp deleted file mode 100644 index e6a834de7..000000000 --- a/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/edit.jsp +++ /dev/null @@ -1,143 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.suggest_elevate_word_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - -

    -
    - - - - - - - - - - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - - <%-- Form Fields --%> -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - <%-- Box Footer --%> - -
    -
    -
    -
    - -
    -
    - - -
    - - - - diff --git a/src/main/webapp/WEB-INF/view/admin/suggestBadWord/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/suggestbadword/confirm.jsp similarity index 54% rename from src/main/webapp/WEB-INF/view/admin/suggestBadWord/confirm.jsp rename to src/main/webapp/WEB-INF/view/admin/suggestbadword/confirm.jsp index 90ec842a1..58235308f 100644 --- a/src/main/webapp/WEB-INF/view/admin/suggestBadWord/confirm.jsp +++ b/src/main/webapp/WEB-INF/view/admin/suggestbadword/confirm.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.suggest_bad_word_configuration" /> +Fess | <la:message key="labels.suggest_bad_word_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,14 +42,14 @@
    <%-- Form --%> - - + + - - + + - - + +
    @@ -57,42 +57,42 @@

    - + - + - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%> - - + +
    ${f:h(suggestWord)}${f:h(suggestWord)}
    @@ -101,37 +101,37 @@ <%-- Box Footer --%>
    - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/suggestBadWord/download.jsp b/src/main/webapp/WEB-INF/view/admin/suggestbadword/download.jsp similarity index 52% rename from src/main/webapp/WEB-INF/view/admin/suggestBadWord/download.jsp rename to src/main/webapp/WEB-INF/view/admin/suggestbadword/download.jsp index 1d52af71f..47b4e2fa9 100644 --- a/src/main/webapp/WEB-INF/view/admin/suggestBadWord/download.jsp +++ b/src/main/webapp/WEB-INF/view/admin/suggestbadword/download.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.suggest_bad_word_configuration" /> +Fess | <la:message key="labels.suggest_bad_word_configuration" /> @@ -18,13 +18,13 @@ <%-- Content Header --%>

    - +

    @@ -36,35 +36,35 @@ <%-- Box Header --%>

    - +

    - - - - - - - - - - - - + + + + + + + + + + + +
    <%-- Box Body --%>
    - + - - + +
    " type="submit" />" type="submit" />
    -
    +
    <%-- Box Footer --%> diff --git a/src/main/webapp/WEB-INF/view/admin/suggestbadword/edit.jsp b/src/main/webapp/WEB-INF/view/admin/suggestbadword/edit.jsp new file mode 100644 index 000000000..08f0b4598 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/suggestbadword/edit.jsp @@ -0,0 +1,127 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.suggest_bad_word_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + +

    +
    + + + + + + + + + + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> +
    + + +
    +
    + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/suggestBadWord/error.jsp b/src/main/webapp/WEB-INF/view/admin/suggestbadword/error.jsp similarity index 70% rename from src/main/webapp/WEB-INF/view/admin/suggestBadWord/error.jsp rename to src/main/webapp/WEB-INF/view/admin/suggestbadword/error.jsp index 2994dafcb..09e4afdd5 100644 --- a/src/main/webapp/WEB-INF/view/admin/suggestBadWord/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/suggestbadword/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.suggest_bad_word_configuration" /> +Fess | <la:message key="labels.suggest_bad_word_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/suggestBadWord/index.jsp b/src/main/webapp/WEB-INF/view/admin/suggestbadword/index.jsp similarity index 58% rename from src/main/webapp/WEB-INF/view/admin/suggestBadWord/index.jsp rename to src/main/webapp/WEB-INF/view/admin/suggestbadword/index.jsp index 92c2e936f..91669a25d 100644 --- a/src/main/webapp/WEB-INF/view/admin/suggestBadWord/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/suggestbadword/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.suggest_bad_word_configuration" /> +Fess | <la:message key="labels.suggest_bad_word_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,51 +35,51 @@ <%-- Box Header --%>

    - +

    - - - - - - - - - - - - + + + + + + + + + + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - + - + @@ -91,31 +91,31 @@ <%-- Box Footer --%>
    ${f:h(data.suggestWord)}
    - +
    - " /> + " />
    - +
    <%-- Box Footer --%> diff --git a/src/main/webapp/WEB-INF/view/admin/suggestelevateword/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/suggestelevateword/confirm.jsp new file mode 100644 index 000000000..5e9e6dfba --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/suggestelevateword/confirm.jsp @@ -0,0 +1,160 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.suggest_elevate_word_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> + + + + + + + + + + + + + + + + + + + + + + + +
    ${f:h(suggestWord)}
    ${f:h(reading)}
    ${f:h(targetRole)}
    ${f:h(targetLabel)}
    ${f:h(boost)}
    + +
    + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/download.jsp b/src/main/webapp/WEB-INF/view/admin/suggestelevateword/download.jsp similarity index 52% rename from src/main/webapp/WEB-INF/view/admin/suggestElevateWord/download.jsp rename to src/main/webapp/WEB-INF/view/admin/suggestelevateword/download.jsp index e52567662..d9a078bdd 100644 --- a/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/download.jsp +++ b/src/main/webapp/WEB-INF/view/admin/suggestelevateword/download.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.suggest_elevate_word_configuration" /> +Fess | <la:message key="labels.suggest_elevate_word_configuration" /> @@ -18,13 +18,13 @@ <%-- Content Header --%>

    - +

    @@ -36,35 +36,35 @@ <%-- Box Header --%>

    - +

    - - - - - - - - - - - - + + + + + + + + + + + +
    <%-- Box Body --%>
    - + - - + +
    " type="submit" />" type="submit" />
    -
    +
    <%-- Box Footer --%> diff --git a/src/main/webapp/WEB-INF/view/admin/suggestelevateword/edit.jsp b/src/main/webapp/WEB-INF/view/admin/suggestelevateword/edit.jsp new file mode 100644 index 000000000..271285fac --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/suggestelevateword/edit.jsp @@ -0,0 +1,143 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.suggest_elevate_word_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + +

    +
    + + + + + + + + + + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> +
    + + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/error.jsp b/src/main/webapp/WEB-INF/view/admin/suggestelevateword/error.jsp similarity index 70% rename from src/main/webapp/WEB-INF/view/admin/suggestElevateWord/error.jsp rename to src/main/webapp/WEB-INF/view/admin/suggestelevateword/error.jsp index b523b8bad..9dae0b7c1 100644 --- a/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/suggestelevateword/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.suggest_elevate_word_configuration" /> +Fess | <la:message key="labels.suggest_elevate_word_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/index.jsp b/src/main/webapp/WEB-INF/view/admin/suggestelevateword/index.jsp similarity index 57% rename from src/main/webapp/WEB-INF/view/admin/suggestElevateWord/index.jsp rename to src/main/webapp/WEB-INF/view/admin/suggestelevateword/index.jsp index afab804b3..929c11650 100644 --- a/src/main/webapp/WEB-INF/view/admin/suggestElevateWord/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/suggestelevateword/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.suggest_elevate_word_configuration" /> +Fess | <la:message key="labels.suggest_elevate_word_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -35,51 +35,51 @@ <%-- Box Header --%>

    - +

    - - - - - - - - - - - - + + + + + + + + + + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - + - + @@ -91,31 +91,31 @@ <%-- Box Footer --%>
    ${f:h(data.suggestWord)}
    - +
    - " /> + " />
    - +
    <%-- Box Footer --%> diff --git a/src/main/webapp/WEB-INF/view/admin/system/index.jsp b/src/main/webapp/WEB-INF/view/admin/system/index.jsp index e44d19a88..3c8d66f38 100644 --- a/src/main/webapp/WEB-INF/view/admin/system/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/system/index.jsp @@ -1,119 +1,108 @@ <%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - Fess | <bean:message key="labels.system_title_configuration" /> - - - -
    - - - - - + + +Fess | <la:message key="labels.system_title_configuration" /> + + + +
    + + + + + -
    - <%-- Content Header --%> - <%-- Message --%> -
    - -
    - -
    -
    - -
    +
    + <%-- Content Header --%> + <%-- Message --%> +
    + +
    ${msg}
    +
    + +
    -
    -
    -
    - -
    - <%-- Box Header --%> -
    -

    - -

    -
    - <%-- Box Body --%> -
    - - - - - - - -
    - ${f:h(clusterName)} - ( - - - - ) -
    -
    -
    - - -
    - <%-- Box Header --%> -
    -

    - -

    -
    - <%-- Box Body --%> -
    - <%-- Message --%> - - - - - - - - - - - -
    - - - - - - -
    - - - - " /> - - -
    - - - - - - - " /> -
    -
    -
    -
    -
    -
    -
    -
    -
    +
    +
    +
    +
    + <%-- Box Header --%> +
    +

    + +

    +
    + <%-- Box Body --%> +
    + + + + + + + +
    ${f:h(clusterName)} + (${f:h(clusterStatus)})
    +
    - + + +
    + <%-- Box Header --%> +
    +

    + +

    +
    + <%-- Box Body --%> +
    + <%-- Message --%> + + + + + + + + + + + +
    + + + + +
    + + " /> + +
    + + + + + + + " /> +
    +
    +
    +
    +
    +
    - - +
    +
    + +
    + + diff --git a/src/main/webapp/WEB-INF/view/admin/systemInfo/index.jsp b/src/main/webapp/WEB-INF/view/admin/systeminfo/index.jsp similarity index 68% rename from src/main/webapp/WEB-INF/view/admin/systemInfo/index.jsp rename to src/main/webapp/WEB-INF/view/admin/systeminfo/index.jsp index 47f0dac7d..95430fdaa 100644 --- a/src/main/webapp/WEB-INF/view/admin/systemInfo/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/systeminfo/index.jsp @@ -2,14 +2,14 @@ -Fess | <bean:message key="labels.system_info_configuration" /> +Fess | <la:message key="labels.system_info_configuration" />
    - + @@ -18,7 +18,7 @@ <%-- Content Header --%>

    - +

    @@ -30,27 +30,29 @@ <%-- Box Header --%>

    - +

    <%-- Box Body --%>
    - +
    <%-- Box Header --%>

    - +

    <%-- Box Body --%>
    @@ -58,19 +60,18 @@ <%-- Box Header --%>

    - +

    <%-- Box Body --%>
    - +
    @@ -79,13 +80,14 @@ <%-- Box Header --%>

    - +

    <%-- Box Body --%>
    @@ -100,4 +102,3 @@ - diff --git a/src/main/webapp/WEB-INF/view/admin/user/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/user/confirm.jsp new file mode 100644 index 000000000..c47775861 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/user/confirm.jsp @@ -0,0 +1,176 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.user_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> + + + + + + + + + + + + + + + +
    ${f:h(name)}
    + + + + ${f:h(rt.name)}
    +
    +
    +
    + + + ${f:h(rt.name)} + + +
    + + + + ${f:h(rt.name)}
    +
    +
    +
    + + + ${f:h(rt.name)} + + +
    + +
    + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/user/edit.jsp b/src/main/webapp/WEB-INF/view/admin/user/edit.jsp new file mode 100644 index 000000000..65d22e35e --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/user/edit.jsp @@ -0,0 +1,147 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.user_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> +
    + + + + + + ${f:h(name)} + + +
    +
    + + +
    +
    + + +
    +
    + + + + ${f:h(l.name)} + + +
    +
    + + + + ${f:h(l.name)} + + +
    + +
    + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/user/error.jsp b/src/main/webapp/WEB-INF/view/admin/user/error.jsp new file mode 100644 index 000000000..638128143 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/user/error.jsp @@ -0,0 +1,50 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.user_configuration" /> + + + +
    + + + + + + +
    +
    +

    + +

    + +
    + +
    + +
    +

    Error

    +

    + +

    +

    + + + +

    +
    + +
    +
    + + + +
    + + + diff --git a/src/main/webapp/WEB-INF/view/admin/user/index.jsp b/src/main/webapp/WEB-INF/view/admin/user/index.jsp new file mode 100644 index 000000000..18ed12183 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/user/index.jsp @@ -0,0 +1,126 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.user_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + +
    +
    +
    + <%-- Box Header --%> +
    +

    + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- List --%> + +

    + +

    +
    + + + + + + + + + + + + + + +
    ${f:h(data.name)}
    +
    + +
    + <%-- Box Footer --%> + +
    +
    +
    + +
    +
    + + +
    + + + + diff --git a/src/main/webapp/WEB-INF/view/admin/webAuthentication/edit.jsp b/src/main/webapp/WEB-INF/view/admin/webAuthentication/edit.jsp deleted file mode 100644 index 23722f25b..000000000 --- a/src/main/webapp/WEB-INF/view/admin/webAuthentication/edit.jsp +++ /dev/null @@ -1,155 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.web_authentication_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - -

    -
    - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - - <%-- Form Fields --%> -
    - - -
    -
    - - -
    -
    - - -
    -
    - - - - ${f:h(item.label)} - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - - - ${f:h(item.label)} - - -
    -
    - - <%-- Box Footer --%> - -
    -
    -
    -
    - -
    -
    - - -
    - - - diff --git a/src/main/webapp/WEB-INF/view/admin/webConfig/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/webConfig/confirm.jsp deleted file mode 100644 index 3bd0143e8..000000000 --- a/src/main/webapp/WEB-INF/view/admin/webConfig/confirm.jsp +++ /dev/null @@ -1,237 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.web_crawling_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - - - - - - - -

    -
    - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - - <%-- Form Fields --%> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    ${f:h(id)}
    ${f:h(name)}
    ${f:br(f:h(urls))}
    ${f:br(f:h(includedUrls))}
    ${f:br(f:h(excludedUrls))}
    ${f:br(f:h(includedDocUrls))}
    ${f:br(f:h(excludedDocUrls))}
    ${f:br(f:h(configParameter))}
    ${f:h(depth)}
    ${f:h(maxAccessCount)}
    ${f:h(userAgent)}
    ${f:h(numOfThread)}
    ${f:h(intervalTime)}
    ${f:h(boost)}
    - - - - ${f:h(rt.name)}
    -
    -
    -
    - - - ${f:h(rt.name)} - - -
    - - - - ${f:h(l.name)}
    -
    -
    -
    - - - ${f:h(l.name)} - - -
    - - -
    - -
    - <%-- Box Footer --%> - -
    -
    -
    -
    - -
    -
    - - -
    - - - diff --git a/src/main/webapp/WEB-INF/view/admin/webConfig/edit.jsp b/src/main/webapp/WEB-INF/view/admin/webConfig/edit.jsp deleted file mode 100644 index ee11720fc..000000000 --- a/src/main/webapp/WEB-INF/view/admin/webConfig/edit.jsp +++ /dev/null @@ -1,197 +0,0 @@ -<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> - - - -Fess | <bean:message key="labels.web_crawling_configuration" /> - - - -
    - - - - - - -
    - - <%-- Content Header --%> -
    -

    - -

    - -
    - -
    - - <%-- Form --%> - - - - - - - - - -
    -
    -
    - <%-- Box Header --%> -
    -

    - - - - - - -

    -
    - - - -
    -
    - <%-- Box Body --%> -
    - <%-- Message --%> -
    - -
    - -
    -
    - -
    - - <%-- Form Fields --%> -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - -
    - - -
    -
    -
    - - -
    -
    - - - - ${f:h(rt.name)} - - -
    -
    - - - - ${f:h(l.name)} - - -
    -
    - - - - - - - - - -
    -
    - - <%-- Box Footer --%> - -
    -
    -
    -
    - -
    -
    - - -
    - - - diff --git a/src/main/webapp/WEB-INF/view/admin/webAuthentication/confirm.jsp b/src/main/webapp/WEB-INF/view/admin/webauthentication/confirm.jsp similarity index 50% rename from src/main/webapp/WEB-INF/view/admin/webAuthentication/confirm.jsp rename to src/main/webapp/WEB-INF/view/admin/webauthentication/confirm.jsp index f31401fb6..10c2e0821 100644 --- a/src/main/webapp/WEB-INF/view/admin/webAuthentication/confirm.jsp +++ b/src/main/webapp/WEB-INF/view/admin/webauthentication/confirm.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.web_authentication_configuration" /> +Fess | <la:message key="labels.web_authentication_configuration" /> @@ -18,23 +18,23 @@ <%-- Content Header --%>

    - +

    @@ -42,14 +42,14 @@
    <%-- Form --%> - - + + - - + + - - + +
    @@ -57,75 +57,75 @@

    - + - + - + - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- Form Fields --%> - - + + - - + + - - + + - + + - - + + - + + - - + + - + +
    ${f:h(hostname)}${f:h(hostname)}
    ${f:h(port)}${f:h(port)}
    ${f:h(authRealm)}${f:h(authRealm)}
    ${f:h(item.label)} -
    ${f:h(username)}${f:h(username)}
    ****** -
    ${f:br(f:h(parameters))}${f:br(f:h(parameters))}
    ${f:h(item.label)} -
    @@ -134,37 +134,37 @@ <%-- Box Footer --%>
    - +
    diff --git a/src/main/webapp/WEB-INF/view/admin/webauthentication/edit.jsp b/src/main/webapp/WEB-INF/view/admin/webauthentication/edit.jsp new file mode 100644 index 000000000..3f1e045f6 --- /dev/null +++ b/src/main/webapp/WEB-INF/view/admin/webauthentication/edit.jsp @@ -0,0 +1,155 @@ +<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> + + + +Fess | <la:message key="labels.web_authentication_configuration" /> + + + +
    + + + + + + +
    + + <%-- Content Header --%> +
    +

    + +

    + +
    + +
    + + <%-- Form --%> + + + + + + + + + +
    +
    +
    + <%-- Box Header --%> +
    +

    + + + + + + +

    +
    + + + +
    +
    + <%-- Box Body --%> +
    + <%-- Message --%> +
    + +
    + ${msg} +
    +
    + +
    + + <%-- Form Fields --%> +
    + + +
    +
    + + +
    +
    + + +
    +
    + + + + ${f:h(item.label)} + + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + + + + ${f:h(item.label)} + + +
    +
    + + <%-- Box Footer --%> + +
    +
    +
    +
    + +
    +
    + + +
    + + + diff --git a/src/main/webapp/WEB-INF/view/admin/webAuthentication/error.jsp b/src/main/webapp/WEB-INF/view/admin/webauthentication/error.jsp similarity index 70% rename from src/main/webapp/WEB-INF/view/admin/webAuthentication/error.jsp rename to src/main/webapp/WEB-INF/view/admin/webauthentication/error.jsp index 8a7857317..edfea7e3c 100644 --- a/src/main/webapp/WEB-INF/view/admin/webAuthentication/error.jsp +++ b/src/main/webapp/WEB-INF/view/admin/webauthentication/error.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.web_authentication_configuration" /> +Fess | <la:message key="labels.web_authentication_configuration" /> @@ -16,12 +16,12 @@

    - +

    @@ -30,12 +30,12 @@

    Error

    - +

    - - - + + +

    diff --git a/src/main/webapp/WEB-INF/view/admin/webAuthentication/index.jsp b/src/main/webapp/WEB-INF/view/admin/webauthentication/index.jsp similarity index 61% rename from src/main/webapp/WEB-INF/view/admin/webAuthentication/index.jsp rename to src/main/webapp/WEB-INF/view/admin/webauthentication/index.jsp index 68cf7aa7d..d4ce80243 100644 --- a/src/main/webapp/WEB-INF/view/admin/webAuthentication/index.jsp +++ b/src/main/webapp/WEB-INF/view/admin/webauthentication/index.jsp @@ -2,7 +2,7 @@ -Fess | <bean:message key="labels.web_authentication_configuration" /> +Fess | <la:message key="labels.web_authentication_configuration" /> @@ -18,12 +18,12 @@ <%-- Content Header --%>

    - +

    @@ -32,58 +32,58 @@
    - - - + + +
    <%-- Box Header --%>

    - +

    - - - + + +
    <%-- Box Body --%>
    <%-- Message --%>
    - +
    - + ${msg}
    -
    - + +
    <%-- List --%>

    - +

    - - + + - +
    - + ${f:h(data.hostname)}: - + ${f:h(data.port)} @@ -99,31 +99,31 @@ <%-- Box Footer --%>