Skip navigation links

Oracle® Coherence Java API Reference
Release 3.7.1.0

E22843-01


com.tangosol.util
Class SimpleQueryRecord.PartialResult.Step

java.lang.Object
  extended by com.tangosol.util.SimpleQueryRecord.PartialResult.Step

All Implemented Interfaces:
ExternalizableLite, PortableObject, QueryRecord.PartialResult.Step, java.io.Serializable
Direct Known Subclasses:
SimpleQueryRecord.PartialResult.AbstractRecordableStep
Enclosing class:
SimpleQueryRecord.PartialResult

public static class SimpleQueryRecord.PartialResult.Step
extends java.lang.Object
implements QueryRecord.PartialResult.Step, ExternalizableLite, PortableObject

Simple QueryRecord.PartialResult.Step implementation.


Field Summary
protected  long m_cMillis
          The execution time in milliseconds.
protected  java.util.List m_listSubSteps
          The list of child steps.
protected  int m_nEfficiency
          The estimated cost.
protected  int m_nSizeIn
          The pre-execution key set size.
protected  int m_nSizeOut
          The post-execution key set size.
protected  java.util.Set m_setIndexLookupRecords
          The set of index lookup records.
protected  java.lang.String m_sFilter
          The filter description.

 

Constructor Summary
SimpleQueryRecord.PartialResult.Step()
          Default constructor (necessary for the ExternalizableLite interface).
SimpleQueryRecord.PartialResult.Step(Filter filter)
          Construct a step.
SimpleQueryRecord.PartialResult.Step(QueryRecord.PartialResult.Step step)
          Copy constructor for a Step.

 

Method Summary
 long getDuration()
          Get the amount of time (in ms) spent evaluating the filter or applying an index for this query plan step.
 int getEfficiency()
          Get the calculated cost of applying the filter as defined by calculateEffectiveness
 java.lang.String getFilterDescription()
          Get a description of the filter that was associated with this step during its creation.
 java.util.Set getIndexLookupRecords()
          Get the recorded information about the index lookups performed during filter evaluation as part of a query record.
 int getPostFilterKeySetSize()
          Get the size of the key set remaining after evaluating the filter or applying an index.
 int getPreFilterKeySetSize()
          Get the size of the key set prior to evaluating the filter or applying an index.
 java.util.List getSteps()
          Return inner nested steps, may be null if not nested.
protected  boolean isMatching(QueryRecord.PartialResult.Step step)
          Determine whether or not the given step is capable of being placed in one-to-one correspondence with this step.
protected  void merge(QueryRecord.PartialResult.Step step)
          Merge the given step with this one.
 void readExternal(java.io.DataInput in)
          Restore the contents of this object by loading the object's state from the passed DataInput object.
 void readExternal(PofReader in)
          Restore the contents of a user type instance by reading its state using the specified PofReader object.
 void writeExternal(java.io.DataOutput out)
          Save the contents of this object by storing the object's state into the passed DataOutput object.
 void writeExternal(PofWriter out)
          Save the contents of a POF user type instance by writing its state using the specified PofWriter object.

 

Field Detail

m_sFilter

protected java.lang.String m_sFilter
The filter description.

m_nEfficiency

protected int m_nEfficiency
The estimated cost.

m_nSizeIn

protected int m_nSizeIn
The pre-execution key set size.

m_nSizeOut

protected int m_nSizeOut
The post-execution key set size.

m_cMillis

protected long m_cMillis
The execution time in milliseconds.

m_setIndexLookupRecords

protected java.util.Set m_setIndexLookupRecords
The set of index lookup records.

m_listSubSteps

protected java.util.List m_listSubSteps
The list of child steps.

Constructor Detail

SimpleQueryRecord.PartialResult.Step

public SimpleQueryRecord.PartialResult.Step()
Default constructor (necessary for the ExternalizableLite interface).

SimpleQueryRecord.PartialResult.Step

public SimpleQueryRecord.PartialResult.Step(Filter filter)
Construct a step.
Parameters:
filter - the filter

SimpleQueryRecord.PartialResult.Step

public SimpleQueryRecord.PartialResult.Step(QueryRecord.PartialResult.Step step)
Copy constructor for a Step.
Parameters:
step - the step to copy

Method Detail

getSteps

