String value
String notes
String paraNotes
int orderNo
String actionKey
ContentType contentType
List<E> apiParameters
ClassType retType
String retMockJson
Map<K,V> retRemarks
Class<T> controllerClass
Method method
String name
Set<E> uri
boolean uriHealthCheckEnable
String uriHealthCheckPath
boolean enable
boolean sentinelEnable
String sentinelBlockPage
Map<K,V> sentinelBlockJsonMap
int proxyReadTimeout
int proxyConnectTimeout
int proxyRetries
String proxyContentType
String[] pathEquals
String[] pathContains
String[] pathStartsWith
String[] pathEndsWith
String[] hostEquals
String[] hostContains
String[] hostStartsWith
String[] hostEndsWith
Map<K,V> queryEquals
String[] queryContains
String[] interceptors
String loadBalanceStrategy
Set<E> unHealthUris
Set<E> discoveryUris
String[] healthUris
boolean healthUriChanged
GatewayInterceptor[] gatewayInterceptors
GatewayLoadBalanceStrategy gatewayLoadBalanceStrategy
String namesrvAddr
String namespace
String consumerGroup
Integer consumeMessageBatchMaxSize
String broadcastChannelPrefix
String subscribeSubExpression
String producerGroup
String instanceName
String clientIP
String createTopicKey
Boolean useTLS
Boolean sendLatencyFaultEnable
Boolean sendMessageWithVIPChannel
Integer sendMsgTimeout
Boolean retryAnotherBrokerWhenNotStoreOK
Integer retryTimesWhenSendAsyncFailed
Integer retryTimesWhenSendFailed
String version
String group
String url
Boolean generic
Boolean check
Integer retries
see Constants#DEFAULT_RETRIES
String loadbalance
see Constants#DEFAULT_LOADBALANCE
Boolean async
Integer actives
Integer timeout
String application
String module
String consumer
String monitor
String registry
String protocol
String tag
String id
default value is empty
String version
String group
String path
Boolean export
String token
Boolean deprecated
Boolean register
Integer weight
String document
int retries
String loadbalance
String application
String module
String provider
String protocol
String monitor
String registry
String tag
List<E> cols
boolean useSafeMode
比如 : ``` public ShopInfo findFirstByAccountId(BigInteger accountId) { return findFirstByColumns(Columns.create("account_id", accountId)); } ``` 根据账户 id 来查询该账户对应的 ShopInfo,此时 如果传入 null 值,则返回了 第一个 ShopInfo,这个 ShopInfo 可能并不是该账户的。
在这种场景下,我们就不应该允许用户传入 null 值进行查询,当传入 null 的时候直接抛出异常即可 。
此时,我们可以使用如下代码进行查询。
``` public ShopInfo findFirstByAccountId(BigInteger accountId) { return findFirstByColumns(Columns.safeMode().eq("account_id", accountId)); } ```
Columns columns
Columns columns
int errorCode
Copyright © 2024. All rights reserved.