add fess_user index
This commit is contained in:
parent
053e407452
commit
87a2256c55
96 changed files with 8086 additions and 477 deletions
|
@ -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
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -346,74 +346,6 @@ public abstract class AbstractBehavior<ENTITY extends Entity, CB extends Conditi
|
|||
return results;
|
||||
}
|
||||
|
||||
protected static String toString(final Object value) {
|
||||
if (value != null) {
|
||||
return value.toString();
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
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 {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
public static class BulkList<E> implements List<E> {
|
||||
|
||||
private final List<E> parent;
|
||||
|
|
|
@ -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;
|
||||
|
@ -57,7 +58,7 @@ public abstract class Bs${table.camelizedName}Bhv extends AbstractBehavior<${tab
|
|||
#foreach ($column in $table.columnList)
|
||||
#if ($column.isNormalColumn)
|
||||
#set ($javaNative = ${column.type})
|
||||
result.set${column.capCamelName}(to$javaNative(source.get("${column.name}")));
|
||||
result.set${column.capCamelName}(DfTypeUtil.to$javaNative(source.get("${column.name}")));
|
||||
#end
|
||||
#end
|
||||
return result;
|
||||
|
|
|
@ -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;
|
||||
|
|
|
@ -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;
|
||||
|
|
|
@ -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"
|
||||
}
|
79
src/main/config/es/fess_user.json
Normal file
79
src/main/config/es/fess_user.json
Normal file
|
@ -0,0 +1,79 @@
|
|||
{
|
||||
".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" : {
|
||||
"group" : {
|
||||
"type" : "string",
|
||||
"index" : "not_analyzed"
|
||||
},
|
||||
"id" : {
|
||||
"type" : "string",
|
||||
"index" : "not_analyzed"
|
||||
},
|
||||
"name" : {
|
||||
"type" : "string",
|
||||
"index" : "not_analyzed"
|
||||
},
|
||||
"password" : {
|
||||
"type" : "string",
|
||||
"index" : "not_analyzed"
|
||||
},
|
||||
"role" : {
|
||||
"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",
|
||||
"number_of_shards" : "5",
|
||||
"number_of_replicas" : "0"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -348,74 +348,6 @@ public abstract class AbstractBehavior<ENTITY extends Entity, CB extends Conditi
|
|||
return results;
|
||||
}
|
||||
|
||||
protected static String toString(final Object value) {
|
||||
if (value != null) {
|
||||
return value.toString();
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
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 {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
public static class BulkList<E> implements List<E> {
|
||||
|
||||
private final List<E> parent;
|
||||
|
|
|
@ -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<BoostDocum
|
|||
protected <RESULT extends BoostDocumentRule> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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 BsClickLogBhv extends AbstractBehavior<ClickLog, ClickLogC
|
|||
|
||||
@Override
|
||||
protected String asEsIndex() {
|
||||
return "search_log";
|
||||
return "fess_log";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -54,10 +55,10 @@ public abstract class BsClickLogBhv extends AbstractBehavior<ClickLog, ClickLogC
|
|||
protected <RESULT extends ClickLog> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,11 +55,11 @@ public abstract class BsCrawlingSessionBhv extends AbstractBehavior<CrawlingSess
|
|||
protected <RESULT extends CrawlingSession> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,11 +55,11 @@ public abstract class BsCrawlingSessionInfoBhv extends AbstractBehavior<Crawling
|
|||
protected <RESULT extends CrawlingSessionInfo> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,18 +55,18 @@ public abstract class BsDataConfigBhv extends AbstractBehavior<DataConfig, DataC
|
|||
protected <RESULT extends DataConfig> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,9 +55,9 @@ public abstract class BsDataConfigToLabelBhv extends AbstractBehavior<DataConfig
|
|||
protected <RESULT extends DataConfigToLabel> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,9 +55,9 @@ public abstract class BsDataConfigToRoleBhv extends AbstractBehavior<DataConfigT
|
|||
protected <RESULT extends DataConfigToRole> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
227
src/main/java/org/codelibs/fess/es/bsbhv/BsEventLogBhv.java
Normal file
227
src/main/java/org/codelibs/fess/es/bsbhv/BsEventLogBhv.java
Normal file
|
@ -0,0 +1,227 @@
|
|||
package org.codelibs.fess.es.bsbhv;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.codelibs.fess.es.bsentity.AbstractEntity;
|
||||
import org.codelibs.fess.es.bsentity.AbstractEntity.RequestOptionCall;
|
||||
import org.codelibs.fess.es.bsentity.dbmeta.EventLogDbm;
|
||||
import org.codelibs.fess.es.cbean.EventLogCB;
|
||||
import org.codelibs.fess.es.exentity.EventLog;
|
||||
import org.dbflute.Entity;
|
||||
import org.dbflute.bhv.readable.CBCall;
|
||||
import org.dbflute.bhv.readable.EntityRowHandler;
|
||||
import org.dbflute.cbean.ConditionBean;
|
||||
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;
|
||||
|
||||
/**
|
||||
* @author FreeGen
|
||||
*/
|
||||
public abstract class BsEventLogBhv extends AbstractBehavior<EventLog, EventLogCB> {
|
||||
|
||||
@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 extends EventLog> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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<EventLogCB> cbLambda) {
|
||||
return facadeSelectCount(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public OptionalEntity<EventLog> selectEntity(CBCall<EventLogCB> cbLambda) {
|
||||
return facadeSelectEntity(createCB(cbLambda));
|
||||
}
|
||||
|
||||
protected OptionalEntity<EventLog> facadeSelectEntity(EventLogCB cb) {
|
||||
return doSelectOptionalEntity(cb, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
protected <ENTITY extends EventLog> OptionalEntity<ENTITY> doSelectOptionalEntity(EventLogCB cb, Class<? extends ENTITY> 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<EventLogCB> cbLambda) {
|
||||
return facadeSelectEntityWithDeletedCheck(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public OptionalEntity<EventLog> selectByPK(String id) {
|
||||
return facadeSelectByPK(id);
|
||||
}
|
||||
|
||||
protected OptionalEntity<EventLog> facadeSelectByPK(String id) {
|
||||
return doSelectOptionalByPK(id, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
protected <ENTITY extends EventLog> ENTITY doSelectByPK(String id, Class<? extends ENTITY> tp) {
|
||||
return doSelectEntity(xprepareCBAsPK(id), tp);
|
||||
}
|
||||
|
||||
protected EventLogCB xprepareCBAsPK(String id) {
|
||||
assertObjectNotNull("id", id);
|
||||
return newConditionBean().acceptPK(id);
|
||||
}
|
||||
|
||||
protected <ENTITY extends EventLog> OptionalEntity<ENTITY> doSelectOptionalByPK(String id, Class<? extends ENTITY> tp) {
|
||||
return createOptionalEntity(doSelectByPK(id, tp), id);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<? extends EventLog> typeOfSelectedEntity() {
|
||||
return EventLog.class;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<EventLog> typeOfHandlingEntity() {
|
||||
return EventLog.class;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<EventLogCB> typeOfHandlingConditionBean() {
|
||||
return EventLogCB.class;
|
||||
}
|
||||
|
||||
public ListResultBean<EventLog> selectList(CBCall<EventLogCB> cbLambda) {
|
||||
return facadeSelectList(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public PagingResultBean<EventLog> selectPage(CBCall<EventLogCB> cbLambda) {
|
||||
// TODO same?
|
||||
return (PagingResultBean<EventLog>) facadeSelectList(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public void selectCursor(CBCall<EventLogCB> cbLambda, EntityRowHandler<EventLog> entityLambda) {
|
||||
facadeSelectCursor(createCB(cbLambda), entityLambda);
|
||||
}
|
||||
|
||||
public void selectBulk(CBCall<EventLogCB> cbLambda, EntityRowHandler<List<EventLog>> entityLambda) {
|
||||
delegateSelectBulk(createCB(cbLambda), entityLambda, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
public void insert(EventLog entity) {
|
||||
doInsert(entity, null);
|
||||
}
|
||||
|
||||
public void insert(EventLog entity, RequestOptionCall<IndexRequestBuilder> 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<IndexRequestBuilder> 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<IndexRequestBuilder> 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<DeleteRequestBuilder> opLambda) {
|
||||
if (entity instanceof AbstractEntity) {
|
||||
entity.asDocMeta().deleteOption(opLambda);
|
||||
}
|
||||
doDelete(entity, null);
|
||||
}
|
||||
|
||||
public int queryDelete(CBCall<EventLogCB> cbLambda) {
|
||||
return doQueryDelete(createCB(cbLambda), null);
|
||||
}
|
||||
|
||||
public int[] batchInsert(List<EventLog> list) {
|
||||
return batchInsert(list, null);
|
||||
}
|
||||
|
||||
public int[] batchInsert(List<EventLog> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchInsert(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
public int[] batchUpdate(List<EventLog> list) {
|
||||
return batchUpdate(list, null);
|
||||
}
|
||||
|
||||
public int[] batchUpdate(List<EventLog> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchUpdate(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
public int[] batchDelete(List<EventLog> list) {
|
||||
return batchDelete(list, null);
|
||||
}
|
||||
|
||||
public int[] batchDelete(List<EventLog> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchDelete(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
// TODO create, modify, remove
|
||||
}
|
|
@ -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<FailureUrl, Failu
|
|||
protected <RESULT extends FailureUrl> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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 BsFavoriteLogBhv extends AbstractBehavior<FavoriteLog, Fav
|
|||
|
||||
@Override
|
||||
protected String asEsIndex() {
|
||||
return "search_log";
|
||||
return "fess_log";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -54,10 +55,10 @@ public abstract class BsFavoriteLogBhv extends AbstractBehavior<FavoriteLog, Fav
|
|||
protected <RESULT extends FavoriteLog> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,18 +55,18 @@ public abstract class BsFileAuthenticationBhv extends AbstractBehavior<FileAuthe
|
|||
protected <RESULT extends FileAuthentication> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,25 +55,25 @@ public abstract class BsFileConfigBhv extends AbstractBehavior<FileConfig, FileC
|
|||
protected <RESULT extends FileConfig> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,9 +55,9 @@ public abstract class BsFileConfigToLabelBhv extends AbstractBehavior<FileConfig
|
|||
protected <RESULT extends FileConfigToLabel> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,9 +55,9 @@ public abstract class BsFileConfigToRoleBhv extends AbstractBehavior<FileConfigT
|
|||
protected <RESULT extends FileConfigToRole> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
223
src/main/java/org/codelibs/fess/es/bsbhv/BsGroupBhv.java
Normal file
223
src/main/java/org/codelibs/fess/es/bsbhv/BsGroupBhv.java
Normal file
|
@ -0,0 +1,223 @@
|
|||
package org.codelibs.fess.es.bsbhv;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.codelibs.fess.es.bsentity.AbstractEntity;
|
||||
import org.codelibs.fess.es.bsentity.AbstractEntity.RequestOptionCall;
|
||||
import org.codelibs.fess.es.bsentity.dbmeta.GroupDbm;
|
||||
import org.codelibs.fess.es.cbean.GroupCB;
|
||||
import org.codelibs.fess.es.exentity.Group;
|
||||
import org.dbflute.Entity;
|
||||
import org.dbflute.bhv.readable.CBCall;
|
||||
import org.dbflute.bhv.readable.EntityRowHandler;
|
||||
import org.dbflute.cbean.ConditionBean;
|
||||
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;
|
||||
|
||||
/**
|
||||
* @author FreeGen
|
||||
*/
|
||||
public abstract class BsGroupBhv extends AbstractBehavior<Group, GroupCB> {
|
||||
|
||||
@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 extends Group> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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<GroupCB> cbLambda) {
|
||||
return facadeSelectCount(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public OptionalEntity<Group> selectEntity(CBCall<GroupCB> cbLambda) {
|
||||
return facadeSelectEntity(createCB(cbLambda));
|
||||
}
|
||||
|
||||
protected OptionalEntity<Group> facadeSelectEntity(GroupCB cb) {
|
||||
return doSelectOptionalEntity(cb, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
protected <ENTITY extends Group> OptionalEntity<ENTITY> doSelectOptionalEntity(GroupCB cb, Class<? extends ENTITY> 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<GroupCB> cbLambda) {
|
||||
return facadeSelectEntityWithDeletedCheck(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public OptionalEntity<Group> selectByPK(String id) {
|
||||
return facadeSelectByPK(id);
|
||||
}
|
||||
|
||||
protected OptionalEntity<Group> facadeSelectByPK(String id) {
|
||||
return doSelectOptionalByPK(id, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
protected <ENTITY extends Group> ENTITY doSelectByPK(String id, Class<? extends ENTITY> tp) {
|
||||
return doSelectEntity(xprepareCBAsPK(id), tp);
|
||||
}
|
||||
|
||||
protected GroupCB xprepareCBAsPK(String id) {
|
||||
assertObjectNotNull("id", id);
|
||||
return newConditionBean().acceptPK(id);
|
||||
}
|
||||
|
||||
protected <ENTITY extends Group> OptionalEntity<ENTITY> doSelectOptionalByPK(String id, Class<? extends ENTITY> tp) {
|
||||
return createOptionalEntity(doSelectByPK(id, tp), id);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<? extends Group> typeOfSelectedEntity() {
|
||||
return Group.class;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<Group> typeOfHandlingEntity() {
|
||||
return Group.class;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<GroupCB> typeOfHandlingConditionBean() {
|
||||
return GroupCB.class;
|
||||
}
|
||||
|
||||
public ListResultBean<Group> selectList(CBCall<GroupCB> cbLambda) {
|
||||
return facadeSelectList(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public PagingResultBean<Group> selectPage(CBCall<GroupCB> cbLambda) {
|
||||
// TODO same?
|
||||
return (PagingResultBean<Group>) facadeSelectList(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public void selectCursor(CBCall<GroupCB> cbLambda, EntityRowHandler<Group> entityLambda) {
|
||||
facadeSelectCursor(createCB(cbLambda), entityLambda);
|
||||
}
|
||||
|
||||
public void selectBulk(CBCall<GroupCB> cbLambda, EntityRowHandler<List<Group>> entityLambda) {
|
||||
delegateSelectBulk(createCB(cbLambda), entityLambda, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
public void insert(Group entity) {
|
||||
doInsert(entity, null);
|
||||
}
|
||||
|
||||
public void insert(Group entity, RequestOptionCall<IndexRequestBuilder> 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<IndexRequestBuilder> 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<IndexRequestBuilder> 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<DeleteRequestBuilder> opLambda) {
|
||||
if (entity instanceof AbstractEntity) {
|
||||
entity.asDocMeta().deleteOption(opLambda);
|
||||
}
|
||||
doDelete(entity, null);
|
||||
}
|
||||
|
||||
public int queryDelete(CBCall<GroupCB> cbLambda) {
|
||||
return doQueryDelete(createCB(cbLambda), null);
|
||||
}
|
||||
|
||||
public int[] batchInsert(List<Group> list) {
|
||||
return batchInsert(list, null);
|
||||
}
|
||||
|
||||
public int[] batchInsert(List<Group> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchInsert(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
public int[] batchUpdate(List<Group> list) {
|
||||
return batchUpdate(list, null);
|
||||
}
|
||||
|
||||
public int[] batchUpdate(List<Group> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchUpdate(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
public int[] batchDelete(List<Group> list) {
|
||||
return batchDelete(list, null);
|
||||
}
|
||||
|
||||
public int[] batchDelete(List<Group> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchDelete(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
// TODO create, modify, remove
|
||||
}
|
|
@ -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<JobLog, JobLogCB> {
|
|||
protected <RESULT extends JobLog> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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<KeyMatch, KeyMatchC
|
|||
protected <RESULT extends KeyMatch> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,9 +55,9 @@ public abstract class BsLabelToRoleBhv extends AbstractBehavior<LabelToRole, Lab
|
|||
protected <RESULT extends LabelToRole> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,16 +55,16 @@ public abstract class BsLabelTypeBhv extends AbstractBehavior<LabelType, LabelTy
|
|||
protected <RESULT extends LabelType> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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 BsOverlappingHostBhv extends AbstractBehavior<OverlappingH
|
|||
protected <RESULT extends OverlappingHost> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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 BsPathMappingBhv extends AbstractBehavior<PathMapping, Pat
|
|||
protected <RESULT extends PathMapping> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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 BsRequestHeaderBhv extends AbstractBehavior<RequestHeader,
|
|||
protected <RESULT extends RequestHeader> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
223
src/main/java/org/codelibs/fess/es/bsbhv/BsRoleBhv.java
Normal file
223
src/main/java/org/codelibs/fess/es/bsbhv/BsRoleBhv.java
Normal file
|
@ -0,0 +1,223 @@
|
|||
package org.codelibs.fess.es.bsbhv;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.codelibs.fess.es.bsentity.AbstractEntity;
|
||||
import org.codelibs.fess.es.bsentity.AbstractEntity.RequestOptionCall;
|
||||
import org.codelibs.fess.es.bsentity.dbmeta.RoleDbm;
|
||||
import org.codelibs.fess.es.cbean.RoleCB;
|
||||
import org.codelibs.fess.es.exentity.Role;
|
||||
import org.dbflute.Entity;
|
||||
import org.dbflute.bhv.readable.CBCall;
|
||||
import org.dbflute.bhv.readable.EntityRowHandler;
|
||||
import org.dbflute.cbean.ConditionBean;
|
||||
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;
|
||||
|
||||
/**
|
||||
* @author FreeGen
|
||||
*/
|
||||
public abstract class BsRoleBhv extends AbstractBehavior<Role, RoleCB> {
|
||||
|
||||
@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 extends Role> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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<RoleCB> cbLambda) {
|
||||
return facadeSelectCount(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public OptionalEntity<Role> selectEntity(CBCall<RoleCB> cbLambda) {
|
||||
return facadeSelectEntity(createCB(cbLambda));
|
||||
}
|
||||
|
||||
protected OptionalEntity<Role> facadeSelectEntity(RoleCB cb) {
|
||||
return doSelectOptionalEntity(cb, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
protected <ENTITY extends Role> OptionalEntity<ENTITY> doSelectOptionalEntity(RoleCB cb, Class<? extends ENTITY> 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<RoleCB> cbLambda) {
|
||||
return facadeSelectEntityWithDeletedCheck(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public OptionalEntity<Role> selectByPK(String id) {
|
||||
return facadeSelectByPK(id);
|
||||
}
|
||||
|
||||
protected OptionalEntity<Role> facadeSelectByPK(String id) {
|
||||
return doSelectOptionalByPK(id, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
protected <ENTITY extends Role> ENTITY doSelectByPK(String id, Class<? extends ENTITY> tp) {
|
||||
return doSelectEntity(xprepareCBAsPK(id), tp);
|
||||
}
|
||||
|
||||
protected RoleCB xprepareCBAsPK(String id) {
|
||||
assertObjectNotNull("id", id);
|
||||
return newConditionBean().acceptPK(id);
|
||||
}
|
||||
|
||||
protected <ENTITY extends Role> OptionalEntity<ENTITY> doSelectOptionalByPK(String id, Class<? extends ENTITY> tp) {
|
||||
return createOptionalEntity(doSelectByPK(id, tp), id);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<? extends Role> typeOfSelectedEntity() {
|
||||
return Role.class;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<Role> typeOfHandlingEntity() {
|
||||
return Role.class;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<RoleCB> typeOfHandlingConditionBean() {
|
||||
return RoleCB.class;
|
||||
}
|
||||
|
||||
public ListResultBean<Role> selectList(CBCall<RoleCB> cbLambda) {
|
||||
return facadeSelectList(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public PagingResultBean<Role> selectPage(CBCall<RoleCB> cbLambda) {
|
||||
// TODO same?
|
||||
return (PagingResultBean<Role>) facadeSelectList(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public void selectCursor(CBCall<RoleCB> cbLambda, EntityRowHandler<Role> entityLambda) {
|
||||
facadeSelectCursor(createCB(cbLambda), entityLambda);
|
||||
}
|
||||
|
||||
public void selectBulk(CBCall<RoleCB> cbLambda, EntityRowHandler<List<Role>> entityLambda) {
|
||||
delegateSelectBulk(createCB(cbLambda), entityLambda, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
public void insert(Role entity) {
|
||||
doInsert(entity, null);
|
||||
}
|
||||
|
||||
public void insert(Role entity, RequestOptionCall<IndexRequestBuilder> 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<IndexRequestBuilder> 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<IndexRequestBuilder> 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<DeleteRequestBuilder> opLambda) {
|
||||
if (entity instanceof AbstractEntity) {
|
||||
entity.asDocMeta().deleteOption(opLambda);
|
||||
}
|
||||
doDelete(entity, null);
|
||||
}
|
||||
|
||||
public int queryDelete(CBCall<RoleCB> cbLambda) {
|
||||
return doQueryDelete(createCB(cbLambda), null);
|
||||
}
|
||||
|
||||
public int[] batchInsert(List<Role> list) {
|
||||
return batchInsert(list, null);
|
||||
}
|
||||
|
||||
public int[] batchInsert(List<Role> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchInsert(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
public int[] batchUpdate(List<Role> list) {
|
||||
return batchUpdate(list, null);
|
||||
}
|
||||
|
||||
public int[] batchUpdate(List<Role> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchUpdate(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
public int[] batchDelete(List<Role> list) {
|
||||
return batchDelete(list, null);
|
||||
}
|
||||
|
||||
public int[] batchDelete(List<Role> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchDelete(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
// TODO create, modify, remove
|
||||
}
|
|
@ -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<RoleType, RoleTypeC
|
|||
protected <RESULT extends RoleType> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,20 +55,20 @@ public abstract class BsScheduledJobBhv extends AbstractBehavior<ScheduledJob, S
|
|||
protected <RESULT extends ScheduledJob> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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 BsSearchFieldLogBhv extends AbstractBehavior<SearchFieldLo
|
|||
|
||||
@Override
|
||||
protected String asEsIndex() {
|
||||
return "search_log";
|
||||
return "fess_log";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -54,10 +55,10 @@ public abstract class BsSearchFieldLogBhv extends AbstractBehavior<SearchFieldLo
|
|||
protected <RESULT extends SearchFieldLog> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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 BsSearchLogBhv extends AbstractBehavior<SearchLog, SearchL
|
|||
|
||||
@Override
|
||||
protected String asEsIndex() {
|
||||
return "search_log";
|
||||
return "fess_log";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -54,19 +55,19 @@ public abstract class BsSearchLogBhv extends AbstractBehavior<SearchLog, SearchL
|
|||
protected <RESULT extends SearchLog> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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 BsSuggestBadWordBhv extends AbstractBehavior<SuggestBadWor
|
|||
protected <RESULT extends SuggestBadWord> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,16 +55,16 @@ public abstract class BsSuggestElevateWordBhv extends AbstractBehavior<SuggestEl
|
|||
protected <RESULT extends SuggestElevateWord> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
226
src/main/java/org/codelibs/fess/es/bsbhv/BsUserBhv.java
Normal file
226
src/main/java/org/codelibs/fess/es/bsbhv/BsUserBhv.java
Normal file
|
@ -0,0 +1,226 @@
|
|||
package org.codelibs.fess.es.bsbhv;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.codelibs.fess.es.bsentity.AbstractEntity;
|
||||
import org.codelibs.fess.es.bsentity.AbstractEntity.RequestOptionCall;
|
||||
import org.codelibs.fess.es.bsentity.dbmeta.UserDbm;
|
||||
import org.codelibs.fess.es.cbean.UserCB;
|
||||
import org.codelibs.fess.es.exentity.User;
|
||||
import org.dbflute.Entity;
|
||||
import org.dbflute.bhv.readable.CBCall;
|
||||
import org.dbflute.bhv.readable.EntityRowHandler;
|
||||
import org.dbflute.cbean.ConditionBean;
|
||||
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;
|
||||
|
||||
/**
|
||||
* @author FreeGen
|
||||
*/
|
||||
public abstract class BsUserBhv extends AbstractBehavior<User, UserCB> {
|
||||
|
||||
@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 extends User> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> entityType) {
|
||||
try {
|
||||
final RESULT result = entityType.newInstance();
|
||||
result.setGroup(DfTypeUtil.toString(source.get("group")));
|
||||
result.setId(DfTypeUtil.toString(source.get("id")));
|
||||
result.setName(DfTypeUtil.toString(source.get("name")));
|
||||
result.setPassword(DfTypeUtil.toString(source.get("password")));
|
||||
result.setRole(DfTypeUtil.toString(source.get("role")));
|
||||
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<UserCB> cbLambda) {
|
||||
return facadeSelectCount(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public OptionalEntity<User> selectEntity(CBCall<UserCB> cbLambda) {
|
||||
return facadeSelectEntity(createCB(cbLambda));
|
||||
}
|
||||
|
||||
protected OptionalEntity<User> facadeSelectEntity(UserCB cb) {
|
||||
return doSelectOptionalEntity(cb, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
protected <ENTITY extends User> OptionalEntity<ENTITY> doSelectOptionalEntity(UserCB cb, Class<? extends ENTITY> 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<UserCB> cbLambda) {
|
||||
return facadeSelectEntityWithDeletedCheck(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public OptionalEntity<User> selectByPK(String id) {
|
||||
return facadeSelectByPK(id);
|
||||
}
|
||||
|
||||
protected OptionalEntity<User> facadeSelectByPK(String id) {
|
||||
return doSelectOptionalByPK(id, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
protected <ENTITY extends User> ENTITY doSelectByPK(String id, Class<? extends ENTITY> tp) {
|
||||
return doSelectEntity(xprepareCBAsPK(id), tp);
|
||||
}
|
||||
|
||||
protected UserCB xprepareCBAsPK(String id) {
|
||||
assertObjectNotNull("id", id);
|
||||
return newConditionBean().acceptPK(id);
|
||||
}
|
||||
|
||||
protected <ENTITY extends User> OptionalEntity<ENTITY> doSelectOptionalByPK(String id, Class<? extends ENTITY> tp) {
|
||||
return createOptionalEntity(doSelectByPK(id, tp), id);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<? extends User> typeOfSelectedEntity() {
|
||||
return User.class;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<User> typeOfHandlingEntity() {
|
||||
return User.class;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Class<UserCB> typeOfHandlingConditionBean() {
|
||||
return UserCB.class;
|
||||
}
|
||||
|
||||
public ListResultBean<User> selectList(CBCall<UserCB> cbLambda) {
|
||||
return facadeSelectList(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public PagingResultBean<User> selectPage(CBCall<UserCB> cbLambda) {
|
||||
// TODO same?
|
||||
return (PagingResultBean<User>) facadeSelectList(createCB(cbLambda));
|
||||
}
|
||||
|
||||
public void selectCursor(CBCall<UserCB> cbLambda, EntityRowHandler<User> entityLambda) {
|
||||
facadeSelectCursor(createCB(cbLambda), entityLambda);
|
||||
}
|
||||
|
||||
public void selectBulk(CBCall<UserCB> cbLambda, EntityRowHandler<List<User>> entityLambda) {
|
||||
delegateSelectBulk(createCB(cbLambda), entityLambda, typeOfSelectedEntity());
|
||||
}
|
||||
|
||||
public void insert(User entity) {
|
||||
doInsert(entity, null);
|
||||
}
|
||||
|
||||
public void insert(User entity, RequestOptionCall<IndexRequestBuilder> 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<IndexRequestBuilder> 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<IndexRequestBuilder> 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<DeleteRequestBuilder> opLambda) {
|
||||
if (entity instanceof AbstractEntity) {
|
||||
entity.asDocMeta().deleteOption(opLambda);
|
||||
}
|
||||
doDelete(entity, null);
|
||||
}
|
||||
|
||||
public int queryDelete(CBCall<UserCB> cbLambda) {
|
||||
return doQueryDelete(createCB(cbLambda), null);
|
||||
}
|
||||
|
||||
public int[] batchInsert(List<User> list) {
|
||||
return batchInsert(list, null);
|
||||
}
|
||||
|
||||
public int[] batchInsert(List<User> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchInsert(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
public int[] batchUpdate(List<User> list) {
|
||||
return batchUpdate(list, null);
|
||||
}
|
||||
|
||||
public int[] batchUpdate(List<User> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchUpdate(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
public int[] batchDelete(List<User> list) {
|
||||
return batchDelete(list, null);
|
||||
}
|
||||
|
||||
public int[] batchDelete(List<User> list, RequestOptionCall<BulkRequestBuilder> call) {
|
||||
return doBatchDelete(new BulkList<>(list, call), null);
|
||||
}
|
||||
|
||||
// TODO create, modify, remove
|
||||
}
|
|
@ -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<UserInfo, UserInfoC
|
|||
|
||||
@Override
|
||||
protected String asEsIndex() {
|
||||
return "search_log";
|
||||
return "fess_log";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -54,10 +55,10 @@ public abstract class BsUserInfoBhv extends AbstractBehavior<UserInfo, UserInfoC
|
|||
protected <RESULT extends UserInfo> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,19 +55,19 @@ public abstract class BsWebAuthenticationBhv extends AbstractBehavior<WebAuthent
|
|||
protected <RESULT extends WebAuthentication> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,26 +55,26 @@ public abstract class BsWebConfigBhv extends AbstractBehavior<WebConfig, WebConf
|
|||
protected <RESULT extends WebConfig> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,9 +55,9 @@ public abstract class BsWebConfigToLabelBhv extends AbstractBehavior<WebConfigTo
|
|||
protected <RESULT extends WebConfigToLabel> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
|
@ -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,9 +55,9 @@ public abstract class BsWebConfigToRoleBhv extends AbstractBehavior<WebConfigToR
|
|||
protected <RESULT extends WebConfigToRole> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> 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();
|
||||
|
|
133
src/main/java/org/codelibs/fess/es/bsentity/BsEventLog.java
Normal file
133
src/main/java/org/codelibs/fess/es/bsentity/BsEventLog.java
Normal file
|
@ -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<String, Object> toSource() {
|
||||
Map<String, Object> 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;
|
||||
}
|
||||
}
|
68
src/main/java/org/codelibs/fess/es/bsentity/BsGroup.java
Normal file
68
src/main/java/org/codelibs/fess/es/bsentity/BsGroup.java
Normal file
|
@ -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<String, Object> toSource() {
|
||||
Map<String, Object> sourceMap = new HashMap<>();
|
||||
if (asDocMeta().id() != null) {
|
||||
sourceMap.put("id", asDocMeta().id());
|
||||
}
|
||||
if (name != null) {
|
||||
sourceMap.put("name", name);
|
||||
}
|
||||
return sourceMap;
|
||||
}
|
||||
}
|
68
src/main/java/org/codelibs/fess/es/bsentity/BsRole.java
Normal file
68
src/main/java/org/codelibs/fess/es/bsentity/BsRole.java
Normal file
|
@ -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<String, Object> toSource() {
|
||||
Map<String, Object> sourceMap = new HashMap<>();
|
||||
if (asDocMeta().id() != null) {
|
||||
sourceMap.put("id", asDocMeta().id());
|
||||
}
|
||||
if (name != null) {
|
||||
sourceMap.put("name", name);
|
||||
}
|
||||
return sourceMap;
|
||||
}
|
||||
}
|
116
src/main/java/org/codelibs/fess/es/bsentity/BsUser.java
Normal file
116
src/main/java/org/codelibs/fess/es/bsentity/BsUser.java
Normal file
|
@ -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
|
||||
// =========
|
||||
/** group */
|
||||
protected String group;
|
||||
|
||||
/** name */
|
||||
protected String name;
|
||||
|
||||
/** password */
|
||||
protected String password;
|
||||
|
||||
/** role */
|
||||
protected String role;
|
||||
|
||||
// [Referrers] *comment only
|
||||
|
||||
// ===================================================================================
|
||||
// Accessor
|
||||
// ========
|
||||
public String getGroup() {
|
||||
checkSpecifiedProperty("group");
|
||||
return group;
|
||||
}
|
||||
|
||||
public void setGroup(String value) {
|
||||
registerModifiedProperty("group");
|
||||
this.group = 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 getRole() {
|
||||
checkSpecifiedProperty("role");
|
||||
return role;
|
||||
}
|
||||
|
||||
public void setRole(String value) {
|
||||
registerModifiedProperty("role");
|
||||
this.role = value;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> toSource() {
|
||||
Map<String, Object> sourceMap = new HashMap<>();
|
||||
if (group != null) {
|
||||
sourceMap.put("group", group);
|
||||
}
|
||||
if (asDocMeta().id() != null) {
|
||||
sourceMap.put("id", asDocMeta().id());
|
||||
}
|
||||
if (name != null) {
|
||||
sourceMap.put("name", name);
|
||||
}
|
||||
if (password != null) {
|
||||
sourceMap.put("password", password);
|
||||
}
|
||||
if (role != null) {
|
||||
sourceMap.put("role", role);
|
||||
}
|
||||
return sourceMap;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,153 @@
|
|||
package org.codelibs.fess.es.bsentity.dbmeta;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
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.dbway.DBDef;
|
||||
|
||||
public class EventLogDbm extends AbstractDBMeta {
|
||||
|
||||
// ===================================================================================
|
||||
// Singleton
|
||||
// =========
|
||||
private static final EventLogDbm _instance = new EventLogDbm();
|
||||
|
||||
private EventLogDbm() {
|
||||
}
|
||||
|
||||
public static EventLogDbm getInstance() {
|
||||
return _instance;
|
||||
}
|
||||
|
||||
@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 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
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasCompoundPrimaryKey() {
|
||||
// TODO Auto-generated method stub
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getEntityTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getConditionBeanTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getBehaviorTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Class<? extends Entity> getEntityType() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Entity newEntity() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void acceptPrimaryKeyMap(Entity entity, Map<String, ? extends Object> primaryKeyMap) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void acceptAllColumnMap(Entity entity, Map<String, ? extends Object> allColumnMap) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> extractPrimaryKeyMap(Entity entity) {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> extractAllColumnMap(Entity entity) {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected List<ColumnInfo> ccil() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected UniqueInfo cpui() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
}
|
153
src/main/java/org/codelibs/fess/es/bsentity/dbmeta/GroupDbm.java
Normal file
153
src/main/java/org/codelibs/fess/es/bsentity/dbmeta/GroupDbm.java
Normal file
|
@ -0,0 +1,153 @@
|
|||
package org.codelibs.fess.es.bsentity.dbmeta;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
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.dbway.DBDef;
|
||||
|
||||
public class GroupDbm extends AbstractDBMeta {
|
||||
|
||||
// ===================================================================================
|
||||
// Singleton
|
||||
// =========
|
||||
private static final GroupDbm _instance = new GroupDbm();
|
||||
|
||||
private GroupDbm() {
|
||||
}
|
||||
|
||||
public static GroupDbm getInstance() {
|
||||
return _instance;
|
||||
}
|
||||
|
||||
@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 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
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasCompoundPrimaryKey() {
|
||||
// TODO Auto-generated method stub
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getEntityTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getConditionBeanTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getBehaviorTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Class<? extends Entity> getEntityType() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Entity newEntity() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void acceptPrimaryKeyMap(Entity entity, Map<String, ? extends Object> primaryKeyMap) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void acceptAllColumnMap(Entity entity, Map<String, ? extends Object> allColumnMap) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> extractPrimaryKeyMap(Entity entity) {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> extractAllColumnMap(Entity entity) {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected List<ColumnInfo> ccil() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected UniqueInfo cpui() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
}
|
153
src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RoleDbm.java
Normal file
153
src/main/java/org/codelibs/fess/es/bsentity/dbmeta/RoleDbm.java
Normal file
|
@ -0,0 +1,153 @@
|
|||
package org.codelibs.fess.es.bsentity.dbmeta;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
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.dbway.DBDef;
|
||||
|
||||
public class RoleDbm extends AbstractDBMeta {
|
||||
|
||||
// ===================================================================================
|
||||
// Singleton
|
||||
// =========
|
||||
private static final RoleDbm _instance = new RoleDbm();
|
||||
|
||||
private RoleDbm() {
|
||||
}
|
||||
|
||||
public static RoleDbm getInstance() {
|
||||
return _instance;
|
||||
}
|
||||
|
||||
@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 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
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasCompoundPrimaryKey() {
|
||||
// TODO Auto-generated method stub
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getEntityTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getConditionBeanTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getBehaviorTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Class<? extends Entity> getEntityType() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Entity newEntity() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void acceptPrimaryKeyMap(Entity entity, Map<String, ? extends Object> primaryKeyMap) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void acceptAllColumnMap(Entity entity, Map<String, ? extends Object> allColumnMap) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> extractPrimaryKeyMap(Entity entity) {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> extractAllColumnMap(Entity entity) {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected List<ColumnInfo> ccil() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected UniqueInfo cpui() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
}
|
153
src/main/java/org/codelibs/fess/es/bsentity/dbmeta/UserDbm.java
Normal file
153
src/main/java/org/codelibs/fess/es/bsentity/dbmeta/UserDbm.java
Normal file
|
@ -0,0 +1,153 @@
|
|||
package org.codelibs.fess.es.bsentity.dbmeta;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
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.dbway.DBDef;
|
||||
|
||||
public class UserDbm extends AbstractDBMeta {
|
||||
|
||||
// ===================================================================================
|
||||
// Singleton
|
||||
// =========
|
||||
private static final UserDbm _instance = new UserDbm();
|
||||
|
||||
private UserDbm() {
|
||||
}
|
||||
|
||||
public static UserDbm getInstance() {
|
||||
return _instance;
|
||||
}
|
||||
|
||||
@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 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
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasCompoundPrimaryKey() {
|
||||
// TODO Auto-generated method stub
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getEntityTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getConditionBeanTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getBehaviorTypeName() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Class<? extends Entity> getEntityType() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Entity newEntity() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void acceptPrimaryKeyMap(Entity entity, Map<String, ? extends Object> primaryKeyMap) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void acceptAllColumnMap(Entity entity, Map<String, ? extends Object> allColumnMap) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> extractPrimaryKeyMap(Entity entity) {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> extractAllColumnMap(Entity entity) {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected List<ColumnInfo> ccil() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected UniqueInfo cpui() {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
}
|
9
src/main/java/org/codelibs/fess/es/cbean/EventLogCB.java
Normal file
9
src/main/java/org/codelibs/fess/es/cbean/EventLogCB.java
Normal file
|
@ -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 {
|
||||
}
|
9
src/main/java/org/codelibs/fess/es/cbean/GroupCB.java
Normal file
9
src/main/java/org/codelibs/fess/es/cbean/GroupCB.java
Normal file
|
@ -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 {
|
||||
}
|
9
src/main/java/org/codelibs/fess/es/cbean/RoleCB.java
Normal file
9
src/main/java/org/codelibs/fess/es/cbean/RoleCB.java
Normal file
|
@ -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 {
|
||||
}
|
9
src/main/java/org/codelibs/fess/es/cbean/UserCB.java
Normal file
9
src/main/java/org/codelibs/fess/es/cbean/UserCB.java
Normal file
|
@ -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 {
|
||||
}
|
150
src/main/java/org/codelibs/fess/es/cbean/bs/BsEventLogCB.java
Normal file
150
src/main/java/org/codelibs/fess/es/cbean/bs/BsEventLogCB.java
Normal file
|
@ -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<String, ? extends Object> 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<String> 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");
|
||||
}
|
||||
}
|
||||
}
|
134
src/main/java/org/codelibs/fess/es/cbean/bs/BsGroupCB.java
Normal file
134
src/main/java/org/codelibs/fess/es/cbean/bs/BsGroupCB.java
Normal file
|
@ -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<String, ? extends Object> 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<String> columnList = new ArrayList<>();
|
||||
|
||||
private void doColumn(String name) {
|
||||
columnList.add(name);
|
||||
}
|
||||
|
||||
public void columnId() {
|
||||
doColumn("id");
|
||||
}
|
||||
|
||||
public void columnName() {
|
||||
doColumn("name");
|
||||
}
|
||||
}
|
||||
}
|
134
src/main/java/org/codelibs/fess/es/cbean/bs/BsRoleCB.java
Normal file
134
src/main/java/org/codelibs/fess/es/cbean/bs/BsRoleCB.java
Normal file
|
@ -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<String, ? extends Object> 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<String> columnList = new ArrayList<>();
|
||||
|
||||
private void doColumn(String name) {
|
||||
columnList.add(name);
|
||||
}
|
||||
|
||||
public void columnId() {
|
||||
doColumn("id");
|
||||
}
|
||||
|
||||
public void columnName() {
|
||||
doColumn("name");
|
||||
}
|
||||
}
|
||||
}
|
146
src/main/java/org/codelibs/fess/es/cbean/bs/BsUserCB.java
Normal file
146
src/main/java/org/codelibs/fess/es/cbean/bs/BsUserCB.java
Normal file
|
@ -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<String, ? extends Object> 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<String> columnList = new ArrayList<>();
|
||||
|
||||
private void doColumn(String name) {
|
||||
columnList.add(name);
|
||||
}
|
||||
|
||||
public void columnGroup() {
|
||||
doColumn("group");
|
||||
}
|
||||
|
||||
public void columnId() {
|
||||
doColumn("id");
|
||||
}
|
||||
|
||||
public void columnName() {
|
||||
doColumn("name");
|
||||
}
|
||||
|
||||
public void columnPassword() {
|
||||
doColumn("password");
|
||||
}
|
||||
|
||||
public void columnRole() {
|
||||
doColumn("role");
|
||||
}
|
||||
}
|
||||
}
|
|
@ -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 {
|
||||
}
|
9
src/main/java/org/codelibs/fess/es/cbean/cf/GroupCF.java
Normal file
9
src/main/java/org/codelibs/fess/es/cbean/cf/GroupCF.java
Normal file
|
@ -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 {
|
||||
}
|
9
src/main/java/org/codelibs/fess/es/cbean/cf/RoleCF.java
Normal file
9
src/main/java/org/codelibs/fess/es/cbean/cf/RoleCF.java
Normal file
|
@ -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 {
|
||||
}
|
9
src/main/java/org/codelibs/fess/es/cbean/cf/UserCF.java
Normal file
9
src/main/java/org/codelibs/fess/es/cbean/cf/UserCF.java
Normal file
|
@ -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 {
|
||||
}
|
855
src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsEventLogCF.java
Normal file
855
src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsEventLogCF.java
Normal file
|
@ -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<EventLogCF> boolLambda) {
|
||||
bool(boolLambda, null);
|
||||
}
|
||||
|
||||
public void bool(BoolCall<EventLogCF> boolLambda, ConditionOptionCall<BoolFilterBuilder> 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<EventLogCF> andLambda) {
|
||||
and(andLambda, null);
|
||||
}
|
||||
|
||||
public void and(OperatorCall<EventLogCF> andLambda, ConditionOptionCall<AndFilterBuilder> 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<EventLogCF> orLambda) {
|
||||
or(orLambda, null);
|
||||
}
|
||||
|
||||
public void or(OperatorCall<EventLogCF> orLambda, ConditionOptionCall<OrFilterBuilder> 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<EventLogCF> notLambda) {
|
||||
not(notLambda, null);
|
||||
}
|
||||
|
||||
public void not(OperatorCall<EventLogCF> notLambda, ConditionOptionCall<NotFilterBuilder> 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<EventLogCQ> queryLambda) {
|
||||
query(queryLambda, null);
|
||||
}
|
||||
|
||||
public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall<EventLogCQ> queryLambda,
|
||||
ConditionOptionCall<QueryFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setCreatedAt_Term(createdAt, opLambda);
|
||||
}
|
||||
|
||||
public void setCreatedAt_Term(LocalDateTime createdAt) {
|
||||
setCreatedAt_Term(createdAt, null);
|
||||
}
|
||||
|
||||
public void setCreatedAt_Term(LocalDateTime createdAt, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("createdAt", createdAt);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCreatedAt_Terms(Collection<LocalDateTime> createdAtList) {
|
||||
setCreatedAt_Terms(createdAtList, null);
|
||||
}
|
||||
|
||||
public void setCreatedAt_Terms(Collection<LocalDateTime> createdAtList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("createdAt", createdAtList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCreatedAt_InScope(Collection<LocalDateTime> createdAtList) {
|
||||
setCreatedAt_Terms(createdAtList, null);
|
||||
}
|
||||
|
||||
public void setCreatedAt_InScope(Collection<LocalDateTime> createdAtList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setCreatedAt_Terms(createdAtList, opLambda);
|
||||
}
|
||||
|
||||
public void setCreatedAt_Exists() {
|
||||
setCreatedAt_Exists(null);
|
||||
}
|
||||
|
||||
public void setCreatedAt_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("createdAt");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCreatedAt_Missing() {
|
||||
setCreatedAt_Missing(null);
|
||||
}
|
||||
|
||||
public void setCreatedAt_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setCreatedBy_Term(createdBy, opLambda);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Term(String createdBy) {
|
||||
setCreatedBy_Term(createdBy, null);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Term(String createdBy, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("createdBy", createdBy);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCreatedBy_Terms(Collection<String> createdByList) {
|
||||
setCreatedBy_Terms(createdByList, null);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Terms(Collection<String> createdByList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("createdBy", createdByList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCreatedBy_InScope(Collection<String> createdByList) {
|
||||
setCreatedBy_Terms(createdByList, null);
|
||||
}
|
||||
|
||||
public void setCreatedBy_InScope(Collection<String> createdByList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setCreatedBy_Terms(createdByList, opLambda);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Prefix(String createdBy) {
|
||||
setCreatedBy_Prefix(createdBy, null);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Prefix(String createdBy, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("createdBy", createdBy);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCreatedBy_Exists() {
|
||||
setCreatedBy_Exists(null);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("createdBy");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCreatedBy_Missing() {
|
||||
setCreatedBy_Missing(null);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setEventType_Term(eventType, opLambda);
|
||||
}
|
||||
|
||||
public void setEventType_Term(String eventType) {
|
||||
setEventType_Term(eventType, null);
|
||||
}
|
||||
|
||||
public void setEventType_Term(String eventType, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("eventType", eventType);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setEventType_Terms(Collection<String> eventTypeList) {
|
||||
setEventType_Terms(eventTypeList, null);
|
||||
}
|
||||
|
||||
public void setEventType_Terms(Collection<String> eventTypeList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("eventType", eventTypeList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setEventType_InScope(Collection<String> eventTypeList) {
|
||||
setEventType_Terms(eventTypeList, null);
|
||||
}
|
||||
|
||||
public void setEventType_InScope(Collection<String> eventTypeList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setEventType_Terms(eventTypeList, opLambda);
|
||||
}
|
||||
|
||||
public void setEventType_Prefix(String eventType) {
|
||||
setEventType_Prefix(eventType, null);
|
||||
}
|
||||
|
||||
public void setEventType_Prefix(String eventType, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("eventType", eventType);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setEventType_Exists() {
|
||||
setEventType_Exists(null);
|
||||
}
|
||||
|
||||
public void setEventType_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("eventType");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setEventType_Missing() {
|
||||
setEventType_Missing(null);
|
||||
}
|
||||
|
||||
public void setEventType_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setId_Term(id, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Term(String id) {
|
||||
setId_Term(id, null);
|
||||
}
|
||||
|
||||
public void setId_Term(String id, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("id", idList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setId_Terms(idList, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Prefix(String id) {
|
||||
setId_Prefix(id, null);
|
||||
}
|
||||
|
||||
public void setId_Prefix(String id, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Exists() {
|
||||
setId_Exists(null);
|
||||
}
|
||||
|
||||
public void setId_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("id");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Missing() {
|
||||
setId_Missing(null);
|
||||
}
|
||||
|
||||
public void setId_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setMessage_Term(message, opLambda);
|
||||
}
|
||||
|
||||
public void setMessage_Term(String message) {
|
||||
setMessage_Term(message, null);
|
||||
}
|
||||
|
||||
public void setMessage_Term(String message, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("message", message);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setMessage_Terms(Collection<String> messageList) {
|
||||
setMessage_Terms(messageList, null);
|
||||
}
|
||||
|
||||
public void setMessage_Terms(Collection<String> messageList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("message", messageList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setMessage_InScope(Collection<String> messageList) {
|
||||
setMessage_Terms(messageList, null);
|
||||
}
|
||||
|
||||
public void setMessage_InScope(Collection<String> messageList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setMessage_Terms(messageList, opLambda);
|
||||
}
|
||||
|
||||
public void setMessage_Prefix(String message) {
|
||||
setMessage_Prefix(message, null);
|
||||
}
|
||||
|
||||
public void setMessage_Prefix(String message, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("message", message);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setMessage_Exists() {
|
||||
setMessage_Exists(null);
|
||||
}
|
||||
|
||||
public void setMessage_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("message");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setMessage_Missing() {
|
||||
setMessage_Missing(null);
|
||||
}
|
||||
|
||||
public void setMessage_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setPath_Term(path, opLambda);
|
||||
}
|
||||
|
||||
public void setPath_Term(String path) {
|
||||
setPath_Term(path, null);
|
||||
}
|
||||
|
||||
public void setPath_Term(String path, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("path", path);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPath_Terms(Collection<String> pathList) {
|
||||
setPath_Terms(pathList, null);
|
||||
}
|
||||
|
||||
public void setPath_Terms(Collection<String> pathList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("path", pathList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPath_InScope(Collection<String> pathList) {
|
||||
setPath_Terms(pathList, null);
|
||||
}
|
||||
|
||||
public void setPath_InScope(Collection<String> pathList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setPath_Terms(pathList, opLambda);
|
||||
}
|
||||
|
||||
public void setPath_Prefix(String path) {
|
||||
setPath_Prefix(path, null);
|
||||
}
|
||||
|
||||
public void setPath_Prefix(String path, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("path", path);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPath_Exists() {
|
||||
setPath_Exists(null);
|
||||
}
|
||||
|
||||
public void setPath_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("path");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPath_Missing() {
|
||||
setPath_Missing(null);
|
||||
}
|
||||
|
||||
public void setPath_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("path", ConditionKey.CK_LESS_EQUAL, path);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
361
src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsGroupCF.java
Normal file
361
src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsGroupCF.java
Normal file
|
@ -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<GroupCF> boolLambda) {
|
||||
bool(boolLambda, null);
|
||||
}
|
||||
|
||||
public void bool(BoolCall<GroupCF> boolLambda, ConditionOptionCall<BoolFilterBuilder> 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<GroupCF> andLambda) {
|
||||
and(andLambda, null);
|
||||
}
|
||||
|
||||
public void and(OperatorCall<GroupCF> andLambda, ConditionOptionCall<AndFilterBuilder> 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<GroupCF> orLambda) {
|
||||
or(orLambda, null);
|
||||
}
|
||||
|
||||
public void or(OperatorCall<GroupCF> orLambda, ConditionOptionCall<OrFilterBuilder> 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<GroupCF> notLambda) {
|
||||
not(notLambda, null);
|
||||
}
|
||||
|
||||
public void not(OperatorCall<GroupCF> notLambda, ConditionOptionCall<NotFilterBuilder> 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<GroupCQ> queryLambda) {
|
||||
query(queryLambda, null);
|
||||
}
|
||||
|
||||
public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall<GroupCQ> queryLambda,
|
||||
ConditionOptionCall<QueryFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setId_Term(id, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Term(String id) {
|
||||
setId_Term(id, null);
|
||||
}
|
||||
|
||||
public void setId_Term(String id, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("id", idList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setId_Terms(idList, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Prefix(String id) {
|
||||
setId_Prefix(id, null);
|
||||
}
|
||||
|
||||
public void setId_Prefix(String id, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Exists() {
|
||||
setId_Exists(null);
|
||||
}
|
||||
|
||||
public void setId_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("id");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Missing() {
|
||||
setId_Missing(null);
|
||||
}
|
||||
|
||||
public void setId_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setName_Term(name, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Term(String name) {
|
||||
setName_Term(name, null);
|
||||
}
|
||||
|
||||
public void setName_Term(String name, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("name", name);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("name", nameList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setName_Terms(nameList, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Prefix(String name) {
|
||||
setName_Prefix(name, null);
|
||||
}
|
||||
|
||||
public void setName_Prefix(String name, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("name", name);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Exists() {
|
||||
setName_Exists(null);
|
||||
}
|
||||
|
||||
public void setName_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("name");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Missing() {
|
||||
setName_Missing(null);
|
||||
}
|
||||
|
||||
public void setName_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_LESS_EQUAL, name);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
361
src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRoleCF.java
Normal file
361
src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsRoleCF.java
Normal file
|
@ -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<RoleCF> boolLambda) {
|
||||
bool(boolLambda, null);
|
||||
}
|
||||
|
||||
public void bool(BoolCall<RoleCF> boolLambda, ConditionOptionCall<BoolFilterBuilder> 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<RoleCF> andLambda) {
|
||||
and(andLambda, null);
|
||||
}
|
||||
|
||||
public void and(OperatorCall<RoleCF> andLambda, ConditionOptionCall<AndFilterBuilder> 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<RoleCF> orLambda) {
|
||||
or(orLambda, null);
|
||||
}
|
||||
|
||||
public void or(OperatorCall<RoleCF> orLambda, ConditionOptionCall<OrFilterBuilder> 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<RoleCF> notLambda) {
|
||||
not(notLambda, null);
|
||||
}
|
||||
|
||||
public void not(OperatorCall<RoleCF> notLambda, ConditionOptionCall<NotFilterBuilder> 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<RoleCQ> queryLambda) {
|
||||
query(queryLambda, null);
|
||||
}
|
||||
|
||||
public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall<RoleCQ> queryLambda,
|
||||
ConditionOptionCall<QueryFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setId_Term(id, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Term(String id) {
|
||||
setId_Term(id, null);
|
||||
}
|
||||
|
||||
public void setId_Term(String id, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("id", idList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setId_Terms(idList, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Prefix(String id) {
|
||||
setId_Prefix(id, null);
|
||||
}
|
||||
|
||||
public void setId_Prefix(String id, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Exists() {
|
||||
setId_Exists(null);
|
||||
}
|
||||
|
||||
public void setId_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("id");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Missing() {
|
||||
setId_Missing(null);
|
||||
}
|
||||
|
||||
public void setId_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setName_Term(name, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Term(String name) {
|
||||
setName_Term(name, null);
|
||||
}
|
||||
|
||||
public void setName_Term(String name, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("name", name);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("name", nameList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setName_Terms(nameList, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Prefix(String name) {
|
||||
setName_Prefix(name, null);
|
||||
}
|
||||
|
||||
public void setName_Prefix(String name, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("name", name);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Exists() {
|
||||
setName_Exists(null);
|
||||
}
|
||||
|
||||
public void setName_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("name");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Missing() {
|
||||
setName_Missing(null);
|
||||
}
|
||||
|
||||
public void setName_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("name", ConditionKey.CK_LESS_EQUAL, name);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
739
src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsUserCF.java
Normal file
739
src/main/java/org/codelibs/fess/es/cbean/cf/bs/BsUserCF.java
Normal file
|
@ -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<UserCF> boolLambda) {
|
||||
bool(boolLambda, null);
|
||||
}
|
||||
|
||||
public void bool(BoolCall<UserCF> boolLambda, ConditionOptionCall<BoolFilterBuilder> 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<UserCF> andLambda) {
|
||||
and(andLambda, null);
|
||||
}
|
||||
|
||||
public void and(OperatorCall<UserCF> andLambda, ConditionOptionCall<AndFilterBuilder> 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<UserCF> orLambda) {
|
||||
or(orLambda, null);
|
||||
}
|
||||
|
||||
public void or(OperatorCall<UserCF> orLambda, ConditionOptionCall<OrFilterBuilder> 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<UserCF> notLambda) {
|
||||
not(notLambda, null);
|
||||
}
|
||||
|
||||
public void not(OperatorCall<UserCF> notLambda, ConditionOptionCall<NotFilterBuilder> 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<UserCQ> queryLambda) {
|
||||
query(queryLambda, null);
|
||||
}
|
||||
|
||||
public void query(org.codelibs.fess.es.cbean.cq.bs.AbstractConditionQuery.OperatorCall<UserCQ> queryLambda,
|
||||
ConditionOptionCall<QueryFilterBuilder> opLambda) {
|
||||
UserCQ query = new UserCQ();
|
||||
queryLambda.callback(query);
|
||||
if (query.hasQueries()) {
|
||||
QueryFilterBuilder builder = regQueryF(query.getQuery());
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_NotEqual(String group) {
|
||||
setGroup_NotEqual(group, null, null);
|
||||
}
|
||||
|
||||
public void setGroup_NotEqual(String group, ConditionOptionCall<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> eqOpLambda) {
|
||||
not(subCf -> {
|
||||
subCf.setGroup_Equal(group, eqOpLambda);
|
||||
}, notOpLambda);
|
||||
}
|
||||
|
||||
public void setGroup_Equal(String group) {
|
||||
setGroup_Term(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_Equal(String group, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
setGroup_Term(group, opLambda);
|
||||
}
|
||||
|
||||
public void setGroup_Term(String group) {
|
||||
setGroup_Term(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_Term(String group, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("group", group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_Terms(Collection<String> groupList) {
|
||||
setGroup_Terms(groupList, null);
|
||||
}
|
||||
|
||||
public void setGroup_Terms(Collection<String> groupList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("group", groupList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_InScope(Collection<String> groupList) {
|
||||
setGroup_Terms(groupList, null);
|
||||
}
|
||||
|
||||
public void setGroup_InScope(Collection<String> groupList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setGroup_Terms(groupList, opLambda);
|
||||
}
|
||||
|
||||
public void setGroup_Prefix(String group) {
|
||||
setGroup_Prefix(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_Prefix(String group, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("group", group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_Exists() {
|
||||
setGroup_Exists(null);
|
||||
}
|
||||
|
||||
public void setGroup_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("group");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_Missing() {
|
||||
setGroup_Missing(null);
|
||||
}
|
||||
|
||||
public void setGroup_Missing(ConditionOptionCall<MissingFilterBuilder> opLambda) {
|
||||
MissingFilterBuilder builder = regMissingF("group");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_GreaterThan(String group) {
|
||||
setGroup_GreaterThan(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_GreaterThan(String group, ConditionOptionCall<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("group", ConditionKey.CK_GREATER_THAN, group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_LessThan(String group) {
|
||||
setGroup_LessThan(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_LessThan(String group, ConditionOptionCall<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("group", ConditionKey.CK_LESS_THAN, group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_GreaterEqual(String group) {
|
||||
setGroup_GreaterEqual(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_GreaterEqual(String group, ConditionOptionCall<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("group", ConditionKey.CK_GREATER_EQUAL, group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_LessEqual(String group) {
|
||||
setGroup_LessEqual(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_LessEqual(String group, ConditionOptionCall<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("group", ConditionKey.CK_LESS_EQUAL, group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_NotEqual(String id) {
|
||||
setId_NotEqual(id, null, null);
|
||||
}
|
||||
|
||||
public void setId_NotEqual(String id, ConditionOptionCall<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setId_Term(id, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Term(String id) {
|
||||
setId_Term(id, null);
|
||||
}
|
||||
|
||||
public void setId_Term(String id, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("id", idList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setId_Terms(idList, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Prefix(String id) {
|
||||
setId_Prefix(id, null);
|
||||
}
|
||||
|
||||
public void setId_Prefix(String id, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Exists() {
|
||||
setId_Exists(null);
|
||||
}
|
||||
|
||||
public void setId_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("id");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Missing() {
|
||||
setId_Missing(null);
|
||||
}
|
||||
|
||||
public void setId_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setName_Term(name, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Term(String name) {
|
||||
setName_Term(name, null);
|
||||
}
|
||||
|
||||
public void setName_Term(String name, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("name", name);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("name", nameList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setName_Terms(nameList, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Prefix(String name) {
|
||||
setName_Prefix(name, null);
|
||||
}
|
||||
|
||||
public void setName_Prefix(String name, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("name", name);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Exists() {
|
||||
setName_Exists(null);
|
||||
}
|
||||
|
||||
public void setName_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("name");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Missing() {
|
||||
setName_Missing(null);
|
||||
}
|
||||
|
||||
public void setName_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> 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<TermFilterBuilder> opLambda) {
|
||||
setPassword_Term(password, opLambda);
|
||||
}
|
||||
|
||||
public void setPassword_Term(String password) {
|
||||
setPassword_Term(password, null);
|
||||
}
|
||||
|
||||
public void setPassword_Term(String password, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("password", password);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPassword_Terms(Collection<String> passwordList) {
|
||||
setPassword_Terms(passwordList, null);
|
||||
}
|
||||
|
||||
public void setPassword_Terms(Collection<String> passwordList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("password", passwordList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPassword_InScope(Collection<String> passwordList) {
|
||||
setPassword_Terms(passwordList, null);
|
||||
}
|
||||
|
||||
public void setPassword_InScope(Collection<String> passwordList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setPassword_Terms(passwordList, opLambda);
|
||||
}
|
||||
|
||||
public void setPassword_Prefix(String password) {
|
||||
setPassword_Prefix(password, null);
|
||||
}
|
||||
|
||||
public void setPassword_Prefix(String password, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("password", password);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPassword_Exists() {
|
||||
setPassword_Exists(null);
|
||||
}
|
||||
|
||||
public void setPassword_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("password");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPassword_Missing() {
|
||||
setPassword_Missing(null);
|
||||
}
|
||||
|
||||
public void setPassword_Missing(ConditionOptionCall<MissingFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> 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<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("password", ConditionKey.CK_LESS_EQUAL, password);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_NotEqual(String role) {
|
||||
setRole_NotEqual(role, null, null);
|
||||
}
|
||||
|
||||
public void setRole_NotEqual(String role, ConditionOptionCall<NotFilterBuilder> notOpLambda,
|
||||
ConditionOptionCall<TermFilterBuilder> eqOpLambda) {
|
||||
not(subCf -> {
|
||||
subCf.setRole_Equal(role, eqOpLambda);
|
||||
}, notOpLambda);
|
||||
}
|
||||
|
||||
public void setRole_Equal(String role) {
|
||||
setRole_Term(role, null);
|
||||
}
|
||||
|
||||
public void setRole_Equal(String role, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
setRole_Term(role, opLambda);
|
||||
}
|
||||
|
||||
public void setRole_Term(String role) {
|
||||
setRole_Term(role, null);
|
||||
}
|
||||
|
||||
public void setRole_Term(String role, ConditionOptionCall<TermFilterBuilder> opLambda) {
|
||||
TermFilterBuilder builder = regTermF("role", role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_Terms(Collection<String> roleList) {
|
||||
setRole_Terms(roleList, null);
|
||||
}
|
||||
|
||||
public void setRole_Terms(Collection<String> roleList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
TermsFilterBuilder builder = regTermsF("role", roleList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_InScope(Collection<String> roleList) {
|
||||
setRole_Terms(roleList, null);
|
||||
}
|
||||
|
||||
public void setRole_InScope(Collection<String> roleList, ConditionOptionCall<TermsFilterBuilder> opLambda) {
|
||||
setRole_Terms(roleList, opLambda);
|
||||
}
|
||||
|
||||
public void setRole_Prefix(String role) {
|
||||
setRole_Prefix(role, null);
|
||||
}
|
||||
|
||||
public void setRole_Prefix(String role, ConditionOptionCall<PrefixFilterBuilder> opLambda) {
|
||||
PrefixFilterBuilder builder = regPrefixF("role", role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_Exists() {
|
||||
setRole_Exists(null);
|
||||
}
|
||||
|
||||
public void setRole_Exists(ConditionOptionCall<ExistsFilterBuilder> opLambda) {
|
||||
ExistsFilterBuilder builder = regExistsF("role");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_Missing() {
|
||||
setRole_Missing(null);
|
||||
}
|
||||
|
||||
public void setRole_Missing(ConditionOptionCall<MissingFilterBuilder> opLambda) {
|
||||
MissingFilterBuilder builder = regMissingF("role");
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_GreaterThan(String role) {
|
||||
setRole_GreaterThan(role, null);
|
||||
}
|
||||
|
||||
public void setRole_GreaterThan(String role, ConditionOptionCall<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("role", ConditionKey.CK_GREATER_THAN, role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_LessThan(String role) {
|
||||
setRole_LessThan(role, null);
|
||||
}
|
||||
|
||||
public void setRole_LessThan(String role, ConditionOptionCall<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("role", ConditionKey.CK_LESS_THAN, role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_GreaterEqual(String role) {
|
||||
setRole_GreaterEqual(role, null);
|
||||
}
|
||||
|
||||
public void setRole_GreaterEqual(String role, ConditionOptionCall<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("role", ConditionKey.CK_GREATER_EQUAL, role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_LessEqual(String role) {
|
||||
setRole_LessEqual(role, null);
|
||||
}
|
||||
|
||||
public void setRole_LessEqual(String role, ConditionOptionCall<RangeFilterBuilder> opLambda) {
|
||||
RangeFilterBuilder builder = regRangeF("role", ConditionKey.CK_LESS_EQUAL, role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
|
@ -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 {
|
||||
}
|
9
src/main/java/org/codelibs/fess/es/cbean/cq/GroupCQ.java
Normal file
9
src/main/java/org/codelibs/fess/es/cbean/cq/GroupCQ.java
Normal file
|
@ -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 {
|
||||
}
|
9
src/main/java/org/codelibs/fess/es/cbean/cq/RoleCQ.java
Normal file
9
src/main/java/org/codelibs/fess/es/cbean/cq/RoleCQ.java
Normal file
|
@ -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 {
|
||||
}
|
9
src/main/java/org/codelibs/fess/es/cbean/cq/UserCQ.java
Normal file
9
src/main/java/org/codelibs/fess/es/cbean/cq/UserCQ.java
Normal file
|
@ -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 {
|
||||
}
|
937
src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsEventLogCQ.java
Normal file
937
src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsEventLogCQ.java
Normal file
|
@ -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<EventLogCQ, EventLogCF> filteredLambda) {
|
||||
filtered(filteredLambda, null);
|
||||
}
|
||||
|
||||
public void filtered(FilteredCall<EventLogCQ, EventLogCF> filteredLambda, ConditionOptionCall<FilteredQueryBuilder> 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<EventLogCQ> boolLambda) {
|
||||
bool(boolLambda, null);
|
||||
}
|
||||
|
||||
public void bool(BoolCall<EventLogCQ> boolLambda, ConditionOptionCall<BoolQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setCreatedAt_Term(createdAt, opLambda);
|
||||
}
|
||||
|
||||
public void setCreatedAt_Term(LocalDateTime createdAt) {
|
||||
setCreatedAt_Term(createdAt, null);
|
||||
}
|
||||
|
||||
public void setCreatedAt_Term(LocalDateTime createdAt, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("createdAt", createdAt);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCreatedAt_Terms(Collection<LocalDateTime> createdAtList) {
|
||||
setCreatedAt_Terms(createdAtList, null);
|
||||
}
|
||||
|
||||
public void setCreatedAt_Terms(Collection<LocalDateTime> createdAtList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("createdAt", createdAtList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCreatedAt_InScope(Collection<LocalDateTime> createdAtList) {
|
||||
setCreatedAt_Terms(createdAtList, null);
|
||||
}
|
||||
|
||||
public void setCreatedAt_InScope(Collection<LocalDateTime> createdAtList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setCreatedAt_Terms(createdAtList, opLambda);
|
||||
}
|
||||
|
||||
public void setCreatedAt_Match(LocalDateTime createdAt) {
|
||||
setCreatedAt_Match(createdAt, null);
|
||||
}
|
||||
|
||||
public void setCreatedAt_Match(LocalDateTime createdAt, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setCreatedBy_Term(createdBy, opLambda);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Term(String createdBy) {
|
||||
setCreatedBy_Term(createdBy, null);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Term(String createdBy, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("createdBy", createdBy);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCreatedBy_Terms(Collection<String> createdByList) {
|
||||
setCreatedBy_Terms(createdByList, null);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Terms(Collection<String> createdByList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("createdBy", createdByList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCreatedBy_InScope(Collection<String> createdByList) {
|
||||
setCreatedBy_Terms(createdByList, null);
|
||||
}
|
||||
|
||||
public void setCreatedBy_InScope(Collection<String> createdByList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setCreatedBy_Terms(createdByList, opLambda);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Match(String createdBy) {
|
||||
setCreatedBy_Match(createdBy, null);
|
||||
}
|
||||
|
||||
public void setCreatedBy_Match(String createdBy, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setEventType_Term(eventType, opLambda);
|
||||
}
|
||||
|
||||
public void setEventType_Term(String eventType) {
|
||||
setEventType_Term(eventType, null);
|
||||
}
|
||||
|
||||
public void setEventType_Term(String eventType, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("eventType", eventType);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setEventType_Terms(Collection<String> eventTypeList) {
|
||||
setEventType_Terms(eventTypeList, null);
|
||||
}
|
||||
|
||||
public void setEventType_Terms(Collection<String> eventTypeList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("eventType", eventTypeList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setEventType_InScope(Collection<String> eventTypeList) {
|
||||
setEventType_Terms(eventTypeList, null);
|
||||
}
|
||||
|
||||
public void setEventType_InScope(Collection<String> eventTypeList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setEventType_Terms(eventTypeList, opLambda);
|
||||
}
|
||||
|
||||
public void setEventType_Match(String eventType) {
|
||||
setEventType_Match(eventType, null);
|
||||
}
|
||||
|
||||
public void setEventType_Match(String eventType, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setId_Term(id, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Term(String id) {
|
||||
setId_Term(id, null);
|
||||
}
|
||||
|
||||
public void setId_Term(String id, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("id", idList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setId_Terms(idList, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Match(String id) {
|
||||
setId_Match(id, null);
|
||||
}
|
||||
|
||||
public void setId_Match(String id, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setMessage_Term(message, opLambda);
|
||||
}
|
||||
|
||||
public void setMessage_Term(String message) {
|
||||
setMessage_Term(message, null);
|
||||
}
|
||||
|
||||
public void setMessage_Term(String message, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("message", message);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setMessage_Terms(Collection<String> messageList) {
|
||||
setMessage_Terms(messageList, null);
|
||||
}
|
||||
|
||||
public void setMessage_Terms(Collection<String> messageList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("message", messageList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setMessage_InScope(Collection<String> messageList) {
|
||||
setMessage_Terms(messageList, null);
|
||||
}
|
||||
|
||||
public void setMessage_InScope(Collection<String> messageList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setMessage_Terms(messageList, opLambda);
|
||||
}
|
||||
|
||||
public void setMessage_Match(String message) {
|
||||
setMessage_Match(message, null);
|
||||
}
|
||||
|
||||
public void setMessage_Match(String message, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setPath_Term(path, opLambda);
|
||||
}
|
||||
|
||||
public void setPath_Term(String path) {
|
||||
setPath_Term(path, null);
|
||||
}
|
||||
|
||||
public void setPath_Term(String path, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("path", path);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPath_Terms(Collection<String> pathList) {
|
||||
setPath_Terms(pathList, null);
|
||||
}
|
||||
|
||||
public void setPath_Terms(Collection<String> pathList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("path", pathList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPath_InScope(Collection<String> pathList) {
|
||||
setPath_Terms(pathList, null);
|
||||
}
|
||||
|
||||
public void setPath_InScope(Collection<String> pathList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setPath_Terms(pathList, opLambda);
|
||||
}
|
||||
|
||||
public void setPath_Match(String path) {
|
||||
setPath_Match(path, null);
|
||||
}
|
||||
|
||||
public void setPath_Match(String path, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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;
|
||||
}
|
||||
|
||||
}
|
359
src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsGroupCQ.java
Normal file
359
src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsGroupCQ.java
Normal file
|
@ -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<GroupCQ, GroupCF> filteredLambda) {
|
||||
filtered(filteredLambda, null);
|
||||
}
|
||||
|
||||
public void filtered(FilteredCall<GroupCQ, GroupCF> filteredLambda, ConditionOptionCall<FilteredQueryBuilder> 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<GroupCQ> boolLambda) {
|
||||
bool(boolLambda, null);
|
||||
}
|
||||
|
||||
public void bool(BoolCall<GroupCQ> boolLambda, ConditionOptionCall<BoolQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setId_Term(id, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Term(String id) {
|
||||
setId_Term(id, null);
|
||||
}
|
||||
|
||||
public void setId_Term(String id, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("id", idList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setId_Terms(idList, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Match(String id) {
|
||||
setId_Match(id, null);
|
||||
}
|
||||
|
||||
public void setId_Match(String id, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setName_Term(name, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Term(String name) {
|
||||
setName_Term(name, null);
|
||||
}
|
||||
|
||||
public void setName_Term(String name, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("name", name);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("name", nameList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setName_Terms(nameList, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Match(String name) {
|
||||
setName_Match(name, null);
|
||||
}
|
||||
|
||||
public void setName_Match(String name, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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;
|
||||
}
|
||||
|
||||
}
|
359
src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRoleCQ.java
Normal file
359
src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsRoleCQ.java
Normal file
|
@ -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<RoleCQ, RoleCF> filteredLambda) {
|
||||
filtered(filteredLambda, null);
|
||||
}
|
||||
|
||||
public void filtered(FilteredCall<RoleCQ, RoleCF> filteredLambda, ConditionOptionCall<FilteredQueryBuilder> 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<RoleCQ> boolLambda) {
|
||||
bool(boolLambda, null);
|
||||
}
|
||||
|
||||
public void bool(BoolCall<RoleCQ> boolLambda, ConditionOptionCall<BoolQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setId_Term(id, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Term(String id) {
|
||||
setId_Term(id, null);
|
||||
}
|
||||
|
||||
public void setId_Term(String id, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("id", idList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setId_Terms(idList, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Match(String id) {
|
||||
setId_Match(id, null);
|
||||
}
|
||||
|
||||
public void setId_Match(String id, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setName_Term(name, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Term(String name) {
|
||||
setName_Term(name, null);
|
||||
}
|
||||
|
||||
public void setName_Term(String name, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("name", name);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("name", nameList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setName_Terms(nameList, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Match(String name) {
|
||||
setName_Match(name, null);
|
||||
}
|
||||
|
||||
public void setName_Match(String name, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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;
|
||||
}
|
||||
|
||||
}
|
800
src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsUserCQ.java
Normal file
800
src/main/java/org/codelibs/fess/es/cbean/cq/bs/BsUserCQ.java
Normal file
|
@ -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<UserCQ, UserCF> filteredLambda) {
|
||||
filtered(filteredLambda, null);
|
||||
}
|
||||
|
||||
public void filtered(FilteredCall<UserCQ, UserCF> filteredLambda, ConditionOptionCall<FilteredQueryBuilder> 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<UserCQ> boolLambda) {
|
||||
bool(boolLambda, null);
|
||||
}
|
||||
|
||||
public void bool(BoolCall<UserCQ> boolLambda, ConditionOptionCall<BoolQueryBuilder> 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 setGroup_Equal(String group) {
|
||||
setGroup_Term(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_Equal(String group, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
setGroup_Term(group, opLambda);
|
||||
}
|
||||
|
||||
public void setGroup_Term(String group) {
|
||||
setGroup_Term(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_Term(String group, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("group", group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_Terms(Collection<String> groupList) {
|
||||
setGroup_Terms(groupList, null);
|
||||
}
|
||||
|
||||
public void setGroup_Terms(Collection<String> groupList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("group", groupList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_InScope(Collection<String> groupList) {
|
||||
setGroup_Terms(groupList, null);
|
||||
}
|
||||
|
||||
public void setGroup_InScope(Collection<String> groupList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setGroup_Terms(groupList, opLambda);
|
||||
}
|
||||
|
||||
public void setGroup_Match(String group) {
|
||||
setGroup_Match(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_Match(String group, ConditionOptionCall<MatchQueryBuilder> opLambda) {
|
||||
MatchQueryBuilder builder = regMatchQ("group", group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_MatchPhrase(String group) {
|
||||
setGroup_MatchPhrase(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_MatchPhrase(String group, ConditionOptionCall<MatchQueryBuilder> opLambda) {
|
||||
MatchQueryBuilder builder = regMatchPhraseQ("group", group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_MatchPhrasePrefix(String group) {
|
||||
setGroup_MatchPhrasePrefix(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_MatchPhrasePrefix(String group, ConditionOptionCall<MatchQueryBuilder> opLambda) {
|
||||
MatchQueryBuilder builder = regMatchPhrasePrefixQ("group", group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_Fuzzy(String group) {
|
||||
setGroup_Fuzzy(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_Fuzzy(String group, ConditionOptionCall<FuzzyQueryBuilder> opLambda) {
|
||||
FuzzyQueryBuilder builder = regFuzzyQ("group", group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_Prefix(String group) {
|
||||
setGroup_Prefix(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_Prefix(String group, ConditionOptionCall<PrefixQueryBuilder> opLambda) {
|
||||
PrefixQueryBuilder builder = regPrefixQ("group", group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_GreaterThan(String group) {
|
||||
setGroup_GreaterThan(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_GreaterThan(String group, ConditionOptionCall<RangeQueryBuilder> opLambda) {
|
||||
RangeQueryBuilder builder = regRangeQ("group", ConditionKey.CK_GREATER_THAN, group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_LessThan(String group) {
|
||||
setGroup_LessThan(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_LessThan(String group, ConditionOptionCall<RangeQueryBuilder> opLambda) {
|
||||
RangeQueryBuilder builder = regRangeQ("group", ConditionKey.CK_LESS_THAN, group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_GreaterEqual(String group) {
|
||||
setGroup_GreaterEqual(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_GreaterEqual(String group, ConditionOptionCall<RangeQueryBuilder> opLambda) {
|
||||
RangeQueryBuilder builder = regRangeQ("group", ConditionKey.CK_GREATER_EQUAL, group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setGroup_LessEqual(String group) {
|
||||
setGroup_LessEqual(group, null);
|
||||
}
|
||||
|
||||
public void setGroup_LessEqual(String group, ConditionOptionCall<RangeQueryBuilder> opLambda) {
|
||||
RangeQueryBuilder builder = regRangeQ("group", ConditionKey.CK_LESS_EQUAL, group);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public BsUserCQ addOrderBy_Group_Asc() {
|
||||
regOBA("group");
|
||||
return this;
|
||||
}
|
||||
|
||||
public BsUserCQ addOrderBy_Group_Desc() {
|
||||
regOBD("group");
|
||||
return this;
|
||||
}
|
||||
|
||||
public void setId_Equal(String id) {
|
||||
setId_Term(id, null);
|
||||
}
|
||||
|
||||
public void setId_Equal(String id, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
setId_Term(id, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Term(String id) {
|
||||
setId_Term(id, null);
|
||||
}
|
||||
|
||||
public void setId_Term(String id, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("id", id);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_Terms(Collection<String> idList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("id", idList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList) {
|
||||
setId_Terms(idList, null);
|
||||
}
|
||||
|
||||
public void setId_InScope(Collection<String> idList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setId_Terms(idList, opLambda);
|
||||
}
|
||||
|
||||
public void setId_Match(String id) {
|
||||
setId_Match(id, null);
|
||||
}
|
||||
|
||||
public void setId_Match(String id, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setName_Term(name, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Term(String name) {
|
||||
setName_Term(name, null);
|
||||
}
|
||||
|
||||
public void setName_Term(String name, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("name", name);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_Terms(Collection<String> nameList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("name", nameList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList) {
|
||||
setName_Terms(nameList, null);
|
||||
}
|
||||
|
||||
public void setName_InScope(Collection<String> nameList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setName_Terms(nameList, opLambda);
|
||||
}
|
||||
|
||||
public void setName_Match(String name) {
|
||||
setName_Match(name, null);
|
||||
}
|
||||
|
||||
public void setName_Match(String name, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<TermQueryBuilder> opLambda) {
|
||||
setPassword_Term(password, opLambda);
|
||||
}
|
||||
|
||||
public void setPassword_Term(String password) {
|
||||
setPassword_Term(password, null);
|
||||
}
|
||||
|
||||
public void setPassword_Term(String password, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("password", password);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPassword_Terms(Collection<String> passwordList) {
|
||||
setPassword_Terms(passwordList, null);
|
||||
}
|
||||
|
||||
public void setPassword_Terms(Collection<String> passwordList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("password", passwordList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setPassword_InScope(Collection<String> passwordList) {
|
||||
setPassword_Terms(passwordList, null);
|
||||
}
|
||||
|
||||
public void setPassword_InScope(Collection<String> passwordList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setPassword_Terms(passwordList, opLambda);
|
||||
}
|
||||
|
||||
public void setPassword_Match(String password) {
|
||||
setPassword_Match(password, null);
|
||||
}
|
||||
|
||||
public void setPassword_Match(String password, ConditionOptionCall<MatchQueryBuilder> 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<MatchQueryBuilder> 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<MatchQueryBuilder> 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<FuzzyQueryBuilder> 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<PrefixQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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<RangeQueryBuilder> 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 setRole_Equal(String role) {
|
||||
setRole_Term(role, null);
|
||||
}
|
||||
|
||||
public void setRole_Equal(String role, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
setRole_Term(role, opLambda);
|
||||
}
|
||||
|
||||
public void setRole_Term(String role) {
|
||||
setRole_Term(role, null);
|
||||
}
|
||||
|
||||
public void setRole_Term(String role, ConditionOptionCall<TermQueryBuilder> opLambda) {
|
||||
TermQueryBuilder builder = regTermQ("role", role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_Terms(Collection<String> roleList) {
|
||||
setRole_Terms(roleList, null);
|
||||
}
|
||||
|
||||
public void setRole_Terms(Collection<String> roleList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
TermsQueryBuilder builder = regTermsQ("role", roleList);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_InScope(Collection<String> roleList) {
|
||||
setRole_Terms(roleList, null);
|
||||
}
|
||||
|
||||
public void setRole_InScope(Collection<String> roleList, ConditionOptionCall<TermsQueryBuilder> opLambda) {
|
||||
setRole_Terms(roleList, opLambda);
|
||||
}
|
||||
|
||||
public void setRole_Match(String role) {
|
||||
setRole_Match(role, null);
|
||||
}
|
||||
|
||||
public void setRole_Match(String role, ConditionOptionCall<MatchQueryBuilder> opLambda) {
|
||||
MatchQueryBuilder builder = regMatchQ("role", role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_MatchPhrase(String role) {
|
||||
setRole_MatchPhrase(role, null);
|
||||
}
|
||||
|
||||
public void setRole_MatchPhrase(String role, ConditionOptionCall<MatchQueryBuilder> opLambda) {
|
||||
MatchQueryBuilder builder = regMatchPhraseQ("role", role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_MatchPhrasePrefix(String role) {
|
||||
setRole_MatchPhrasePrefix(role, null);
|
||||
}
|
||||
|
||||
public void setRole_MatchPhrasePrefix(String role, ConditionOptionCall<MatchQueryBuilder> opLambda) {
|
||||
MatchQueryBuilder builder = regMatchPhrasePrefixQ("role", role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_Fuzzy(String role) {
|
||||
setRole_Fuzzy(role, null);
|
||||
}
|
||||
|
||||
public void setRole_Fuzzy(String role, ConditionOptionCall<FuzzyQueryBuilder> opLambda) {
|
||||
FuzzyQueryBuilder builder = regFuzzyQ("role", role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_Prefix(String role) {
|
||||
setRole_Prefix(role, null);
|
||||
}
|
||||
|
||||
public void setRole_Prefix(String role, ConditionOptionCall<PrefixQueryBuilder> opLambda) {
|
||||
PrefixQueryBuilder builder = regPrefixQ("role", role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_GreaterThan(String role) {
|
||||
setRole_GreaterThan(role, null);
|
||||
}
|
||||
|
||||
public void setRole_GreaterThan(String role, ConditionOptionCall<RangeQueryBuilder> opLambda) {
|
||||
RangeQueryBuilder builder = regRangeQ("role", ConditionKey.CK_GREATER_THAN, role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_LessThan(String role) {
|
||||
setRole_LessThan(role, null);
|
||||
}
|
||||
|
||||
public void setRole_LessThan(String role, ConditionOptionCall<RangeQueryBuilder> opLambda) {
|
||||
RangeQueryBuilder builder = regRangeQ("role", ConditionKey.CK_LESS_THAN, role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_GreaterEqual(String role) {
|
||||
setRole_GreaterEqual(role, null);
|
||||
}
|
||||
|
||||
public void setRole_GreaterEqual(String role, ConditionOptionCall<RangeQueryBuilder> opLambda) {
|
||||
RangeQueryBuilder builder = regRangeQ("role", ConditionKey.CK_GREATER_EQUAL, role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public void setRole_LessEqual(String role) {
|
||||
setRole_LessEqual(role, null);
|
||||
}
|
||||
|
||||
public void setRole_LessEqual(String role, ConditionOptionCall<RangeQueryBuilder> opLambda) {
|
||||
RangeQueryBuilder builder = regRangeQ("role", ConditionKey.CK_LESS_EQUAL, role);
|
||||
if (opLambda != null) {
|
||||
opLambda.callback(builder);
|
||||
}
|
||||
}
|
||||
|
||||
public BsUserCQ addOrderBy_Role_Asc() {
|
||||
regOBA("role");
|
||||
return this;
|
||||
}
|
||||
|
||||
public BsUserCQ addOrderBy_Role_Desc() {
|
||||
regOBD("role");
|
||||
return this;
|
||||
}
|
||||
|
||||
}
|
10
src/main/java/org/codelibs/fess/es/exbhv/EventLogBhv.java
Normal file
10
src/main/java/org/codelibs/fess/es/exbhv/EventLogBhv.java
Normal file
|
@ -0,0 +1,10 @@
|
|||
package org.codelibs.fess.es.exbhv;
|
||||
|
||||
import org.codelibs.fess.es.bsbhv.BsEventLogBhv;
|
||||
|
||||
/**
|
||||
* @author FreeGen
|
||||
*/
|
||||
public class EventLogBhv extends BsEventLogBhv {
|
||||
|
||||
}
|
10
src/main/java/org/codelibs/fess/es/exbhv/GroupBhv.java
Normal file
10
src/main/java/org/codelibs/fess/es/exbhv/GroupBhv.java
Normal file
|
@ -0,0 +1,10 @@
|
|||
package org.codelibs.fess.es.exbhv;
|
||||
|
||||
import org.codelibs.fess.es.bsbhv.BsGroupBhv;
|
||||
|
||||
/**
|
||||
* @author FreeGen
|
||||
*/
|
||||
public class GroupBhv extends BsGroupBhv {
|
||||
|
||||
}
|
10
src/main/java/org/codelibs/fess/es/exbhv/RoleBhv.java
Normal file
10
src/main/java/org/codelibs/fess/es/exbhv/RoleBhv.java
Normal file
|
@ -0,0 +1,10 @@
|
|||
package org.codelibs.fess.es.exbhv;
|
||||
|
||||
import org.codelibs.fess.es.bsbhv.BsRoleBhv;
|
||||
|
||||
/**
|
||||
* @author FreeGen
|
||||
*/
|
||||
public class RoleBhv extends BsRoleBhv {
|
||||
|
||||
}
|
10
src/main/java/org/codelibs/fess/es/exbhv/UserBhv.java
Normal file
10
src/main/java/org/codelibs/fess/es/exbhv/UserBhv.java
Normal file
|
@ -0,0 +1,10 @@
|
|||
package org.codelibs.fess.es.exbhv;
|
||||
|
||||
import org.codelibs.fess.es.bsbhv.BsUserBhv;
|
||||
|
||||
/**
|
||||
* @author FreeGen
|
||||
*/
|
||||
public class UserBhv extends BsUserBhv {
|
||||
|
||||
}
|
11
src/main/java/org/codelibs/fess/es/exentity/EventLog.java
Normal file
11
src/main/java/org/codelibs/fess/es/exentity/EventLog.java
Normal file
|
@ -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;
|
||||
}
|
11
src/main/java/org/codelibs/fess/es/exentity/Group.java
Normal file
11
src/main/java/org/codelibs/fess/es/exentity/Group.java
Normal file
|
@ -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;
|
||||
}
|
11
src/main/java/org/codelibs/fess/es/exentity/Role.java
Normal file
11
src/main/java/org/codelibs/fess/es/exentity/Role.java
Normal file
|
@ -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;
|
||||
}
|
11
src/main/java/org/codelibs/fess/es/exentity/User.java
Normal file
11
src/main/java/org/codelibs/fess/es/exentity/User.java
Normal file
|
@ -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;
|
||||
}
|
|
@ -6,9 +6,7 @@
|
|||
<property name="settings">
|
||||
{"http.cors.enabled":"true"}
|
||||
</property>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>"fess/doc"</arg>
|
||||
</postConstruct>
|
||||
<!-- Dictionaries -->
|
||||
<postConstruct name="addConfigFile">
|
||||
<arg>"fess"</arg>
|
||||
<arg>"ja/mapping.txt"</arg>
|
||||
|
@ -21,12 +19,14 @@
|
|||
<arg>"fess"</arg>
|
||||
<arg>"ja/kuromoji.txt"</arg>
|
||||
</postConstruct>
|
||||
<!-- fess index -->
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>"fess/doc"</arg>
|
||||
</postConstruct>
|
||||
<!-- .fess_config index -->
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/boost_document_rule"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/click_log"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/crawling_session"</arg>
|
||||
</postConstruct>
|
||||
|
@ -45,9 +45,6 @@
|
|||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/failure_url"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/favorite_log"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/file_authentication"</arg>
|
||||
</postConstruct>
|
||||
|
@ -87,21 +84,12 @@
|
|||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/scheduled_job"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/search_field_log"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/search_log"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/suggest_bad_word"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/suggest_elevate_word"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/user_info"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/web_authentication"</arg>
|
||||
</postConstruct>
|
||||
|
@ -114,5 +102,34 @@
|
|||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_config/web_config_to_role"</arg>
|
||||
</postConstruct>
|
||||
<!-- .fess_user index -->
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_user/user"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_user/role"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>".fess_user/group"</arg>
|
||||
</postConstruct>
|
||||
<!-- fess_log index -->
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>"fess_log/event_log"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>"fess_log/click_log"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>"fess_log/favorite_log"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>"fess_log/search_field_log"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>"fess_log/search_log"</arg>
|
||||
</postConstruct>
|
||||
<postConstruct name="addIndexConfig">
|
||||
<arg>"fess_log/user_info"</arg>
|
||||
</postConstruct>
|
||||
</component>
|
||||
</components>
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"settings": {
|
||||
"index": {
|
||||
"refresh_interval": "1s",
|
||||
"number_of_shards": 5,
|
||||
"number_of_shards": 2,
|
||||
"number_of_replicas": 0
|
||||
}
|
||||
}
|
||||
|
|
9
src/main/resources/fess_indices/.fess_user.json
Normal file
9
src/main/resources/fess_indices/.fess_user.json
Normal file
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
"settings": {
|
||||
"index": {
|
||||
"refresh_interval": "1s",
|
||||
"number_of_shards": 5,
|
||||
"number_of_replicas": 0
|
||||
}
|
||||
}
|
||||
}
|
23
src/main/resources/fess_indices/.fess_user/group.json
Normal file
23
src/main/resources/fess_indices/.fess_user/group.json
Normal file
|
@ -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"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
23
src/main/resources/fess_indices/.fess_user/role.json
Normal file
23
src/main/resources/fess_indices/.fess_user/role.json
Normal file
|
@ -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"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
35
src/main/resources/fess_indices/.fess_user/user.json
Normal file
35
src/main/resources/fess_indices/.fess_user/user.json
Normal file
|
@ -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"
|
||||
},
|
||||
"group": {
|
||||
"type": "string",
|
||||
"index": "not_analyzed"
|
||||
},
|
||||
"role": {
|
||||
"type": "string",
|
||||
"index": "not_analyzed"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
9
src/main/resources/fess_indices/fess_log.json
Normal file
9
src/main/resources/fess_indices/fess_log.json
Normal file
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
"settings": {
|
||||
"index": {
|
||||
"refresh_interval": "60s",
|
||||
"number_of_shards": 10,
|
||||
"number_of_replicas": 0
|
||||
}
|
||||
}
|
||||
}
|
37
src/main/resources/fess_indices/fess_log/event_log.json
Normal file
37
src/main/resources/fess_indices/fess_log/event_log.json
Normal file
|
@ -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"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -53,8 +53,9 @@
|
|||
"type": "string",
|
||||
"index": "not_analyzed"
|
||||
},
|
||||
"userId": {
|
||||
"type": "long"
|
||||
"userInfoId": {
|
||||
"type": "string",
|
||||
"index": "not_analyzed"
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Reference in a new issue