public java.util.List getSteps()
Return inner nested steps, may be null if not nested.
Specified by:
getSteps in interface QueryRecord.PartialResult.Step
Returns:
the inner nested steps in the order they are applied

getFilterDescription

public java.lang.String getFilterDescription()
Get a description of the filter that was associated with this step during its creation.
Specified by:
getFilterDescription in interface QueryRecord.PartialResult.Step
Returns:
the description of the filter

getIndexLookupRecords

public java.util.Set getIndexLookupRecords()
Get the recorded information about the index lookups performed during filter evaluation as part of a query record.
Specified by:
getIndexLookupRecords in interface QueryRecord.PartialResult.Step
Returns:
a set of QueryRecord.PartialResult.IndexLookupRecord

getEfficiency

public int getEfficiency()
Get the calculated cost of applying the filter as defined by calculateEffectiveness
Specified by:
getEfficiency in interface QueryRecord.PartialResult.Step
Returns:
an effectiveness estimate of how well the associated filter can use any applicable index

getPreFilterKeySetSize

public int getPreFilterKeySetSize()
Get the size of the key set prior to evaluating the filter or applying an index. This value can be used together with QueryRecord.PartialResult.Step.getPostFilterKeySetSize() to calculate an actual effectiveness (reduction of the key set) for this filter step.
Specified by:
getPreFilterKeySetSize in interface QueryRecord.PartialResult.Step
Returns:
the size of the key set prior to evaluating the filter or applying an index

getPostFilterKeySetSize

public int getPostFilterKeySetSize()
Get the size of the key set remaining after evaluating the filter or applying an index. This value can be used together with QueryRecord.PartialResult.Step.getPreFilterKeySetSize() to calculate an actual effectiveness (reduction of the key set) for this filter step.
Specified by:
getPostFilterKeySetSize in interface QueryRecord.PartialResult.Step
Returns:
the size of the key set after evaluating the filter or applying an index

getDuration

public long getDuration()
Get the amount of time (in ms) spent evaluating the filter or applying an index for this query plan step.
Specified by:
getDuration in interface QueryRecord.PartialResult.Step
Returns:
the number of milliseconds spent evaluating the filter

isMatching

protected boolean isMatching(QueryRecord.PartialResult.Step step)
Determine whether or not the given step is capable of being placed in one-to-one correspondence with this step. Steps are defined to be matching if both steps have equivalent name, index lookup records and owned lists of sub-steps.
Parameters:
step - the step to check
Returns:
true iff the given step matches with this step

merge

protected void merge(QueryRecord.PartialResult.Step step)
Merge the given step with this one. This method assumes that the given step matches with this one.
Parameters:
step - the step to merge

readExternal

public void readExternal(java.io.DataInput in)
                  throws java.io.IOException
Restore the contents of this object by loading the object's state from the passed DataInput object.
Specified by:
readExternal in interface ExternalizableLite
Parameters:
in - the DataInput stream to read data from in order to restore the state of this object
Throws:
java.io.IOException - if an I/O exception occurs
java.io.NotActiveException - if the object is not in its initial state, and therefore cannot be deserialized into

writeExternal

public void writeExternal(java.io.DataOutput out)
                   throws java.io.IOException
Save the contents of this object by storing the object's state into the passed DataOutput object.
Specified by:
writeExternal in interface ExternalizableLite
Parameters:
out - the DataOutput stream to write the state of this object to
Throws:
java.io.IOException - if an I/O exception occurs

readExternal

public void readExternal(PofReader in)
                  throws java.io.IOException
Restore the contents of a user type instance by reading its state using the specified PofReader object.
Specified by:
readExternal in interface PortableObject
Parameters:
in - the PofReader from which to read the object's state
Throws:
java.io.IOException - if an I/O error occurs

writeExternal

public void writeExternal(PofWriter out)
                   throws java.io.IOException
Save the contents of a POF user type instance by writing its state using the specified PofWriter object.
Specified by:
writeExternal in interface PortableObject
Parameters:
out - the PofWriter to which to write the object's state
Throws:
java.io.IOException - if an I/O error occurs

Skip navigation links

Oracle® Coherence Java API Reference
Release 3.7.1.0

E22843-01


Copyright © 2000, 2011, Oracle and/or its affiliates. All rights reserved.