public final class IntervalMergesOperatorImplementation extends java.lang.Object implements IntervalOperatorImplementation
| Constructor and Description |
|---|
IntervalMergesOperatorImplementation(java.lang.String intervalTypeName,
IntervalOverlapsOperatorImplementation overlapsOperatorImplementation,
IntervalMeetsOperatorImplementation meetsOperatorImplementation)
Creates the IntervalMergesOperatorImplementation for the named interval type
|
| Modifier and Type | Method and Description |
|---|---|
ValueBuffer |
executeOperator(java.util.LinkedList<ValueBuffer> args)
The MERGES operator returns TRUE if the two interval arguments can be IUNIONed.
|
java.lang.String[] |
getArgumentTypeNames()
MERGES takes two arguments that are both of the same interval type
|
TypeDeclaration |
getReturnTypeDeclaration()
Gets the full type declaration of the type of the return value.
|
java.lang.String |
getReturnTypeName()
The return type is BOOLEAN
|
java.lang.String |
getSignature()
Gets the name of the operator implemented by this implementation object
|
boolean |
isDeterministic()
Tells whether the operator is deterministic with respect to the arguments of its invocations.
|
void |
readExternal(java.io.ObjectInput in) |
void |
writeExternal(java.io.ObjectOutput out) |
public IntervalMergesOperatorImplementation(java.lang.String intervalTypeName,
IntervalOverlapsOperatorImplementation overlapsOperatorImplementation,
IntervalMeetsOperatorImplementation meetsOperatorImplementation)
intervalTypeName - The name of the interval type for which the MERGES operator is being definedoverlapsOperatorImplementation - The implementation object of the OVERLAPS operator for the interval typemeetsOperatorImplementation - The implementation object of the MEETS operator for the interval typepublic ValueBuffer executeOperator(java.util.LinkedList<ValueBuffer> args)
| Cases | (meaning) | MERGES operator outcome |
| Any argument is o (the empty interval) | b1 == e1 || b2 == e2 | TRUE |
| Allen's MEETS operator | e1 == b2 | TRUE |
| Allen's IS MET BY operator | e2 == b1 | TRUE |
| Allen's OVERLAPS operator | b1 < b2 < e1 | TRUE |
| Allen's IS OVERLAPPED BY operator | b2 < b1 < e2 | TRUE |
| Allen's STARTS operator | b1 == b2 && e1 < e2 | TRUE |
| Allen's IS STARTED BY operator | b1 == b2 && e1 > e2 | TRUE |
| Allen's FINISHES operator | b1 > b2 && e1 == e2 | TRUE |
| Allen's IS FINISHED BY operator | b1 < b2 && e1 == e2 | TRUE |
| Allen's IS CONTAINED IN operator | b1 > b2 && e1 < e2 | TRUE |
| Allen's CONTAINS operator | b1 < b2 && e1 > e2 | TRUE |
| Allen's EQUALS operator | b1 == b2 && e1 == e2 | TRUE |
| All other Allen operators (AFTER BEFORE) | FALSE |
executeOperator in interface OperatorImplementation_V0104args - the argument list. The list must hold as many ValueBuffer objects as there are arguments to the operator, and each ValueBuffer object holds a value for some argument to the operator. ValueBuffer objects on the list must appear in the same order as the operator argument declarations. Implementations have the option, but are not required, to do a check the conformance of the argument list (the argument count, notably) to the operator signature.public java.lang.String[] getArgumentTypeNames()
getArgumentTypeNames in interface OperatorImplementation_V0104public TypeDeclaration getReturnTypeDeclaration()
OperatorImplementation_V0105getReturnTypeDeclaration in interface OperatorImplementation_V0105public java.lang.String getReturnTypeName()
getReturnTypeName in interface OperatorImplementation_V0104public java.lang.String getSignature()
OperatorImplementation_V0104getSignature in interface OperatorImplementation_V0104public boolean isDeterministic()
OperatorImplementation_V0104isDeterministic in interface OperatorImplementation_V0104public void readExternal(java.io.ObjectInput in)
throws java.io.IOException,
java.lang.ClassNotFoundException
readExternal in interface java.io.Externalizablejava.io.IOExceptionjava.lang.ClassNotFoundExceptionpublic void writeExternal(java.io.ObjectOutput out)
throws java.io.IOException
writeExternal in interface java.io.Externalizablejava.io.IOException