[#6306] Add org.jooq.True and org.jooq.False
This commit is contained in:
parent
97a4cffa8e
commit
cb0a9249e5
44
jOOQ/src/main/java/org/jooq/False.java
Normal file
44
jOOQ/src/main/java/org/jooq/False.java
Normal file
@ -0,0 +1,44 @@
|
||||
/*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*
|
||||
* Other licenses:
|
||||
* -----------------------------------------------------------------------------
|
||||
* Commercial licenses for this work are available. These replace the above
|
||||
* ASL 2.0 and offer limited warranties, support, maintenance, and commercial
|
||||
* database integrations.
|
||||
*
|
||||
* For more information, please visit: http://www.jooq.org/licenses
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*/
|
||||
package org.jooq;
|
||||
|
||||
/**
|
||||
* A predicate that always yields <code>false</code>.
|
||||
*
|
||||
* @author Lukas Eder
|
||||
*/
|
||||
public interface False extends Condition {
|
||||
|
||||
}
|
||||
44
jOOQ/src/main/java/org/jooq/True.java
Normal file
44
jOOQ/src/main/java/org/jooq/True.java
Normal file
@ -0,0 +1,44 @@
|
||||
/*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*
|
||||
* Other licenses:
|
||||
* -----------------------------------------------------------------------------
|
||||
* Commercial licenses for this work are available. These replace the above
|
||||
* ASL 2.0 and offer limited warranties, support, maintenance, and commercial
|
||||
* database integrations.
|
||||
*
|
||||
* For more information, please visit: http://www.jooq.org/licenses
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*
|
||||
*/
|
||||
package org.jooq;
|
||||
|
||||
/**
|
||||
* A predicate that always yields <code>true</code>.
|
||||
*
|
||||
* @author Lukas Eder
|
||||
*/
|
||||
public interface True extends Condition {
|
||||
|
||||
}
|
||||
@ -154,6 +154,7 @@ import org.jooq.DropSchemaStep;
|
||||
import org.jooq.DropSequenceFinalStep;
|
||||
import org.jooq.DropTableStep;
|
||||
import org.jooq.DropViewFinalStep;
|
||||
import org.jooq.False;
|
||||
import org.jooq.Field;
|
||||
import org.jooq.FieldOrRow;
|
||||
import org.jooq.GroupConcatOrderByStep;
|
||||
@ -282,6 +283,7 @@ import org.jooq.SortField;
|
||||
import org.jooq.Support;
|
||||
import org.jooq.Table;
|
||||
import org.jooq.TableLike;
|
||||
import org.jooq.True;
|
||||
import org.jooq.TruncateIdentityStep;
|
||||
import org.jooq.UDTRecord;
|
||||
import org.jooq.Update;
|
||||
@ -10242,7 +10244,7 @@ public class DSL {
|
||||
* Return a <code>Condition</code> that will always evaluate to true.
|
||||
*/
|
||||
@Support
|
||||
public static Condition trueCondition() {
|
||||
public static True trueCondition() {
|
||||
return new TrueCondition();
|
||||
}
|
||||
|
||||
@ -10250,7 +10252,7 @@ public class DSL {
|
||||
* Return a <code>Condition</code> that will always evaluate to false.
|
||||
*/
|
||||
@Support
|
||||
public static Condition falseCondition() {
|
||||
public static False falseCondition() {
|
||||
return new FalseCondition();
|
||||
}
|
||||
|
||||
|
||||
@ -39,11 +39,12 @@ import static org.jooq.Clause.CONDITION_COMPARISON;
|
||||
|
||||
import org.jooq.Clause;
|
||||
import org.jooq.Context;
|
||||
import org.jooq.False;
|
||||
|
||||
/**
|
||||
* @author Lukas Eder
|
||||
*/
|
||||
final class FalseCondition extends AbstractCondition {
|
||||
final class FalseCondition extends AbstractCondition implements False {
|
||||
|
||||
private static final long serialVersionUID = -3972466479081463547L;
|
||||
private static final Clause[] CLAUSES = { CONDITION, CONDITION_COMPARISON };
|
||||
|
||||
@ -40,11 +40,12 @@ import static org.jooq.Clause.CONDITION_COMPARISON;
|
||||
|
||||
import org.jooq.Clause;
|
||||
import org.jooq.Context;
|
||||
import org.jooq.True;
|
||||
|
||||
/**
|
||||
* @author Lukas Eder
|
||||
*/
|
||||
final class TrueCondition extends AbstractCondition {
|
||||
final class TrueCondition extends AbstractCondition implements True {
|
||||
|
||||
private static final long serialVersionUID = 775364624704563687L;
|
||||
private static final Clause[] CLAUSES = { CONDITION, CONDITION_COMPARISON };
|
||||
|
||||
Loading…
Reference in New Issue
Block a user